[code-saturne] 58/70: Imported Upstream version 2.0.1

Gilles Filippini pini at debian.org
Sun Jan 18 22:33:16 UTC 2015


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

pini pushed a commit to branch master
in repository code-saturne.

commit 02da66815c141e55636ccd34870960350987c9c1
Author: Gilles Filippini <pini at debian.org>
Date:   Sun Jan 18 22:52:45 2015 +0100

    Imported Upstream version 2.0.1
---
 ABOUT-NLS                                          | 1956 +++--
 COMPATIBILITY                                      |   21 +-
 ChangeLog                                          |  701 +-
 Makefile.in                                        |   22 +-
 QUALITY_ASSURANCE                                  |    4 +-
 aclocal.m4                                         | 9228 --------------------
 bin/cs_case.py                                     |   61 +-
 bin/cs_case_domain.py                              |   20 +-
 bin/cs_check_mesh.py                               |    7 +
 bin/cs_exec_environment.py                         |  230 +-
 bin/cs_info.py                                     |   30 +-
 bin/runcase.in                                     |    5 +-
 bin/runcase.py.in                                  |  125 +-
 bin/runcase_mpi_env                                |   15 +-
 bin/runcase_mpi_rank                               |    2 +-
 config/config.rpath                                |   34 +-
 config/cs_auto_flags.sh                            |  103 +-
 config/cs_blas.m4                                  |   22 -
 config/cs_fortran.m4                               |    4 +-
 config/cs_mpi.m4                                   |    4 +-
 config/gettext.m4                                  |   42 +-
 config/iconv.m4                                    |   68 +-
 config/lib-ld.m4                                   |   20 +-
 config/lib-link.m4                                 |  133 +-
 config/lib-prefix.m4                               |   91 +-
 config/libtool.m4                                  | 2002 +++--
 config/ltmain.sh                                   | 3976 ++++++---
 config/ltoptions.m4                                |   13 +-
 config/ltversion.m4                                |   12 +-
 config/lt~obsolete.m4                              |   12 +-
 config/nls.m4                                      |   13 +-
 config/po.m4                                       |   10 +-
 config/progtest.m4                                 |   14 +-
 configure                                          | 5805 +++++++-----
 configure.ac                                       |   33 +-
 cs_config.h.in                                     |    3 +
 doc/Makefile.am                                    |    2 +-
 doc/Makefile.in                                    |   24 +-
 doc/developper/Makefile.am                         |    3 +-
 doc/developper/Makefile.in                         |   26 +-
 doc/developper/coding_standards.tex                |  340 +
 doc/developper/developper.tex                      |    1 +
 doc/developper/graphics/Makefile.in                |   22 +-
 doc/howto/Makefile.in                              |   22 +-
 doc/howto/graphics/Makefile.in                     |   22 +-
 doc/install/Makefile.in                            |   22 +-
 doc/refcard/Makefile.in                            |   22 +-
 doc/refcard/graphics/Makefile.in                   |   22 +-
 doc/style/csdoc.sty                                |    1 +
 doc/theory/Makefile.in                             |   22 +-
 doc/theory/bilsc2.tex                              |    2 +-
 doc/theory/combbase.tex                            |   32 +-
 doc/theory/combfuel.tex                            |   62 +-
 doc/theory/combgaz.tex                             |   80 +-
 doc/theory/graphics/Makefile.in                    |   22 +-
 doc/theory/thermo.tex                              |   45 +-
 doc/tutorial/Makefile.am                           |    5 -
 doc/tutorial/Makefile.in                           |   28 +-
 doc/tutorial/case2.tex                             |   14 +-
 doc/tutorial/case3.tex                             |   66 +-
 doc/tutorial/case4.tex                             |   88 +-
 doc/tutorial/case5.tex                             |   69 +-
 doc/tutorial/graphics/Makefile.am                  |   48 +-
 doc/tutorial/graphics/Makefile.in                  |   70 +-
 doc/tutorial/graphics/V-1.png                      |  Bin 0 -> 124083 bytes
 doc/tutorial/graphics/V-10.png                     |  Bin 0 -> 3021 bytes
 doc/tutorial/graphics/V-11.png                     |  Bin 0 -> 54457 bytes
 doc/tutorial/graphics/V-12.png                     |  Bin 0 -> 53094 bytes
 doc/tutorial/graphics/V-13.png                     |  Bin 0 -> 12408 bytes
 doc/tutorial/graphics/V-14.png                     |  Bin 0 -> 49592 bytes
 doc/tutorial/graphics/V-15.png                     |  Bin 0 -> 63889 bytes
 doc/tutorial/graphics/V-16.png                     |  Bin 0 -> 53802 bytes
 doc/tutorial/graphics/V-17.png                     |  Bin 0 -> 60572 bytes
 doc/tutorial/graphics/V-18.png                     |  Bin 0 -> 14673 bytes
 doc/tutorial/graphics/V-2.png                      |  Bin 0 -> 120888 bytes
 doc/tutorial/graphics/V-20.png                     |  Bin 0 -> 11970 bytes
 doc/tutorial/graphics/V-21.png                     |  Bin 0 -> 14957 bytes
 doc/tutorial/graphics/V-22.png                     |  Bin 0 -> 16680 bytes
 doc/tutorial/graphics/V-23.png                     |  Bin 0 -> 74381 bytes
 doc/tutorial/graphics/V-24.png                     |  Bin 0 -> 20585 bytes
 doc/tutorial/graphics/V-25.png                     |  Bin 0 -> 19886 bytes
 doc/tutorial/graphics/V-27.png                     |  Bin 0 -> 23063 bytes
 doc/tutorial/graphics/V-28.png                     |  Bin 0 -> 8192 bytes
 doc/tutorial/graphics/V-29.png                     |  Bin 0 -> 59473 bytes
 doc/tutorial/graphics/V-3.png                      |  Bin 0 -> 45972 bytes
 doc/tutorial/graphics/V-30.png                     |  Bin 0 -> 77847 bytes
 doc/tutorial/graphics/V-31.png                     |  Bin 0 -> 27347 bytes
 doc/tutorial/graphics/V-32.png                     |  Bin 0 -> 25250 bytes
 doc/tutorial/graphics/V-33.png                     |  Bin 0 -> 65784 bytes
 doc/tutorial/graphics/V-34.png                     |  Bin 0 -> 69146 bytes
 doc/tutorial/graphics/V-34bis.png                  |  Bin 0 -> 72481 bytes
 doc/tutorial/graphics/V-35.png                     |  Bin 0 -> 70430 bytes
 doc/tutorial/graphics/V-36.png                     |  Bin 0 -> 60873 bytes
 doc/tutorial/graphics/V-37.png                     |  Bin 0 -> 72731 bytes
 doc/tutorial/graphics/V-38.png                     |  Bin 0 -> 24277 bytes
 doc/tutorial/graphics/V-39.png                     |  Bin 0 -> 69162 bytes
 doc/tutorial/graphics/V-4.png                      |  Bin 0 -> 20565 bytes
 doc/tutorial/graphics/V-40.png                     |  Bin 0 -> 50177 bytes
 doc/tutorial/graphics/V-41.png                     |  Bin 0 -> 50402 bytes
 doc/tutorial/graphics/V-43.png                     |  Bin 0 -> 51171 bytes
 doc/tutorial/graphics/V-44.png                     |  Bin 0 -> 50006 bytes
 doc/tutorial/graphics/V-45.png                     |  Bin 0 -> 46361 bytes
 doc/tutorial/graphics/V-46.png                     |  Bin 0 -> 64900 bytes
 doc/tutorial/graphics/V-47.png                     |  Bin 0 -> 17774 bytes
 doc/tutorial/graphics/V-48.png                     |  Bin 0 -> 23653 bytes
 doc/tutorial/graphics/V-49.png                     |  Bin 0 -> 84023 bytes
 doc/tutorial/graphics/V-5.png                      |  Bin 0 -> 40363 bytes
 doc/tutorial/graphics/V-50.png                     |  Bin 0 -> 27404 bytes
 doc/tutorial/graphics/V-51.png                     |  Bin 0 -> 8913 bytes
 doc/tutorial/graphics/V-52.png                     |  Bin 0 -> 67870 bytes
 doc/tutorial/graphics/V-53.png                     |  Bin 0 -> 88287 bytes
 doc/tutorial/graphics/V-54.png                     |  Bin 0 -> 73651 bytes
 doc/tutorial/graphics/V-56.png                     |  Bin 0 -> 6057 bytes
 doc/tutorial/graphics/V-57.png                     |  Bin 0 -> 11435 bytes
 doc/tutorial/graphics/V-58.png                     |  Bin 0 -> 90233 bytes
 doc/tutorial/graphics/V-59.png                     |  Bin 0 -> 28539 bytes
 doc/tutorial/graphics/V-6.png                      |  Bin 0 -> 47280 bytes
 doc/tutorial/graphics/V-60.png                     |  Bin 0 -> 52187 bytes
 doc/tutorial/graphics/V-60bis.png                  |  Bin 0 -> 9076 bytes
 doc/tutorial/graphics/V-61.png                     |  Bin 0 -> 40309 bytes
 doc/tutorial/graphics/V-62.png                     |  Bin 0 -> 54827 bytes
 doc/tutorial/graphics/V-63.png                     |  Bin 0 -> 51310 bytes
 doc/tutorial/graphics/V-64.png                     |  Bin 0 -> 27161 bytes
 doc/tutorial/graphics/V-65.png                     |  Bin 0 -> 48477 bytes
 doc/tutorial/graphics/V-66.png                     |  Bin 0 -> 42922 bytes
 doc/tutorial/graphics/V-67.png                     |  Bin 0 -> 11439 bytes
 doc/tutorial/graphics/V-68.png                     |  Bin 0 -> 65144 bytes
 doc/tutorial/graphics/V-69.png                     |  Bin 0 -> 68867 bytes
 doc/tutorial/graphics/V-69bis.png                  |  Bin 0 -> 14356 bytes
 doc/tutorial/graphics/V-7.png                      |  Bin 0 -> 43344 bytes
 doc/tutorial/graphics/V-70.png                     |  Bin 0 -> 58935 bytes
 doc/tutorial/graphics/V-71.png                     |  Bin 0 -> 58733 bytes
 doc/tutorial/graphics/V-72.png                     |  Bin 0 -> 63872 bytes
 doc/tutorial/graphics/V-73.png                     |  Bin 0 -> 70253 bytes
 doc/tutorial/graphics/V-73bis.png                  |  Bin 0 -> 70069 bytes
 doc/tutorial/graphics/V-74.png                     |  Bin 0 -> 27821 bytes
 doc/tutorial/graphics/V-74bis.png                  |  Bin 0 -> 28109 bytes
 doc/tutorial/graphics/V-75.png                     |  Bin 0 -> 54195 bytes
 doc/tutorial/graphics/V-76.png                     |  Bin 0 -> 65529 bytes
 doc/tutorial/graphics/V-76bis.png                  |  Bin 0 -> 55957 bytes
 doc/tutorial/graphics/V-8.png                      |  Bin 0 -> 5628 bytes
 doc/tutorial/graphics/V-9.png                      |  Bin 0 -> 33136 bytes
 doc/tutorial/graphics/c1_capture01.jpg             |  Bin 81837 -> 0 bytes
 doc/tutorial/graphics/c1_capture02.jpg             |  Bin 82950 -> 0 bytes
 doc/tutorial/graphics/c1_capture03.jpg             |  Bin 74018 -> 0 bytes
 doc/tutorial/graphics/c1_capture04.jpg             |  Bin 91893 -> 0 bytes
 doc/tutorial/graphics/c1_capture05.jpg             |  Bin 78951 -> 0 bytes
 doc/tutorial/graphics/c1_capture06.jpg             |  Bin 78555 -> 0 bytes
 doc/tutorial/graphics/c1_capture07.jpg             |  Bin 84472 -> 0 bytes
 doc/tutorial/graphics/c1_capture08.jpg             |  Bin 67204 -> 0 bytes
 doc/tutorial/graphics/c1_capture09.jpg             |  Bin 78259 -> 0 bytes
 doc/tutorial/graphics/c1_capture10.jpg             |  Bin 69478 -> 0 bytes
 doc/tutorial/graphics/c1_capture11.jpg             |  Bin 71693 -> 0 bytes
 doc/tutorial/graphics/c1_capture12.jpg             |  Bin 69911 -> 0 bytes
 doc/tutorial/graphics/c1_capture13.jpg             |  Bin 69205 -> 0 bytes
 doc/tutorial/graphics/c1_capture14.jpg             |  Bin 87523 -> 0 bytes
 doc/tutorial/graphics/c1_capture15.jpg             |  Bin 89818 -> 0 bytes
 doc/tutorial/graphics/c1_capture16.jpg             |  Bin 90738 -> 0 bytes
 doc/tutorial/graphics/c1_capture17.jpg             |  Bin 76209 -> 0 bytes
 doc/tutorial/graphics/c1_capture18.jpg             |  Bin 89814 -> 0 bytes
 doc/tutorial/graphics/c1_capture19.jpg             |  Bin 86324 -> 0 bytes
 doc/tutorial/graphics/c1_capture20.jpg             |  Bin 94398 -> 0 bytes
 doc/tutorial/graphics/c1_capture21.jpg             |  Bin 93784 -> 0 bytes
 doc/tutorial/graphics/c1_capture22.jpg             |  Bin 93773 -> 0 bytes
 doc/tutorial/graphics/c1_capture23.jpg             |  Bin 94149 -> 0 bytes
 doc/tutorial/graphics/c1_capture24.jpg             |  Bin 101737 -> 0 bytes
 doc/tutorial/graphics/c1_capture25.jpg             |  Bin 97951 -> 0 bytes
 doc/tutorial/graphics/c1_capture26.jpg             |  Bin 85922 -> 0 bytes
 doc/tutorial/graphics/c1_capture27.jpg             |  Bin 99037 -> 0 bytes
 doc/tutorial/graphics/c1_capture28.jpg             |  Bin 89297 -> 0 bytes
 doc/tutorial/graphics/c1_capture29.jpg             |  Bin 84859 -> 0 bytes
 doc/tutorial/graphics/c1_capture30.jpg             |  Bin 95394 -> 0 bytes
 doc/tutorial/graphics/c1_capture31.jpg             |  Bin 94190 -> 0 bytes
 doc/tutorial/graphics/c1_capture32.jpg             |  Bin 85932 -> 0 bytes
 doc/tutorial/graphics/c1_capture33.jpg             |  Bin 110744 -> 0 bytes
 doc/tutorial/graphics/c1_capture34.jpg             |  Bin 109562 -> 0 bytes
 doc/tutorial/graphics/c1_capture35.jpg             |  Bin 108929 -> 0 bytes
 doc/tutorial/graphics/c1_capture36.jpg             |  Bin 102281 -> 0 bytes
 doc/tutorial/graphics/c1_capture37.jpg             |  Bin 99877 -> 0 bytes
 doc/tutorial/graphics/c1_capture38.jpg             |  Bin 103117 -> 0 bytes
 doc/tutorial/graphics/c1_capture39.jpg             |  Bin 93936 -> 0 bytes
 doc/tutorial/graphics/c1_capture40.jpg             |  Bin 89303 -> 0 bytes
 doc/tutorial/graphics/c1_capture41.jpg             |  Bin 90937 -> 0 bytes
 doc/tutorial/graphics/c1_capture42.jpg             |  Bin 110238 -> 0 bytes
 doc/tutorial/graphics/c1_capture43.jpg             |  Bin 103061 -> 0 bytes
 doc/tutorial/graphics/c2_capture01.jpg             |  Bin 77984 -> 0 bytes
 doc/tutorial/graphics/c2_capture02.jpg             |  Bin 85994 -> 0 bytes
 doc/tutorial/graphics/c2_capture03.jpg             |  Bin 92407 -> 0 bytes
 doc/tutorial/graphics/c2_capture04.jpg             |  Bin 93377 -> 0 bytes
 doc/tutorial/graphics/c2_capture05.jpg             |  Bin 87388 -> 0 bytes
 doc/tutorial/graphics/c2_capture06.jpg             |  Bin 83439 -> 0 bytes
 doc/tutorial/graphics/c2_capture07.jpg             |  Bin 70535 -> 0 bytes
 doc/tutorial/graphics/c2_capture08.jpg             |  Bin 97867 -> 0 bytes
 doc/tutorial/graphics/c2_capture09.jpg             |  Bin 86948 -> 0 bytes
 doc/tutorial/graphics/c2_capture10.jpg             |  Bin 97985 -> 0 bytes
 doc/tutorial/graphics/c2_capture11.jpg             |  Bin 98936 -> 0 bytes
 doc/tutorial/graphics/c2_capture12.jpg             |  Bin 100202 -> 0 bytes
 doc/tutorial/graphics/c2_capture13.jpg             |  Bin 107444 -> 0 bytes
 doc/tutorial/graphics/c2_capture14.jpg             |  Bin 106415 -> 0 bytes
 doc/tutorial/graphics/c2_capture15.jpg             |  Bin 108418 -> 0 bytes
 doc/tutorial/graphics/c2_capture152.jpg            |  Bin 109097 -> 0 bytes
 doc/tutorial/graphics/c2_capture16.jpg             |  Bin 109684 -> 0 bytes
 doc/tutorial/graphics/c2_capture17.jpg             |  Bin 106669 -> 0 bytes
 doc/tutorial/graphics/c2_capture18.jpg             |  Bin 107170 -> 0 bytes
 doc/tutorial/graphics/c2_capture19.jpg             |  Bin 107151 -> 0 bytes
 doc/tutorial/graphics/c2_capture20.jpg             |  Bin 107021 -> 0 bytes
 doc/tutorial/graphics/c2_capture21.jpg             |  Bin 107372 -> 0 bytes
 doc/tutorial/graphics/c2_capture212.jpg            |  Bin 107488 -> 0 bytes
 doc/tutorial/graphics/c2_capture22.jpg             |  Bin 106995 -> 0 bytes
 doc/tutorial/graphics/c2_capture23.jpg             |  Bin 95922 -> 0 bytes
 doc/tutorial/graphics/c2_capture24.jpg             |  Bin 110505 -> 0 bytes
 doc/tutorial/graphics/c2_capture25.jpg             |  Bin 99713 -> 0 bytes
 doc/tutorial/graphics/c2_capture26.jpg             |  Bin 100493 -> 0 bytes
 doc/tutorial/graphics/c2_capture27.jpg             |  Bin 101182 -> 0 bytes
 doc/tutorial/graphics/c2_capture28.jpg             |  Bin 106528 -> 0 bytes
 doc/tutorial/graphics/c2_capture29.jpg             |  Bin 112288 -> 0 bytes
 doc/tutorial/graphics/c2_capture30.jpg             |  Bin 110373 -> 0 bytes
 doc/tutorial/graphics/c3_capture01.jpg             |  Bin 89525 -> 0 bytes
 doc/tutorial/graphics/c3_capture02.jpg             |  Bin 82631 -> 0 bytes
 doc/tutorial/graphics/c3_capture03.jpg             |  Bin 105847 -> 0 bytes
 doc/tutorial/graphics/c3_capture04.jpg             |  Bin 65600 -> 0 bytes
 doc/tutorial/graphics/c3_capture05.jpg             |  Bin 84334 -> 0 bytes
 doc/tutorial/graphics/c3_capture06.jpg             |  Bin 83782 -> 0 bytes
 doc/tutorial/graphics/c4_capture01.jpg             |  Bin 102332 -> 0 bytes
 doc/tutorial/graphics/c4_capture02.jpg             |  Bin 107539 -> 0 bytes
 doc/tutorial/graphics/c5_capture01.jpg             |  Bin 87263 -> 0 bytes
 doc/tutorial/graphics/c5_capture02.jpg             |  Bin 87993 -> 0 bytes
 doc/tutorial/graphics/c5_capture03.jpg             |  Bin 83137 -> 0 bytes
 doc/tutorial/graphics/c5_capture04.jpg             |  Bin 96374 -> 0 bytes
 doc/tutorial/graphics/c5_capture05.jpg             |  Bin 98886 -> 0 bytes
 doc/tutorial/graphics/c5_capture06.jpg             |  Bin 91631 -> 0 bytes
 doc/tutorial/graphics/c5_capture07.jpg             |  Bin 101077 -> 0 bytes
 doc/tutorial/graphics/c5_capture08.jpg             |  Bin 101728 -> 0 bytes
 doc/tutorial/graphics/c5_capture09.jpg             |  Bin 96830 -> 0 bytes
 doc/tutorial/graphics/c5_capture10.jpg             |  Bin 96680 -> 0 bytes
 doc/tutorial/graphics/c5_capture11.jpg             |  Bin 105915 -> 0 bytes
 doc/tutorial/graphics/c5_capture12.jpg             |  Bin 109385 -> 0 bytes
 doc/tutorial/graphics/c5_capture13.jpg             |  Bin 106832 -> 0 bytes
 doc/tutorial/graphics/capture10.jpg                |  Bin 96680 -> 0 bytes
 doc/tutorial/graphics/capture11.jpg                |  Bin 105915 -> 0 bytes
 doc/tutorial/graphics/capture12.jpg                |  Bin 109385 -> 0 bytes
 doc/tutorial/graphics/capture13.jpg                |  Bin 106832 -> 0 bytes
 doc/tutorial/graphics/density_law.png              |  Bin 0 -> 9076 bytes
 doc/tutorial/graphics/head_loss0.png               |  Bin 0 -> 72485 bytes
 doc/tutorial/graphics/head_loss1.png               |  Bin 0 -> 58559 bytes
 doc/tutorial/graphics/head_loss2.png               |  Bin 0 -> 18676 bytes
 doc/tutorial/graphics/head_loss3.png               |  Bin 0 -> 18313 bytes
 doc/tutorial/graphics/head_loss4.png               |  Bin 0 -> 16112 bytes
 doc/tutorial/graphics/head_loss5.png               |  Bin 0 -> 54966 bytes
 doc/tutorial/graphics/viscosity_law.png            |  Bin 0 -> 9318 bytes
 doc/tutorial/intro.tex                             |    3 +-
 doc/tutorial/tuto_case1.tex                        |  284 +-
 doc/tutorial/tuto_case2.tex                        |  140 +-
 doc/tutorial/tuto_case3.tex                        |  110 +-
 doc/tutorial/tuto_case4.tex                        |   49 +-
 doc/tutorial/tuto_case5.tex                        |  107 +-
 doc/user/Makefile.am                               |    1 -
 doc/user/Makefile.in                               |   23 +-
 doc/user/a1_autovalid.tex                          |   61 +-
 doc/user/graphics/Makefile.in                      |   22 +-
 doc/user/graphics/cs_components.fig                |  946 +-
 doc/user/saturne1.tex                              |   82 +-
 doc/user/saturne2.tex                              |    2 +-
 examples/1-simple_junction/case1/case1.xml         |  102 +-
 examples/1-simple_junction/case1/runcase           | 1125 ---
 examples/2-full_domain/case2/case2.xml             |  168 +-
 examples/2-full_domain/case2/lance                 | 1612 ----
 examples/2-full_domain/case2/runcase               | 1125 ---
 examples/2-full_domain/case3/case3.xml             |  162 +-
 examples/2-full_domain/case3/runcase               | 1125 ---
 examples/2-full_domain/case3/usclim.f90            |  320 +-
 examples/2-full_domain/case3/usphyv.f90            |  313 -
 examples/2-full_domain/case4/case4.xml             |  177 +-
 examples/2-full_domain/case4/runcase               | 1125 ---
 examples/2-full_domain/case4/usclim.f90            |  320 +-
 examples/2-full_domain/case4/uskpdc.f90            |  409 -
 examples/2-full_domain/case4/usphyv.f90            |  313 -
 examples/2-full_domain/case4/usproj.f90            |  286 +-
 examples/3-stratified_junction/case5/case5.xml     |  107 +-
 examples/3-stratified_junction/case5/runcase       | 1125 ---
 examples/3-stratified_junction/case5/usdpst.f90    |  365 +-
 examples/3-stratified_junction/case5/usmpst.f90    |  237 +-
 examples/3-stratified_junction/case5/usphyv.f90    |  403 -
 examples/3-stratified_junction/case5/usvpst.f90    |  474 +-
 extras/installer/README.txt                        |    6 +-
 extras/installer/install_saturne.py                |  213 +-
 extras/installer/setup                             |   38 +-
 gui/Base/Makefile.in                               |   22 +-
 gui/Makefile.in                                    |   22 +-
 gui/Pages/BatchRunningModel.py                     |  100 +-
 .../BatchRunningPBSJobManagementDialogForm.ui      |   14 +-
 gui/Pages/BatchRunningView.py                      |   14 +-
 gui/Pages/Boundary.py                              |   26 +-
 gui/Pages/BoundaryConditionsScalarsView.py         |    8 +-
 gui/Pages/Makefile.am                              |    2 +-
 gui/Pages/Makefile.in                              |   24 +-
 include/base/cplsat.h                              |    5 +-
 include/base/cs_join.h                             |   55 +-
 include/base/cs_join_intersect.h                   |    6 +-
 include/base/cs_join_merge.h                       |    8 +-
 include/base/cs_join_mesh.h                        |   88 +-
 include/base/cs_join_perio.h                       |  416 +
 include/base/cs_join_post.h                        |    4 -
 include/base/cs_join_set.h                         |   61 +-
 include/base/cs_join_split.h                       |    4 +-
 include/base/cs_join_update.h                      |   16 +-
 include/base/cs_join_util.h                        |  191 +-
 include/base/cs_mesh.h                             |    6 +
 include/base/cs_prototypes.h                       |    6 +
 libsyrcs/Makefile.in                               |   63 +-
 patches/README                                     |    8 +
 patches/typecl.f90                                 | 1990 +++++
 po/Makefile.in.in                                  |   39 +-
 po/POTFILES.in                                     |    2 +
 po/fr.gmo                                          |  Bin 0 -> 87086 bytes
 po/fr.po                                           | 1048 ++-
 po/{fr.po => ncs.pot}                              | 2357 ++---
 src/Makefile.in                                    |   22 +-
 src/apps/Makefile.in                               |   65 +-
 src/apps/cs_solver.c                               |   17 +-
 src/atmo/Makefile.in                               |   57 +-
 src/atmo/atiniv.f90                                |   17 +-
 src/atmo/atmcls.f90                                |    3 +-
 src/atmo/atphyv.f90                                |    7 +
 src/atmo/atprke.f90                                |    7 +-
 src/atmo/attycl.f90                                |    2 +
 src/base/Makefile.am                               |    7 +-
 src/base/Makefile.in                               |  271 +-
 src/base/clptrg.f90                                |    9 +-
 src/base/clptur.f90                                |    2 +-
 src/base/cs_ast_coupling.c                         |    3 +
 src/base/cs_base.c                                 |   32 +-
 src/base/cs_benchmark.c                            |    6 +-
 src/base/cs_boundary_conditions.c                  |    4 +-
 src/base/cs_ext_neighborhood.c                     |   23 +-
 src/base/cs_gui.c                                  |   11 +-
 src/base/cs_gui_boundary_conditions.c              |    4 +-
 src/base/cs_io.c                                   |   77 +-
 src/base/cs_join.c                                 | 1924 ++--
 src/base/cs_join_f2c.f90                           |   28 +-
 src/base/cs_join_intersect.c                       |  147 +-
 src/base/cs_join_merge.c                           |  146 +-
 src/base/cs_join_mesh.c                            |  941 +-
 src/base/cs_join_perio.c                           | 2417 +++++
 src/base/cs_join_perio_f2c.f90                     |  235 +
 src/base/cs_join_post.c                            |  107 +-
 src/base/cs_join_set.c                             |  704 +-
 src/base/cs_join_split.c                           | 1251 +--
 src/base/cs_join_update.c                          | 1726 ++--
 src/base/cs_join_util.c                            | 1198 ++-
 src/base/cs_matrix.c                               |    2 +
 src/base/cs_mesh.c                                 |   32 +-
 src/base/cs_mesh_quantities.c                      |    5 +-
 src/base/cs_mesh_warping.c                         |    3 +
 src/base/cs_multigrid.c                            |    8 +-
 src/base/cs_opts.c                                 |   69 +-
 src/base/cs_post.c                                 |    2 +-
 src/base/cs_preprocessor_data.c                    |   49 +-
 src/base/cs_restart.c                              |   24 +-
 src/base/cs_sat_coupling.c                         |  115 +-
 src/base/cs_syr4_coupling.c                        |    8 +-
 src/base/csc2cl.f90                                |   12 +-
 src/base/csc2ts.f90                                |    8 +-
 src/base/cscini.f90                                |   39 +-
 src/base/cscpfb.f90                                |  339 +-
 src/base/iniini.f90                                |    2 +-
 src/base/memdis.f90                                |    2 +
 src/base/memdyp.f90                                |    2 +
 src/base/modini.f90                                |    8 +-
 src/base/navsto.f90                                |   66 +-
 src/base/resolp.f90                                |    2 +-
 src/base/resv2f.f90                                |    1 +
 src/base/strini.f90                                |    4 +-
 src/base/testel.f90                                |   89 +-
 src/base/tremai.c                                  |   20 +-
 src/base/turbke.f90                                |    2 +-
 src/cfbl/Makefile.in                               |   66 +-
 src/cfbl/cfvarp.f90                                |    4 +-
 src/cogz/Makefile.in                               |   75 +-
 src/cplv/Makefile.in                               |   63 +-
 src/cplv/cpphy1.f90                                |    2 +-
 src/cplv/cpphyv.f90                                |    2 +-
 src/ctwr/Makefile.in                               |   94 +-
 src/elec/Makefile.in                               |   69 +-
 src/fuel/Makefile.in                               |   57 +-
 src/fuel/fuiniv.f90                                |    2 +
 src/lagr/Makefile.in                               |  121 +-
 src/lagr/enslag.f90                                |    6 +-
 src/lagr/enswaf.f90                                |   52 +-
 src/lagr/lageli.f90                                |    7 +-
 src/lagr/lagopt.f90                                |    4 +
 src/mati/Makefile.in                               |   48 +-
 src/pprt/Makefile.in                               |   51 +-
 src/rayt/Makefile.in                               |   63 +-
 src/rayt/raycli.f90                                |    1 -
 src/rayt/rayopt.f90                                |    8 +-
 users/atmo/usatcl.f90                              |  188 +-
 users/atmo/usati1.f90                              |   13 +-
 users/base/usini1.f90                              |    2 +-
 users/base/usjoin.f90                              |   19 +-
 users/base/{usjoin.f90 => usperi.f90}              |  104 +-
 users/base/usphyv.f90                              |  610 +-
 users/base/ussatc.f90                              |   10 +-
 users/cfbl/uscfpv.f90                              |  256 +-
 users/cfbl/uscfth.f90                              |  434 +-
 users/cfbl/uscfx1.f90                              |    2 +-
 users/cfbl/uscfx2.f90                              |   20 +-
 users/cfbl/uscfxi.f90                              |   60 +-
 users/pprt/usppmo.f90                              |    8 +-
 409 files changed, 27285 insertions(+), 33727 deletions(-)

diff --git a/ABOUT-NLS b/ABOUT-NLS
index 83bc72e..b1de1b6 100644
--- a/ABOUT-NLS
+++ b/ABOUT-NLS
@@ -18,35 +18,7 @@ explain how users should proceed for getting the programs to use the
 available translations.  They tell how people wanting to contribute and
 work on translations can contact the appropriate team.
 
-   When reporting bugs in the `intl/' directory or bugs which may be
-related to internationalization, you should tell about the version of
-`gettext' which is used.  The information can be found in the
-`intl/VERSION' file, in internationalized packages.
-
-1.1 Quick configuration advice
-==============================
-
-If you want to exploit the full power of internationalization, you
-should configure it using
-
-     ./configure --with-included-gettext
-
-to force usage of internationalizing routines provided within this
-package, despite the existence of internationalizing capabilities in the
-operating system where this package is being installed.  So far, only
-the `gettext' implementation in the GNU C library version 2 provides as
-many features (such as locale alias, message inheritance, automatic
-charset conversion or plural form handling) as the implementation here.
-It is also not possible to offer this additional functionality on top
-of a `catgets' implementation.  Future versions of GNU `gettext' will
-very likely convey even more functionality.  So it might be a good idea
-to change to GNU `gettext' as soon as possible.
-
-   So you need _not_ provide this option if you are using GNU libc 2 or
-you have installed a recent copy of the GNU gettext package with the
-included `libintl'.
-
-1.2 INSTALL Matters
+1.1 INSTALL Matters
 ===================
 
 Some packages are "localizable" when properly installed; the programs
@@ -56,36 +28,19 @@ internationalization, predating GNU `gettext'.
 
    By default, this package will be installed to allow translation of
 messages.  It will automatically detect whether the system already
-provides the GNU `gettext' functions.  If not, the included GNU
-`gettext' library will be used.  This library is wholly contained
-within this package, usually in the `intl/' subdirectory, so prior
-installation of the GNU `gettext' package is _not_ required.
-Installers may use special options at configuration time for changing
-the default behaviour.  The commands:
+provides the GNU `gettext' functions.  Installers may use special
+options at configuration time for changing the default behaviour.  The
+command:
 
-     ./configure --with-included-gettext
      ./configure --disable-nls
 
-will, respectively, bypass any pre-existing `gettext' to use the
-internationalizing routines provided within this package, or else,
-_totally_ disable translation of messages.
+will _totally_ disable translation of messages.
 
    When you already have GNU `gettext' installed on your system and run
 configure without an option for your new package, `configure' will
-probably detect the previously built and installed `libintl.a' file and
-will decide to use this.  This might not be desirable.  You should use
-the more recent version of the GNU `gettext' library.  I.e. if the file
-`intl/VERSION' shows that the library which comes with this package is
-more recent, you should use
-
-     ./configure --with-included-gettext
-
-to prevent auto-detection.
-
-   The configuration process will not test for the `catgets' function
-and therefore it will not be used.  The reason is that even an
-emulation of `gettext' on top of `catgets' could not provide all the
-extensions of the GNU `gettext' library.
+probably detect the previously built and installed `libintl' library
+and will decide to use it.  If not, you may have to to use the
+`--with-libintl-prefix' option to tell `configure' where to look for it.
 
    Internationalized packages usually have many `po/LL.po' files, where
 LL gives an ISO 639 two-letter code identifying the language.  Unless
@@ -96,7 +51,7 @@ may be set, prior to configuration, to limit the installed set.
 `LINGUAS' should then contain a space separated list of two-letter
 codes, stating which languages are allowed.
 
-1.3 Using This Package
+1.2 Using This Package
 ======================
 
 As a user, if your language has been installed for this package, you
@@ -148,7 +103,7 @@ to denote the language's main dialect.  For example, `de' is equivalent
 to `de_DE' (German as spoken in Germany), and `pt' to `pt_PT'
 (Portuguese as spoken in Portugal) in this context.
 
-1.4 Translating Teams
+1.3 Translating Teams
 =====================
 
 For the Free Translation Project to be a success, we need interested
@@ -177,859 +132,1118 @@ reach the coordinator for all translator teams.
 the terminology in use.  Proven linguistic skills are praised more than
 programming skills, here.
 
-1.5 Available Packages
+1.4 Available Packages
 ======================
 
 Languages are not equally supported in all packages.  The following
-matrix shows the current state of internationalization, as of November
-2007.  The matrix shows, in regard of each package, for which languages
+matrix shows the current state of internationalization, as of June
+2010.  The matrix shows, in regard of each package, for which languages
 PO files have been submitted to translation coordination, with a
 translation percentage of at least 50%.
 
-     Ready PO files       af am ar az be bg bs ca cs cy da de el en en_GB eo
-                        +----------------------------------------------------+
-     Compendium         |                      []       [] []        []      |
-     a2ps               |             []                [] [] []     []      |
-     aegis              |                                  ()                |
-     ant-phone          |                                  ()                |
-     anubis             |                                  []                |
-     ap-utils           |                                                    |
-     aspell             |                      [] []    [] []        []      |
-     bash               |                                                 [] |
-     bfd                |                                                    |
-     bibshelf           |                                  []                |
-     binutils           |                                                    |
-     bison              |                               [] []                |
-     bison-runtime      |                                  []                |
-     bluez-pin          | []                      []       [] []          [] |
-     cflow              |                               []                   |
-     clisp              |                               [] []    []          |
-     console-tools      |                         []       []                |
-     coreutils          |                []    [] []       []                |
-     cpio               |                                                    |
-     cpplib             |                      []       [] []                |
-     cryptonit          |                                  []                |
-     dialog             |                                                    |
-     diffutils          |                      [] []    [] [] []          [] |
-     doodle             |                                  []                |
-     e2fsprogs          |                         []       []                |
-     enscript           |                      []       [] []        []      |
-     fetchmail          |                      []       [] () []     []      |
-     findutils          |                []                                  |
-     findutils_stable   |                []    []       []                   |
-     flex               |                      []       [] []                |
-     fslint             |                                                    |
-     gas                |                                                    |
-     gawk               |                      []       [] []                |
-     gcal               |                      []                            |
-     gcc                |                                  []                |
-     gettext-examples   | []                   []          [] []          [] |
-     gettext-runtime    |             []       []       [] []             [] |
-     gettext-tools      |                      []          []                |
-     gip                |                []                                  |
-     gliv               |                []                []                |
-     glunarclock        |                []                                  |
-     gmult              | []                               []                |
-     gnubiff            |                                  ()                |
-     gnucash            |                      [] []       () ()     []      |
-     gnuedu             |                                                    |
-     gnulib             |                []                                  |
-     gnunet             |                                                    |
-     gnunet-gtk         |                                                    |
-     gnutls             |                                  []                |
-     gpe-aerial         |                         []       []                |
-     gpe-beam           |                         []       []                |
-     gpe-calendar       |                                                    |
-     gpe-clock          |                         []       []                |
-     gpe-conf           |                         []       []                |
-     gpe-contacts       |                                                    |
-     gpe-edit           |                         []                         |
-     gpe-filemanager    |                                                    |
-     gpe-go             |                         []                         |
-     gpe-login          |                         []       []                |
-     gpe-ownerinfo      |                         []       []                |
-     gpe-package        |                                                    |
-     gpe-sketchbook     |                         []       []                |
-     gpe-su             |                         []       []                |
-     gpe-taskmanager    |                         []       []                |
-     gpe-timesheet      |                         []                         |
-     gpe-today          |                         []       []                |
-     gpe-todo           |                                                    |
-     gphoto2            |                         []    [] []        []      |
-     gprof              |                               [] []                |
-     gpsdrive           |                                                    |
-     gramadoir          | []                               []                |
-     grep               |                         []                      [] |
-     gretl              |                                  ()                |
-     gsasl              |                                                    |
-     gss                |                                                    |
-     gst-plugins-bad    |                []             []                   |
-     gst-plugins-base   |                []             []                   |
-     gst-plugins-good   |                []    []       []                   |
-     gst-plugins-ugly   |                []             []                   |
-     gstreamer          | []             []    [] []    [] []        []      |
-     gtick              |                                  ()                |
-     gtkam              |             []          []    [] []                |
-     gtkorphan          |                []                []                |
-     gtkspell           |             []                   [] []          [] |
-     gutenprint         |                               []                   |
-     hello              |                []    []       [] []             [] |
-     herrie             |                                  []                |
-     hylafax            |                                                    |
-     idutils            |                               [] []                |
-     indent             |                      [] []       []             [] |
-     iso_15924          |                                                    |
-     iso_3166           |       []    [] [] [] [] [] [] [] [] []          [] |
-     iso_3166_2         |                                                    |
-     iso_4217           |                         []    [] []                |
-     iso_639            |                         []    [] []             [] |
-     jpilot             |                         []                         |
-     jtag               |                                                    |
-     jwhois             |                                                    |
-     kbd                |                         []    [] [] []             |
-     keytouch           |                      []          []                |
-     keytouch-editor    |                                  []                |
-     keytouch-keyboa... |                      []                            |
-     latrine            |                                  ()                |
-     ld                 |                               []                   |
-     leafpad            |                []    [] []       [] []             |
-     libc               |                      [] []    [] []                |
-     libexif            |                                  []                |
-     libextractor       |                                  []                |
-     libgpewidget       |                         []    [] []                |
-     libgpg-error       |                                  []                |
-     libgphoto2         |                               [] []                |
-     libgphoto2_port    |                               [] []                |
-     libgsasl           |                                                    |
-     libiconv           |                                  []             [] |
-     libidn             |                         []    []                [] |
-     lifelines          |                               [] ()                |
-     lilypond           |                                  []                |
-     lingoteach         |                                                    |
-     lprng              |                                                    |
-     lynx               |                      [] []    [] []                |
-     m4                 |                         []    [] [] []             |
-     mailfromd          |                                                    |
-     mailutils          |                      []                            |
-     make               |                               [] []                |
-     man-db             |                      []       [] []                |
-     minicom            |                         []    [] []                |
-     nano               |                []    []          []                |
-     opcodes            |                                  []                |
-     parted             |                         []       []                |
-     pilot-qof          |                                                    |
-     popt               |                         []    [] []                |
-     psmisc             |                []                                  |
-     pwdutils           |                                                    |
-     qof                |                                                    |
-     radius             |                      []                            |
-     recode             |             []       []       [] [] []          [] |
-     rpm                |                               []                   |
-     screem             |                                                    |
-     scrollkeeper       |          [] []       [] [] [] [] []        []      |
-     sed                |                      []          []             [] |
-     shared-mime-info   |                []    [] []    [] () []     []   [] |
-     sharutils          |                []    [] []    [] [] []             |
-     shishi             |                                                    |
-     skencil            |                               [] ()                |
-     solfege            |                                                    |
-     soundtracker       |                               [] []                |
-     sp                 |                                  []                |
-     system-tools-ba... |       []       [] [] [] []    [] [] []     []      |
-     tar                |                []                []                |
-     texinfo            |                               [] []             [] |
-     tin                |                                  ()        ()      |
-     tuxpaint           | []             []             [] []        []   [] |
-     unicode-han-tra... |                                                    |
-     unicode-transla... |                                                    |
-     util-linux         |                      [] []    [] []                |
-     util-linux-ng      |                      [] []    [] []                |
-     vorbis-tools       |                         []                         |
-     wastesedge         |                                  ()                |
-     wdiff              |                      []       [] []        []      |
-     wget               |                      [] []       []                |
-     xchat              |             [] []    [] []       [] []     []      |
-     xkeyboard-config   |                []                                  |
-     xpad               |                []             []           []      |
-                        +----------------------------------------------------+
-                          af am ar az be bg bs ca cs cy da de el en en_GB eo
-                           6  0  2  1  8 26  2 40 48  2 56 88 15  1  15   18
-
-                          es et eu fa fi fr  ga gl gu he hi hr hu id is it
+     Ready PO files       af am an ar as ast az be be at latin bg bn_IN bs ca
                         +--------------------------------------------------+
-     Compendium         | []          [] []  []                []          |
-     a2ps               |    []       [] []                             () |
+     a2ps               |                       []                      [] |
      aegis              |                                                  |
-     ant-phone          |                []                                |
-     anubis             |                []                                |
-     ap-utils           |             [] []                                |
-     aspell             |                []  []                         [] |
-     bash               | []                                               |
-     bfd                | []          []                                   |
-     bibshelf           | []                 []                         [] |
-     binutils           | []          [] []                                |
-     bison              | [] []          []  []                   []    [] |
-     bison-runtime      |    []          []  []                   []    [] |
-     bluez-pin          |             [] []  []                [] []       |
-     cflow              |                    []                            |
-     clisp              | []             []                                |
-     console-tools      |                                                  |
-     coreutils          | [] []       [] []  []                []          |
-     cpio               | []             []  []                            |
-     cpplib             | []             []                                |
-     cryptonit          |                []                                |
-     dialog             |       []           []                         [] |
-     diffutils          | []          [] []  [] []    []       [] []    [] |
-     doodle             |                    []                         [] |
-     e2fsprogs          | []             []                             [] |
-     enscript           |                []  []             []             |
-     fetchmail          | []                                               |
-     findutils          |    []              []                []          |
-     findutils_stable   |    []          []  []                []          |
-     flex               | []             []  []                            |
-     fslint             |                                                  |
-     gas                | []             []                                |
-     gawk               | []             []  []       []                () |
-     gcal               | []             []                                |
-     gcc                | []                                               |
-     gettext-examples   | []          [] []  []                [] []    [] |
-     gettext-runtime    | []          [] []  []                   []    [] |
-     gettext-tools      | []    []       []                             [] |
-     gip                | []    []       []  []                            |
-     gliv               |                ()                                |
-     glunarclock        |             []     []                []          |
-     gmult              |       []       []                             [] |
-     gnubiff            |                ()                             () |
-     gnucash            | ()             ()                    ()          |
-     gnuedu             | []                                               |
-     gnulib             | [] []              []                            |
-     gnunet             |                                                  |
-     gnunet-gtk         |                                                  |
-     gnutls             |                                                  |
-     gpe-aerial         | []             []                                |
-     gpe-beam           | []             []                                |
-     gpe-calendar       |                                                  |
-     gpe-clock          | []          [] []                    []          |
-     gpe-conf           |                []                                |
-     gpe-contacts       | []             []                                |
-     gpe-edit           | []             []                    [] []       |
-     gpe-filemanager    | []                                               |
-     gpe-go             | []             []                    []          |
-     gpe-login          | []             []                    []          |
-     gpe-ownerinfo      | []          [] []                    [] []       |
-     gpe-package        | []                                               |
-     gpe-sketchbook     | []             []                                |
-     gpe-su             | []          [] []                    []          |
-     gpe-taskmanager    | []          [] []                                |
-     gpe-timesheet      | []             []  []                   []       |
-     gpe-today          | []          [] []  []                            |
-     gpe-todo           | []                                               |
-     gphoto2            | []          [] []                    []       [] |
-     gprof              | []          [] []  []                   []       |
-     gpsdrive           |    []                                            |
-     gramadoir          |                []  []                            |
-     grep               | []          []     []                            |
-     gretl              | []    []       []                             () |
-     gsasl              |                    []                   []       |
-     gss                |                []  []                            |
-     gst-plugins-bad    | []          []                       []       [] |
-     gst-plugins-base   | []          []                       []       [] |
-     gst-plugins-good   | []    []    []                       []       [] |
-     gst-plugins-ugly   | []          []                       []       [] |
-     gstreamer          |             []                       []       [] |
-     gtick              |             []     []                         [] |
-     gtkam              | []             []                    []       [] |
-     gtkorphan          |                []                             [] |
-     gtkspell           | []    []    [] []  []                []       [] |
-     gutenprint         |                                      []          |
-     hello              | [] [] [] [] [] []  [] []    []    [] [] []    [] |
-     herrie             |                    []                            |
-     hylafax            |                                                  |
-     idutils            |                []  []                [] []    [] |
-     indent             | [] [] []    [] []  [] []             [] []    [] |
-     iso_15924          |                []                                |
-     iso_3166           | [] [] []    [] []     [] [] [] [] [] [] []    [] |
-     iso_3166_2         |                []                                |
-     iso_4217           | [] []       [] []                    []       [] |
-     iso_639            | []       [] [] []  []                []          |
-     jpilot             | []             []                                |
-     jtag               |                []                                |
-     jwhois             | []             []                    [] []    [] |
-     kbd                | []             []                                |
-     keytouch           |                []  []                         [] |
-     keytouch-editor    |                    []                            |
-     keytouch-keyboa... |                    []                         [] |
-     latrine            |                    []                         [] |
-     ld                 | []          [] []  []                            |
-     leafpad            | []             []  []       []       []       [] |
-     libc               | []          [] []     []             []          |
-     libexif            | []                                               |
-     libextractor       |                    []                            |
-     libgpewidget       | []             []  []                [] []       |
-     libgpg-error       |                []                                |
-     libgphoto2         | []             []                             [] |
-     libgphoto2_port    |                []                             [] |
-     libgsasl           |                []  []                            |
-     libiconv           |    []       []     []                            |
-     libidn             |                []                             [] |
-     lifelines          |                ()                                |
-     lilypond           | []          [] []                                |
-     lingoteach         |                []                       []    [] |
-     lprng              |                                                  |
-     lynx               |    []                                []       [] |
-     m4                 |                []  [] []                []       |
-     mailfromd          |                                                  |
-     mailutils          | []             []                                |
-     make               | []          [] []  [] []    []    []    []       |
-     man-db             |                                               [] |
-     minicom            | []          [] []                    []          |
-     nano               | []    []       []  [] []             []       [] |
-     opcodes            | []          [] []  []                            |
-     parted             |                []                       []    [] |
-     pilot-qof          |                                                  |
-     popt               |                []  [] []                   []    |
-     psmisc             |                                      []       [] |
-     pwdutils           |                                                  |
-     qof                |                                         []       |
-     radius             | []             []                                |
-     recode             | []             []  [] []    []       [] []    [] |
-     rpm                |                []                       []       |
-     screem             |                                                  |
-     scrollkeeper       | []          []                       []          |
-     sed                | [] []          []  []                []          |
-     shared-mime-info   | []    []    [] []                    []       [] |
-     sharutils          | [] []       [] []  [] []             []       [] |
-     shishi             |                []                                |
-     skencil            | []             []                                |
-     solfege            |                                               [] |
-     soundtracker       | []             []                             [] |
-     sp                 |                []                                |
-     system-tools-ba... | []    []    [] []  []             [] [] []    [] |
-     tar                |    [] []    []     []                []          |
-     texinfo            |                []           []       []          |
-     tin                |    []          ()                                |
-     tuxpaint           |                    []                []          |
-     unicode-han-tra... |                                                  |
-     unicode-transla... |                []  []                            |
-     util-linux         | [] []       [] []                    [] []    [] |
-     util-linux-ng      | [] []       [] []                    [] []    [] |
-     vorbis-tools       |                                                  |
-     wastesedge         |                ()                                |
-     wdiff              | [] []          []  [] []             [] []    [] |
-     wget               |    []       [] []  []             [] [] []    [] |
-     xchat              | []          [] []        []    []    []       [] |
-     xkeyboard-config   | []          [] []                    []          |
-     xpad               | []                 []                []          |
-                        +--------------------------------------------------+
-                          es et eu fa fi fr  ga gl gu he hi hr hu id is it
-                          85 22 14  2 48 101 61 12  2  8  2  6 53 29  1 52
-
-                          ja ka ko ku ky lg lt lv mk mn ms mt nb ne nl  nn
-                        +--------------------------------------------------+
-     Compendium         |                                           []     |
-     a2ps               |       ()                      []          []     |
-     aegis              |                                           ()     |
-     ant-phone          |                                           []     |
-     anubis             |                               []    []    []     |
-     ap-utils           |                               []                 |
-     aspell             |                            []             []     |
-     bash               |                                           []     |
+     ant-phone          |                                                  |
+     anubis             |                                                  |
+     aspell             |                []                             [] |
+     bash               |                                                  |
      bfd                |                                                  |
-     bibshelf           |                               []                 |
+     bibshelf           |                []                                |
      binutils           |                                                  |
-     bison              |                               []    []    []     |
-     bison-runtime      |                               []    []    []     |
-     bluez-pin          |          []                   []          []     |
+     bison              |                                                  |
+     bison-runtime      |                []                                |
+     bluez-pin          | []             []                                |
+     bombono-dvd        |                                                  |
+     buzztard           |                                                  |
      cflow              |                                                  |
-     clisp              |                                           []     |
-     console-tools      |                                                  |
-     coreutils          |                                           []     |
-     cpio               |                                           []     |
-     cpplib             |                                           []     |
-     cryptonit          |                                           []     |
-     dialog             |                               []          []     |
-     diffutils          | []                            []          []     |
+     clisp              |                                                  |
+     coreutils          |                                   []          [] |
+     cpio               |                                                  |
+     cppi               |                                                  |
+     cpplib             |                                               [] |
+     cryptsetup         |                                                  |
+     dfarc              |                                                  |
+     dialog             |                             []                [] |
+     dico               |                                                  |
+     diffutils          |                                               [] |
+     dink               |                                                  |
      doodle             |                                                  |
-     e2fsprogs          |                                           []     |
-     enscript           |                                           []     |
-     fetchmail          | []                                        []     |
-     findutils          |                                           []     |
-     findutils_stable   |                                           []     |
-     flex               |       []                                  []     |
-     fslint             |                                                  |
+     e2fsprogs          |                                               [] |
+     enscript           |                                               [] |
+     exif               |                                                  |
+     fetchmail          |                                               [] |
+     findutils          |                                   []             |
+     flex               |                                               [] |
+     freedink           |                                                  |
      gas                |                                                  |
-     gawk               | []                                        []     |
-     gcal               |                                                  |
+     gawk               |                []                             [] |
+     gcal               |                                               [] |
      gcc                |                                                  |
-     gettext-examples   | []                            []          []     |
-     gettext-runtime    | []    []                                  []     |
-     gettext-tools      | []    []                                         |
-     gip                |                               []          []     |
-     gliv               |                                           []     |
-     glunarclock        |                               []          []     |
-     gmult              | []                            []          []     |
+     gettext-examples   | []             []                 []          [] |
+     gettext-runtime    |                                   []          [] |
+     gettext-tools      |                                   []          [] |
+     gip                |                                   []             |
+     gjay               |                                                  |
+     gliv               |                                   []             |
+     glunarclock        |                []                 []             |
      gnubiff            |                                                  |
-     gnucash            | ()                                  () ()        |
+     gnucash            |                                               [] |
      gnuedu             |                                                  |
-     gnulib             | []                                        []     |
+     gnulib             |                                                  |
      gnunet             |                                                  |
      gnunet-gtk         |                                                  |
-     gnutls             |                               []                 |
-     gpe-aerial         |                                           []     |
-     gpe-beam           |                                           []     |
-     gpe-calendar       | []                                               |
-     gpe-clock          | []    []                                  []     |
-     gpe-conf           | []    []                                  []     |
-     gpe-contacts       |       []                                         |
-     gpe-edit           | []    []                                  []     |
-     gpe-filemanager    | []    []                                         |
-     gpe-go             | []    []                                  []     |
-     gpe-login          | []    []                                  []     |
-     gpe-ownerinfo      | []                                        []     |
-     gpe-package        | []    []                                         |
-     gpe-sketchbook     |       []                                  []     |
-     gpe-su             | []    []                                  []     |
-     gpe-taskmanager    | []    [] []                               []     |
-     gpe-timesheet      |                                           []     |
-     gpe-today          | []                                        []     |
-     gpe-todo           | []                                               |
-     gphoto2            | []                                        []     |
-     gprof              |                               []                 |
-     gpsdrive           |                                           []     |
-     gramadoir          |                                           ()     |
-     grep               |             []                            []     |
-     gretl              |                                                  |
-     gsasl              |                                           []     |
+     gnutls             |                                                  |
+     gold               |                                                  |
+     gpe-aerial         |                                                  |
+     gpe-beam           |                                                  |
+     gpe-bluetooth      |                                                  |
+     gpe-calendar       |                                                  |
+     gpe-clock          |                []                                |
+     gpe-conf           |                                                  |
+     gpe-contacts       |                                                  |
+     gpe-edit           |                                                  |
+     gpe-filemanager    |                                                  |
+     gpe-go             |                                                  |
+     gpe-login          |                                                  |
+     gpe-ownerinfo      |                []                                |
+     gpe-package        |                                                  |
+     gpe-sketchbook     |                                                  |
+     gpe-su             |                []                                |
+     gpe-taskmanager    |                []                                |
+     gpe-timesheet      |                []                                |
+     gpe-today          |                []                                |
+     gpe-todo           |                                                  |
+     gphoto2            |                                                  |
+     gprof              |                                   []             |
+     gpsdrive           |                                                  |
+     gramadoir          |                                                  |
+     grep               |                                                  |
+     grub               |                []                             [] |
+     gsasl              |                                                  |
      gss                |                                                  |
-     gst-plugins-bad    |                                           []     |
-     gst-plugins-base   |                                           []     |
-     gst-plugins-good   |                                           []     |
-     gst-plugins-ugly   |                                           []     |
-     gstreamer          |                                           []     |
-     gtick              |                                           []     |
-     gtkam              | []                                        []     |
-     gtkorphan          |                                           []     |
-     gtkspell           |                            []             []     |
-     gutenprint         |                                           []     |
-     hello              | [] [] []                      []    []    []  [] |
-     herrie             |                                           []     |
+     gst-plugins-bad    |                                   []             |
+     gst-plugins-base   |                                   []             |
+     gst-plugins-good   |                                   []             |
+     gst-plugins-ugly   |                                   []             |
+     gstreamer          | []                                []          [] |
+     gtick              |                                                  |
+     gtkam              |                       []                         |
+     gtkorphan          |                                   []             |
+     gtkspell           | []             []     []                         |
+     gutenprint         |                                                  |
+     hello              |                                   []             |
+     help2man           |                                                  |
      hylafax            |                                                  |
-     idutils            |                                           []     |
-     indent             | []                                        []     |
-     iso_15924          |                                           []     |
-     iso_3166           | []    [] []       []    []          []    []  [] |
-     iso_3166_2         |                                           []     |
-     iso_4217           | []                []                      []     |
-     iso_639            | []                []                      []  [] |
-     jpilot             | ()                                        ()     |
-     jtag               |                                                  |
-     jwhois             |                                           []     |
-     kbd                |                                           []     |
-     keytouch           |                                           []     |
-     keytouch-editor    |                                           []     |
-     keytouch-keyboa... |                                                  |
-     latrine            |                                           []     |
-     ld                 |                                                  |
-     leafpad            | []                []                             |
-     libc               | []    []                                  []     |
-     libexif            |                                                  |
+     idutils            |                                                  |
+     indent             |                                   []          [] |
+     iso_15924          |                                                  |
+     iso_3166           | []          []        []          []  []   [] [] |
+     iso_3166_2         |                                                  |
+     iso_4217           |                                                  |
+     iso_639            |             [] []     []              []         |
+     iso_639_3          |                                                  |
+     jwhois             |                                                  |
+     kbd                |                                                  |
+     keytouch           |                                               [] |
+     keytouch-editor    |                                                  |
+     keytouch-keyboa... |                                               [] |
+     klavaro            |          []                                      |
+     latrine            |                                                  |
+     ld                 |                                   []             |
+     leafpad            |                                   []          [] |
+     libc               |                                   []          [] |
+     libexif            |                       ()                         |
      libextractor       |                                                  |
-     libgpewidget       |                                           []     |
+     libgnutls          |                                                  |
+     libgpewidget       |                                                  |
      libgpg-error       |                                                  |
-     libgphoto2         | []                                               |
-     libgphoto2_port    | []                                               |
-     libgsasl           |                                           []     |
-     libiconv           |                                           []     |
-     libidn             | []                                        []     |
-     lifelines          |                                           []     |
-     lilypond           |                                           []     |
-     lingoteach         |                                           []     |
+     libgphoto2         |                                                  |
+     libgphoto2_port    |                                                  |
+     libgsasl           |                                                  |
+     libiconv           |                                   []             |
+     libidn             |                                                  |
+     lifelines          |                                                  |
+     liferea            |                             []                [] |
+     lilypond           |                                                  |
+     linkdr             |          []                                      |
+     lordsawar          |                                                  |
      lprng              |                                                  |
-     lynx               | []                                        []     |
-     m4                 | []                                        []     |
+     lynx               |                                               [] |
+     m4                 |                                                  |
      mailfromd          |                                                  |
      mailutils          |                                                  |
-     make               | []    []                                  []     |
+     make               |                                                  |
      man-db             |                                                  |
-     minicom            | []                                               |
-     nano               |                               []    []    []     |
-     opcodes            |                                           []     |
-     parted             | []                                        []     |
-     pilot-qof          |                                                  |
-     popt               | []    []                                  []     |
-     psmisc             | []                                  []    []     |
+     man-db-manpages    |                                                  |
+     minicom            |                                                  |
+     mkisofs            |                                                  |
+     myserver           |                                                  |
+     nano               |                                   []          [] |
+     opcodes            |                                                  |
+     parted             |                                                  |
+     pies               |                                                  |
+     popt               |                                                  |
+     psmisc             |                                                  |
+     pspp               |                                               [] |
      pwdutils           |                                                  |
-     qof                |                                                  |
-     radius             |                                                  |
-     recode             |                                           []     |
-     rpm                | []    []                                         |
-     screem             | []                                               |
-     scrollkeeper       |                                     [] [] []  [] |
-     sed                | []                                        []     |
-     shared-mime-info   | []    []          []          []    []    []  [] |
-     sharutils          | []                                        []     |
+     radius             |                                               [] |
+     recode             |                       []                      [] |
+     rosegarden         |                                                  |
+     rpm                |                                                  |
+     rush               |                                                  |
+     sarg               |                                                  |
+     screem             |                                                  |
+     scrollkeeper       |                    [] []                      [] |
+     sed                |                []                             [] |
+     sharutils          |                                   []          [] |
      shishi             |                                                  |
      skencil            |                                                  |
-     solfege            |                                     ()        () |
+     solfege            |                                                  |
+     solfege-manual     |                                                  |
      soundtracker       |                                                  |
-     sp                 | ()                                               |
-     system-tools-ba... | []    []          []                      []     |
-     tar                | []          []                            []     |
-     texinfo            |                                     []    []     |
+     sp                 |                                                  |
+     sysstat            |                                                  |
+     tar                |                                   []             |
+     texinfo            |                                                  |
      tin                |                                                  |
-     tuxpaint           |                                     ()    []  [] |
      unicode-han-tra... |                                                  |
      unicode-transla... |                                                  |
-     util-linux         | []                                        []     |
-     util-linux-ng      | []                                        []     |
+     util-linux-ng      |                                               [] |
+     vice               |                                                  |
+     vmm                |                                                  |
      vorbis-tools       |                                                  |
-     wastesedge         |                                           []     |
-     wdiff              |                               []    []           |
-     wget               | []                                        []     |
-     xchat              | []    []                []                []     |
-     xkeyboard-config   |    [] []                                  []     |
-     xpad               |       []                      []          []     |
-                        +--------------------------------------------------+
-                          ja ka ko ku ky lg lt lv mk mn ms mt nb ne nl  nn
-                          51  2 25  3  2  0  6  0  2  2 20  0 11  1 103  6
-
-                          or pa pl pt pt_BR rm ro ru rw sk sl sq sr sv  ta
-                        +--------------------------------------------------+
-     Compendium         |          []  []      []       []          []     |
-     a2ps               |       ()     []      [] []       []    [] []     |
-     aegis              |                      () ()                       |
-     ant-phone          |                      []                   []     |
-     anubis             |       []             [] []                       |
-     ap-utils           |       ()                                         |
-     aspell             |                      [] []    []                 |
-     bash               |       []                      []                 |
-     bfd                |                                                  |
-     bibshelf           |                                           []     |
-     binutils           |                         []    []                 |
-     bison              |       []     []      [] []                []     |
-     bison-runtime      |       []     []      []          []       []     |
-     bluez-pin          |       []     []   [] [] []    [] []    [] []     |
-     cflow              |       []                                         |
-     clisp              |                         []                       |
-     console-tools      |                         []                       |
-     coreutils          |       []                []       []       []     |
-     cpio               |       []                []                []     |
-     cpplib             |                                           []     |
-     cryptonit          |              []                           []     |
-     dialog             |                                           []     |
-     diffutils          |       []     []      [] []             [] []     |
-     doodle             |                                     []    []     |
-     e2fsprogs          |       []                                  []     |
-     enscript           |              []      [] []       []       []     |
-     fetchmail          |       []                []          []           |
-     findutils          |       [] []                               []     |
-     findutils_stable   |       [] []          []       [] []       []     |
-     flex               |       []     []      [] []                []     |
-     fslint             |                                           []     |
-     gas                |                                                  |
-     gawk               |       []     []      []                   []     |
-     gcal               |                                           []     |
-     gcc                |                                        [] []     |
-     gettext-examples   |       [] []          [] []    [] []    [] []     |
-     gettext-runtime    |       [] []          [] []    [] []    [] []     |
-     gettext-tools      |       []             [] []    [] []    [] []     |
-     gip                |                   []          []       [] []     |
-     gliv               |       []     []      [] []    []          []     |
-     glunarclock        |              []      [] []    []       [] []     |
-     gmult              |                   [] []                [] []     |
-     gnubiff            |                      ()                   []     |
-     gnucash            |       ()                                  []     |
-     gnuedu             |                                                  |
-     gnulib             |       []                         []       []     |
-     gnunet             |                                                  |
-     gnunet-gtk         |                                           []     |
-     gnutls             |       []                                  []     |
-     gpe-aerial         |          []  []      [] []       []    [] []     |
-     gpe-beam           |          []  []      [] []       []    [] []     |
-     gpe-calendar       |                         []       []    [] []     |
-     gpe-clock          |          []  []      [] []    [] []    [] []     |
-     gpe-conf           |          []  []      [] []    [] []       []     |
-     gpe-contacts       |                      [] []       []    [] []     |
-     gpe-edit           |       [] []  []      [] []    [] []    [] []     |
-     gpe-filemanager    |                                  []       []     |
-     gpe-go             |       []     []      [] []    [] []    [] []     |
-     gpe-login          |          []  []      [] []    [] []    [] []     |
-     gpe-ownerinfo      |          []  []      [] []    [] []    [] []     |
-     gpe-package        |                                  []       []     |
-     gpe-sketchbook     |          []  []      [] []    [] []    [] []     |
-     gpe-su             |          []  []      [] []    [] []    [] []     |
-     gpe-taskmanager    |          []  []      [] []    [] []    [] []     |
-     gpe-timesheet      |          []  []      [] []    [] []    [] []     |
-     gpe-today          |          []  []      [] []    [] []    [] []     |
-     gpe-todo           |                         []       []    [] []     |
-     gphoto2            |    [] []             []       []       [] []     |
-     gprof              |              []      []                   []     |
-     gpsdrive           |                         []                []     |
-     gramadoir          |                               []          []     |
-     grep               |       []                      [] []       []     |
-     gretl              |       [] []  []                                  |
-     gsasl              |       []                               [] []     |
-     gss                |       []             []       []          []     |
-     gst-plugins-bad    |       []     []                           []     |
-     gst-plugins-base   |       []                                  []     |
-     gst-plugins-good   |       []                                  []     |
-     gst-plugins-ugly   |       []     []                           []     |
-     gstreamer          |       []                            [] [] []     |
-     gtick              |                         []                       |
-     gtkam              |    [] []     []         []                []     |
-     gtkorphan          |                                           []     |
-     gtkspell           |              []   [] [] []    [] []    [] []     |
-     gutenprint         |                                           []     |
-     hello              |       []     []      [] []    [] []    [] []     |
-     herrie             |       []                []                []     |
-     hylafax            |                                                  |
-     idutils            |       []     []      [] []                []     |
-     indent             |       []     []      [] []    []       [] []     |
-     iso_15924          |                                                  |
-     iso_3166           |    [] [] []  []      [] [] [] [] [] [] [] []  [] |
-     iso_3166_2         |                                                  |
-     iso_4217           |       [] []             [] []    []    [] []     |
-     iso_639            |       []                [] [] [] []    [] []     |
-     jpilot             |                                                  |
-     jtag               |                               []                 |
-     jwhois             |       []     []      []                   []     |
-     kbd                |       []             []                   []     |
-     keytouch           |                                           []     |
-     keytouch-editor    |                                           []     |
-     keytouch-keyboa... |                                           []     |
-     latrine            |                                                  |
-     ld                 |                                           []     |
-     leafpad            |       [] []             []    []          []  [] |
-     libc               |       []                []    []          []     |
-     libexif            |       []                      []                 |
-     libextractor       |                      []                   []     |
-     libgpewidget       |       [] []  []      []       [] []    [] []     |
-     libgpg-error       |       []             []                   []     |
-     libgphoto2         |       []                                         |
-     libgphoto2_port    |       []                []                []     |
-     libgsasl           |       []             []                [] []     |
-     libiconv           |                                  []    [] []     |
-     libidn             |       []                               [] ()     |
-     lifelines          |       []                                  []     |
-     lilypond           |                                                  |
-     lingoteach         |              []                                  |
-     lprng              |       []                                         |
-     lynx               |              []         []                []     |
-     m4                 |       []     []      [] []                []     |
-     mailfromd          |       []                                         |
-     mailutils          |       []                []                []     |
-     make               |       []     []         []                []     |
-     man-db             |       []             [] []                []     |
-     minicom            |       []     []      [] []                []     |
-     nano               |              []      [] []                []     |
-     opcodes            |                      []                   []     |
-     parted             |       []                                         |
-     pilot-qof          |                                                  |
-     popt               |       [] []             []                []     |
-     psmisc             |       []                                  []     |
-     pwdutils           |       []                                  []     |
-     qof                |              []                           []     |
-     radius             |       []                []                       |
-     recode             |       [] []  []      [] []       []       []     |
-     rpm                |       [] []             []                []     |
-     screem             |                                                  |
-     scrollkeeper       |       []             [] []    []    [] [] []     |
-     sed                |       [] []  []      [] []    [] []    [] []     |
-     shared-mime-info   |       [] []  []                     [] [] []     |
-     sharutils          |       []                []             [] []     |
-     shishi             |       []                                         |
-     skencil            |          []  []                           []     |
-     solfege            |              []                                  |
-     soundtracker       |                               []          []     |
-     sp                 |                                                  |
-     system-tools-ba... |    [] [] []  []      []             [] [] []  [] |
-     tar                |       []                []       []       []     |
-     texinfo            |       []             [] []                []     |
-     tin                |                         ()                       |
-     tuxpaint           |       [] []                      [] [] [] []     |
-     unicode-han-tra... |                                                  |
-     unicode-transla... |                                                  |
-     util-linux         |              []         []       []       []     |
-     util-linux-ng      |              []         []       []       []     |
-     vorbis-tools       |                         []                       |
      wastesedge         |                                                  |
-     wdiff              |       []     []      [] []    [] []       []     |
-     wget               |          []             []    []          []     |
-     xchat              |    []                   []    [] [] [] [] []     |
-     xkeyboard-config   |                               [] []       []     |
-     xpad               |                               [] []       []     |
+     wdiff              |                                                  |
+     wget               |                       []                      [] |
+     wyslij-po          |                                                  |
+     xchat              |                []     []          []          [] |
+     xdg-user-dirs      | []    []    [] []     []    []    []  []      [] |
+     xkeyboard-config   |                                   []          [] |
                         +--------------------------------------------------+
-                          or pa pl pt pt_BR rm ro ru rw sk sl sq sr sv  ta
-                           0  5 77 31  53    4 58 72  3 45 46  9 45 122  3
+                          af am an ar as ast az be be at latin bg bn_IN bs ca
+                           6  0  1  2  3 19   1 10     3    28   3    1 38
+
+                          crh cs da  de  el en en_GB en_ZA eo es et eu fa
+                        +-------------------------------------------------+
+     a2ps               |     [] []  []  []     []            [] []       |
+     aegis              |        []  []                       []          |
+     ant-phone          |        []  ()                                   |
+     anubis             |        []  []                                   |
+     aspell             |     [] []  []         []            []          |
+     bash               |     []                           [] []          |
+     bfd                |                                     []          |
+     bibshelf           |        []  []                       []          |
+     binutils           |                                     []          |
+     bison              |            []  []                               |
+     bison-runtime      |        []  []  []                      []       |
+     bluez-pin          |     [] []  []  []                [] []          |
+     bombono-dvd        |        []                                       |
+     buzztard           |     [] []  []                                   |
+     cflow              |        []  []                                   |
+     clisp              |        []  []     []                []          |
+     coreutils          |     [] []  []                          []       |
+     cpio               |                                                 |
+     cppi               |                                                 |
+     cpplib             |        []  []                       []          |
+     cryptsetup         |            []                                   |
+     dfarc              |        []  []                       []          |
+     dialog             |        []  []                    [] []    []    |
+     dico               |                                                 |
+     diffutils          |     [] []  []  []                [] []          |
+     dink               |        []  []                       []          |
+     doodle             |            []                                   |
+     e2fsprogs          |     []     []                       []          |
+     enscript           |        []  []         []                        |
+     exif               |     () []  []                                   |
+     fetchmail          |     [] []  ()  []     []            []          |
+     findutils          |     [] []  []                                   |
+     flex               |            []                       []          |
+     freedink           |        []  []                       []          |
+     gas                |                                     []          |
+     gawk               |        []  []                       []          |
+     gcal               |                                     []          |
+     gcc                |            []                       []          |
+     gettext-examples   |            []  []                [] []          |
+     gettext-runtime    |        []  []                    [] []          |
+     gettext-tools      |            []                       []    []    |
+     gip                |        []  []                       []    []    |
+     gjay               |            []                                   |
+     gliv               |     [] []  []                                   |
+     glunarclock        |        []  []                                   |
+     gnubiff            |            ()                                   |
+     gnucash            |     []     ()  ()     ()            ()          |
+     gnuedu             |        []                           []          |
+     gnulib             |            []                       []          |
+     gnunet             |                                                 |
+     gnunet-gtk         |        []                                       |
+     gnutls             |     []     []                                   |
+     gold               |                                     []          |
+     gpe-aerial         |     [] []  []                       []          |
+     gpe-beam           |     [] []  []                       []          |
+     gpe-bluetooth      |        []  []                                   |
+     gpe-calendar       |        []                                       |
+     gpe-clock          |     [] []  []                       []          |
+     gpe-conf           |     [] []  []                                   |
+     gpe-contacts       |        []  []                       []          |
+     gpe-edit           |        []  []                                   |
+     gpe-filemanager    |        []  []                       []          |
+     gpe-go             |     [] []  []                       []          |
+     gpe-login          |        []  []                                   |
+     gpe-ownerinfo      |     [] []  []                       []          |
+     gpe-package        |        []  []                       []          |
+     gpe-sketchbook     |     [] []  []                       []          |
+     gpe-su             |     [] []  []                       []          |
+     gpe-taskmanager    |     [] []  []                       []          |
+     gpe-timesheet      |     [] []  []                       []          |
+     gpe-today          |     [] []  []                       []          |
+     gpe-todo           |        []  []                       []          |
+     gphoto2            |     [] []  ()         []            []    []    |
+     gprof              |        []  []                       []          |
+     gpsdrive           |        []                           [] []       |
+     gramadoir          |        []  []                    []             |
+     grep               |     []                                          |
+     grub               |        []  []                                   |
+     gsasl              |            []                                   |
+     gss                |                                                 |
+     gst-plugins-bad    |     [] []  []                       []    []    |
+     gst-plugins-base   |     [] []  []                       []    []    |
+     gst-plugins-good   |     [] []  []  []                   []    []    |
+     gst-plugins-ugly   |     [] []  []  []                   []    []    |
+     gstreamer          |     [] []  []                       []    []    |
+     gtick              |        []  ()                    []             |
+     gtkam              |     [] []  ()                    [] []          |
+     gtkorphan          |     [] []  []                    []             |
+     gtkspell           |     [] []  []  []                [] []    []    |
+     gutenprint         |        []  []         []                        |
+     hello              |        []  []                    [] []          |
+     help2man           |            []                                   |
+     hylafax            |            []                       []          |
+     idutils            |        []  []                                   |
+     indent             |     [] []  []                    [] [] [] []    |
+     iso_15924          |        []      ()                [] []          |
+     iso_3166           | []  [] []  []  ()                [] [] [] ()    |
+     iso_3166_2         |                ()                               |
+     iso_4217           |     [] []  []  ()                   [] []       |
+     iso_639            | []  [] []  []  ()                [] []          |
+     iso_639_3          | []                                              |
+     jwhois             |                                     []          |
+     kbd                |     [] []  []  []                   []          |
+     keytouch           |        []  []                                   |
+     keytouch-editor    |        []  []                                   |
+     keytouch-keyboa... |        []                                       |
+     klavaro            |     [] []  []                    []             |
+     latrine            |        []  ()                                   |
+     ld                 |        []                           []          |
+     leafpad            |     [] []  []  []                   []    []    |
+     libc               |     [] []  []                       []          |
+     libexif            |        []  []         ()                        |
+     libextractor       |                                                 |
+     libgnutls          |     []                                          |
+     libgpewidget       |        []  []                                   |
+     libgpg-error       |     []     []                                   |
+     libgphoto2         |        []  ()                                   |
+     libgphoto2_port    |        []  ()                             []    |
+     libgsasl           |                                                 |
+     libiconv           |     [] []  []                    []    []       |
+     libidn             |     []     []                    []             |
+     lifelines          |        []  ()                                   |
+     liferea            |     []     []  []                   []    []    |
+     lilypond           |     []     []                       []          |
+     linkdr             |        []  []                       []          |
+     lordsawar          |        []                                       |
+     lprng              |                                                 |
+     lynx               |     [] []  []                          []       |
+     m4                 |     [] []  []  []                               |
+     mailfromd          |                                                 |
+     mailutils          |                                     []          |
+     make               |        []  []                       []          |
+     man-db             |                                                 |
+     man-db-manpages    |                                                 |
+     minicom            |     [] []  []                       []          |
+     mkisofs            |                                                 |
+     myserver           |                                                 |
+     nano               |            []                       []    []    |
+     opcodes            |            []                       []          |
+     parted             |     []     []                                   |
+     pies               |                                                 |
+     popt               |     [] []  []                    [] []          |
+     psmisc             |     []     []                             []    |
+     pspp               |                                     []          |
+     pwdutils           |        []                                       |
+     radius             |                                     []          |
+     recode             |     [] []  []  []                [] []          |
+     rosegarden         |     ()     ()                       ()          |
+     rpm                |        []  []                       []          |
+     rush               |                                                 |
+     sarg               |                                                 |
+     screem             |                                                 |
+     scrollkeeper       |     [] []  []         []            []          |
+     sed                |     []     []  []                [] [] []       |
+     sharutils          |        []  []                       [] []       |
+     shishi             |                                                 |
+     skencil            |        []  ()                       []          |
+     solfege            |            []                    []    []       |
+     solfege-manual     |                                  []    []       |
+     soundtracker       |        []  []                       []          |
+     sp                 |            []                                   |
+     sysstat            |        []  []                             []    |
+     tar                |     []     []                          [] []    |
+     texinfo            |            []                    [] []          |
+     tin                |            []                          []       |
+     unicode-han-tra... |                                                 |
+     unicode-transla... |                                                 |
+     util-linux-ng      |     [] []  []                       []          |
+     vice               |        ()  ()                                   |
+     vmm                |            []                                   |
+     vorbis-tools       |     []                           []             |
+     wastesedge         |        []                                       |
+     wdiff              |            []                       []          |
+     wget               |     []     []                          []       |
+     wyslij-po          |                                                 |
+     xchat              |     []     []  []                   [] []       |
+     xdg-user-dirs      | []  [] []  []  []                [] [] [] []    |
+     xkeyboard-config   | []  [] []  []                    [] []          |
+                        +-------------------------------------------------+
+                          crh cs da  de  el en en_GB en_ZA eo es et eu fa
+                           5  64 105 117 18  1   8     0   28 89 18 19  0
+
+                          fi  fr  ga gl gu he hi hr hu hy id  is it ja ka kn
+                        +----------------------------------------------------+
+     a2ps               | []  []                          []        []       |
+     aegis              |     []                                 []          |
+     ant-phone          |     []                                 []          |
+     anubis             | []  []                          []     []          |
+     aspell             |     []  []                      []     []          |
+     bash               | []  []                          []        []       |
+     bfd                | []  []                          []                 |
+     bibshelf           | []  []  []                      []     []          |
+     binutils           | []  []                          []                 |
+     bison              | []  []  []                      []                 |
+     bison-runtime      | []  []  []                      []     [] []       |
+     bluez-pin          | []  []  []                [] [] []  []    []       |
+     bombono-dvd        | []                                                 |
+     buzztard           |                                 []                 |
+     cflow              | []      []                      []                 |
+     clisp              |     []                                             |
+     coreutils          |     []  []                []    []     []          |
+     cpio               | []  []  []                      []                 |
+     cppi               | []  []                                             |
+     cpplib             | []  []                          []                 |
+     cryptsetup         |     []                          []     []          |
+     dfarc              | []  []                                 []          |
+     dialog             |     []  [] []                   []  [] [] []       |
+     dico               |                                                    |
+     diffutils          | []  []  [] []    []       []    []     [] []       |
+     dink               |     []                                             |
+     doodle             |         []                             []          |
+     e2fsprogs          |     []                          []                 |
+     enscript           |     []  []             []       []                 |
+     exif               | []  []                          []  [] [] []       |
+     fetchmail          |     []                          []     [] []       |
+     findutils          | []  []  []                []    []     []          |
+     flex               | []  []  []                                         |
+     freedink           | []  []                          []                 |
+     gas                |     []                          []                 |
+     gawk               |     []  []       []             []     () []       |
+     gcal               |     []                                             |
+     gcc                |                                 []                 |
+     gettext-examples   | []  []  []                []    []     [] []       |
+     gettext-runtime    | []  []  []                      []     [] []       |
+     gettext-tools      |     []                          []     [] []       |
+     gip                | []  []  [] []                   []        []       |
+     gjay               | []                                                 |
+     gliv               | []  ()                                             |
+     glunarclock        | []      []                []    []                 |
+     gnubiff            |     ()                          []     ()          |
+     gnucash            | ()  ()           ()       ()           () []       |
+     gnuedu             |     []                                 []          |
+     gnulib             | []  []  []                []           [] []       |
+     gnunet             |                                                    |
+     gnunet-gtk         |     []                                             |
+     gnutls             |     []                                 []          |
+     gold               | []                              []                 |
+     gpe-aerial         | []  []                          []                 |
+     gpe-beam           | []  []                          []        []       |
+     gpe-bluetooth      | []                              []     [] []       |
+     gpe-calendar       | []                                        []       |
+     gpe-clock          | []  []                    []    []        []       |
+     gpe-conf           | []  []                          []        []       |
+     gpe-contacts       | []  []                          []        []       |
+     gpe-edit           | []                              []        []       |
+     gpe-filemanager    | []                        []    []        []       |
+     gpe-go             | []  []                    []    []        []       |
+     gpe-login          | []                              []        []       |
+     gpe-ownerinfo      | []  []                    []    []        []       |
+     gpe-package        | []                              []        []       |
+     gpe-sketchbook     | []  []                          []        []       |
+     gpe-su             | []  []     []             []    []        []       |
+     gpe-taskmanager    | []  []                    []    []        []       |
+     gpe-timesheet      | []  []  []                      []        []       |
+     gpe-today          | []  []  [] []             []    []        []       |
+     gpe-todo           | []                              []        []       |
+     gphoto2            | []  []                    []    []     [] []       |
+     gprof              | []  []  []                      []                 |
+     gpsdrive           |            []                   []     []          |
+     gramadoir          |     []  []                      []                 |
+     grep               | []                                     []          |
+     grub               | []                        []    []     []          |
+     gsasl              | []  []  []                      []     []          |
+     gss                | []  []  []                      []     []          |
+     gst-plugins-bad    | []  []                    []    []     [] []       |
+     gst-plugins-base   | []  []                    []    []     [] []       |
+     gst-plugins-good   | []  []                    []    []     [] []       |
+     gst-plugins-ugly   | []  []                    []    []     [] []       |
+     gstreamer          | []  []                    []    []     []          |
+     gtick              | []  []  []                      []     []          |
+     gtkam              |     []                    []    []     [] []       |
+     gtkorphan          |     []                          []     []          |
+     gtkspell           | []  []  [] []             [] [] []     [] []       |
+     gutenprint         | []  []                    []           []          |
+     hello              | []      []                      []                 |
+     help2man           | []  []                                             |
+     hylafax            |                                 []                 |
+     idutils            | []  []  []                []    []     []          |
+     indent             | []  []  [] []             []    []     [] []       |
+     iso_15924          | []  ()                          []     []          |
+     iso_3166           | []  ()  [] [] [] [] [] [] []    []     [] []       |
+     iso_3166_2         |     ()                    []    []     []          |
+     iso_4217           | []  ()                    []    []     [] []       |
+     iso_639            | []  ()  []    []          []    []     [] []    [] |
+     iso_639_3          |     ()                                 []       [] |
+     jwhois             | []  []                    []    []     []          |
+     kbd                |     []                          []                 |
+     keytouch           | []  []  []                []    []     []          |
+     keytouch-editor    | []      []                []    []     []          |
+     keytouch-keyboa... | []      []                []    []     []          |
+     klavaro            |            []             []                       |
+     latrine            | []                              []     []          |
+     ld                 | []  []  []                      []                 |
+     leafpad            | []  []  []       []       []    []     [] ()       |
+     libc               | []  []     []                   []        []       |
+     libexif            |                                        []          |
+     libextractor       |                                                    |
+     libgnutls          |     []                                 []          |
+     libgpewidget       | []      []                      []        []       |
+     libgpg-error       |     []                                 []          |
+     libgphoto2         |     []                                 [] []       |
+     libgphoto2_port    |     []                                 [] []       |
+     libgsasl           | []  []  []                      []     []          |
+     libiconv           | []  []  []                      []     [] []       |
+     libidn             | []  []                          []     []          |
+     lifelines          |     ()                                             |
+     liferea            |     []                    []           [] []       |
+     lilypond           | []  []                                             |
+     linkdr             | []               []    [] []           []          |
+     lordsawar          |                                                    |
+     lprng              |                                 []                 |
+     lynx               |     []                    []    []     [] []       |
+     m4                 | []  []  [] []                   []        []       |
+     mailfromd          |                                                    |
+     mailutils          |     []                          []                 |
+     make               | []  []  [] []    []    []       []     [] []       |
+     man-db             |                                 []     []          |
+     man-db-manpages    |                                 []                 |
+     minicom            | []  []                    []    []        []       |
+     mkisofs            | []  []                          []     []          |
+     myserver           |                                                    |
+     nano               | []  []  [] []             []           []          |
+     opcodes            | []  []  []                      []                 |
+     parted             |     []                          []     [] []       |
+     pies               |                                                    |
+     popt               | []  []  [] []             []    []  [] [] []       |
+     psmisc             | []  []                          []                 |
+     pspp               |                                                    |
+     pwdutils           |     []                          []                 |
+     radius             |     []                          []                 |
+     recode             | []  []  [] []    []       []    []     []          |
+     rosegarden         | ()  ()                          ()     () ()       |
+     rpm                |                                 []        []       |
+     rush               |                                                    |
+     sarg               |     []                                             |
+     screem             |                                        [] []       |
+     scrollkeeper       | []                        []    []     []          |
+     sed                | []  []  [] []             []    []     [] []       |
+     sharutils          | []  []  []                []    []     [] []       |
+     shishi             |     []                                             |
+     skencil            |     []                                             |
+     solfege            | []  []     []                          []          |
+     solfege-manual     |     []     []                                      |
+     soundtracker       |     []                                 []          |
+     sp                 |     []                                    ()       |
+     sysstat            | []  []                          []     [] []       |
+     tar                | []  []  []                []    []     [] []       |
+     texinfo            |     []                          []     [] []       |
+     tin                |     []                                             |
+     unicode-han-tra... |                                                    |
+     unicode-transla... |     []  []                                         |
+     util-linux-ng      | []  []                    []    []     [] []       |
+     vice               |     ()                    ()           ()          |
+     vmm                |     []                                             |
+     vorbis-tools       |                                 []                 |
+     wastesedge         |     ()                                 ()          |
+     wdiff              | []                                                 |
+     wget               | []  []  []             [] []    []     [] []       |
+     wyslij-po          | []  []                          []                 |
+     xchat              | []  []        []    []    []    []     [] []    [] |
+     xdg-user-dirs      | []  []  [] [] [] [] []    []    []  [] [] []    [] |
+     xkeyboard-config   | []  []                    []    []     []          |
+                        +----------------------------------------------------+
+                          fi  fr  ga gl gu he hi hr hu hy id  is it ja ka kn
+                          105 121 53 20  4  8  3  5 53  2 120  5 84 67  0  4
+
+                          ko ku ky lg lt lv mk ml mn mr ms mt nb nds ne
+                        +-----------------------------------------------+
+     a2ps               |                               []              |
+     aegis              |                                               |
+     ant-phone          |                                               |
+     anubis             |                               []    []        |
+     aspell             |                         []                    |
+     bash               |                                               |
+     bfd                |                                               |
+     bibshelf           |                []             []              |
+     binutils           |                                               |
+     bison              |                               []              |
+     bison-runtime      |       []    [] []             []    []        |
+     bluez-pin          |    [] []    [] []             []              |
+     bombono-dvd        |                                               |
+     buzztard           |                                               |
+     cflow              |                                               |
+     clisp              |                                               |
+     coreutils          |          []                                   |
+     cpio               |                                               |
+     cppi               |                                               |
+     cpplib             |                                               |
+     cryptsetup         |                                               |
+     dfarc              |                   []                          |
+     dialog             |    []       [] []             []    []        |
+     dico               |                                               |
+     diffutils          |                []             []              |
+     dink               |                                               |
+     doodle             |                                               |
+     e2fsprogs          |                                               |
+     enscript           |                                               |
+     exif               |                []                             |
+     fetchmail          |                                               |
+     findutils          |                                               |
+     flex               |                                               |
+     freedink           |                                     []        |
+     gas                |                                               |
+     gawk               |                                               |
+     gcal               |                                               |
+     gcc                |                                               |
+     gettext-examples   |       []       []             [] []           |
+     gettext-runtime    | []                                            |
+     gettext-tools      | []                                            |
+     gip                |                []             []              |
+     gjay               |                                               |
+     gliv               |                                               |
+     glunarclock        |                []                             |
+     gnubiff            |                                               |
+     gnucash            | ()          ()                      ()     () |
+     gnuedu             |                                               |
+     gnulib             |                                               |
+     gnunet             |                                               |
+     gnunet-gtk         |                                               |
+     gnutls             |                               []              |
+     gold               |                                               |
+     gpe-aerial         |                []                             |
+     gpe-beam           |                []                             |
+     gpe-bluetooth      |                []                []           |
+     gpe-calendar       |                []                             |
+     gpe-clock          | []    []       []             [] []           |
+     gpe-conf           | []             []                             |
+     gpe-contacts       | []             []                             |
+     gpe-edit           |                []                             |
+     gpe-filemanager    | []             []                             |
+     gpe-go             | []             []                []           |
+     gpe-login          |                []                             |
+     gpe-ownerinfo      |                []             []              |
+     gpe-package        | []             []                             |
+     gpe-sketchbook     | []             []                             |
+     gpe-su             | []    []       []             [] [] []        |
+     gpe-taskmanager    | [] [] []       []             [] []           |
+     gpe-timesheet      |                []             []              |
+     gpe-today          |       []       []             [] []           |
+     gpe-todo           |                []                   []        |
+     gphoto2            |                                               |
+     gprof              |                               []              |
+     gpsdrive           |                                               |
+     gramadoir          |                                               |
+     grep               |                                               |
+     grub               |                                               |
+     gsasl              |                                               |
+     gss                |                                               |
+     gst-plugins-bad    |             [] []                [] []        |
+     gst-plugins-base   |             [] []                             |
+     gst-plugins-good   |                []                []           |
+     gst-plugins-ugly   |             [] []             [] [] []        |
+     gstreamer          |                                               |
+     gtick              |                                               |
+     gtkam              |                                     []        |
+     gtkorphan          |                []                      []     |
+     gtkspell           |       []    [] []       []    []    [] []     |
+     gutenprint         |                                               |
+     hello              | []             []             []              |
+     help2man           |                                               |
+     hylafax            |                                               |
+     idutils            |                                               |
+     indent             |                                               |
+     iso_15924          |             [] []                             |
+     iso_3166           | [] []       () [] [] []    []       []        |
+     iso_3166_2         |                                               |
+     iso_4217           |             []                      []        |
+     iso_639            |                      []    []                 |
+     iso_639_3          |                            []                 |
+     jwhois             |                []                             |
+     kbd                |                                               |
+     keytouch           |                []                             |
+     keytouch-editor    |                []                             |
+     keytouch-keyboa... |                []                             |
+     klavaro            |                                     []        |
+     latrine            |                []                             |
+     ld                 |                                               |
+     leafpad            | []          [] []                             |
+     libc               | []                                            |
+     libexif            |                                               |
+     libextractor       |                                               |
+     libgnutls          |                               []              |
+     libgpewidget       |                []             []              |
+     libgpg-error       |                                               |
+     libgphoto2         |                                               |
+     libgphoto2_port    |                                               |
+     libgsasl           |                                               |
+     libiconv           |                                               |
+     libidn             |                                               |
+     lifelines          |                                               |
+     liferea            |                                               |
+     lilypond           |                                               |
+     linkdr             |                                               |
+     lordsawar          |                                               |
+     lprng              |                                               |
+     lynx               |                                               |
+     m4                 |                                               |
+     mailfromd          |                                               |
+     mailutils          |                                               |
+     make               | []                                            |
+     man-db             |                                               |
+     man-db-manpages    |                                               |
+     minicom            |                                     []        |
+     mkisofs            |                                               |
+     myserver           |                                               |
+     nano               |                               []    []        |
+     opcodes            |                                               |
+     parted             |                                               |
+     pies               |                                               |
+     popt               | []             []                   []        |
+     psmisc             |                                               |
+     pspp               |                                               |
+     pwdutils           |                                               |
+     radius             |                                               |
+     recode             |                                               |
+     rosegarden         |                                               |
+     rpm                |                                               |
+     rush               |                                               |
+     sarg               |                                               |
+     screem             |                                               |
+     scrollkeeper       |                                     []     [] |
+     sed                |                                               |
+     sharutils          |                                               |
+     shishi             |                                               |
+     skencil            |                                               |
+     solfege            |                                     []        |
+     solfege-manual     |                                               |
+     soundtracker       |                                               |
+     sp                 |                                               |
+     sysstat            |                []                             |
+     tar                |       []                                      |
+     texinfo            |                                     []        |
+     tin                |                                               |
+     unicode-han-tra... |                                               |
+     unicode-transla... |                                               |
+     util-linux-ng      |                                               |
+     vice               |                                               |
+     vmm                |                                               |
+     vorbis-tools       |                                               |
+     wastesedge         |                                               |
+     wdiff              |                                               |
+     wget               |             []                                |
+     wyslij-po          |                                               |
+     xchat              | []             [] []                          |
+     xdg-user-dirs      | [] []       [] [] []       []       [] []     |
+     xkeyboard-config   | []    []    []                                |
+                        +-----------------------------------------------+
+                          ko ku ky lg lt lv mk ml mn mr ms mt nb nds ne
+                          20  5 10  1 13 48  4  2  2  4 24 10 20  3   1
+
+                          nl  nn or pa pl  ps pt pt_BR ro ru rw sk sl sq sr
+                        +---------------------------------------------------+
+     a2ps               | []           []     []  []   [] []       []    [] |
+     aegis              | []                      []      []                |
+     ant-phone          |                         []   []                   |
+     anubis             | []           []                 []                |
+     aspell             | []                           [] []    [] []       |
+     bash               | []                                    []          |
+     bfd                |                                 []                |
+     bibshelf           | []  []                                            |
+     binutils           |                                 []    []          |
+     bison              | []           []                 []                |
+     bison-runtime      | []           []     []  []   [] []       []       |
+     bluez-pin          | []           []         []   [] []    [] []    [] |
+     bombono-dvd        |     []                          ()                |
+     buzztard           | []  []                                            |
+     cflow              |              []                                   |
+     clisp              | []                              []                |
+     coreutils          | []           []     []  []      []       []       |
+     cpio               | []           []                 []                |
+     cppi               |              []                                   |
+     cpplib             | []                                                |
+     cryptsetup         | []                                                |
+     dfarc              |              []                                   |
+     dialog             | []           []         []      []                |
+     dico               |              []                                   |
+     diffutils          | []           []         []   [] []             [] |
+     dink               | ()                                                |
+     doodle             | []                                          []    |
+     e2fsprogs          | []           []                                   |
+     enscript           | []                      []   [] []       []       |
+     exif               | []           []              [] ()    []          |
+     fetchmail          | []           []                 []          []    |
+     findutils          | []           []     []          []       []       |
+     flex               | []           []         []   [] []                |
+     freedink           | []           []                                   |
+     gas                |                                                   |
+     gawk               | []           []         []   []                   |
+     gcal               |                                                   |
+     gcc                |                                                [] |
+     gettext-examples   | []           []     []       [] []    [] []    [] |
+     gettext-runtime    | []  []       []     []       [] []    [] []    [] |
+     gettext-tools      |              []              [] []    [] []    [] |
+     gip                | []           []                 []    []       [] |
+     gjay               |                                                   |
+     gliv               | []           []         []   [] []    []          |
+     glunarclock        | []                      []   []       []       [] |
+     gnubiff            | []                           ()                   |
+     gnucash            | []           ()         ()      ()                |
+     gnuedu             | []                                                |
+     gnulib             | []           []                 []       []       |
+     gnunet             |                                                   |
+     gnunet-gtk         |                                                   |
+     gnutls             | []           []                                   |
+     gold               |                                                   |
+     gpe-aerial         | []                  []  []   [] []       []    [] |
+     gpe-beam           | []                  []  []   [] []       []    [] |
+     gpe-bluetooth      | []                      []                        |
+     gpe-calendar       |                         []      []       []    [] |
+     gpe-clock          | []                  []  []   [] []    [] []    [] |
+     gpe-conf           | []                  []  []   [] []    [] []       |
+     gpe-contacts       |                         []   [] []       []    [] |
+     gpe-edit           | []           []                          []       |
+     gpe-filemanager    | []                              []       []       |
+     gpe-go             | []           []         []   [] []    [] []    [] |
+     gpe-login          | []                      []                        |
+     gpe-ownerinfo      | []                  []  []   [] []    [] []    [] |
+     gpe-package        | []                                       []       |
+     gpe-sketchbook     | []                  []  []   [] []       []    [] |
+     gpe-su             | []                  []  []   [] []    [] []    [] |
+     gpe-taskmanager    | []                  []  []   [] []    [] []    [] |
+     gpe-timesheet      | []                  []  []   [] []    [] []    [] |
+     gpe-today          | []                  []  []   [] []    [] []    [] |
+     gpe-todo           | []                      []      []       []    [] |
+     gphoto2            | []        [] []         []   [] []    []       [] |
+     gprof              | []                      []   []                   |
+     gpsdrive           | []                              []                |
+     gramadoir          | []                                    []          |
+     grep               | []           []                 []    []          |
+     grub               | []           []                 []                |
+     gsasl              | []           []                       []       [] |
+     gss                |              []              []       []          |
+     gst-plugins-bad    | []           []         []      []    []    []    |
+     gst-plugins-base   | []           []         []      []    []          |
+     gst-plugins-good   | []           []         []      []    []          |
+     gst-plugins-ugly   | []           []         []      []    [] []       |
+     gstreamer          | []           []         []      []    []          |
+     gtick              | []                              []    []          |
+     gtkam              | []        [] []         []      []    []          |
+     gtkorphan          | []                                                |
+     gtkspell           | []           []     []  []   [] []    [] [] [] [] |
+     gutenprint         | []                              []                |
+     hello              | []           []                       [] []       |
+     help2man           |              []                 []                |
+     hylafax            | []                                                |
+     idutils            | []           []         []   [] []                |
+     indent             | []           []         []   [] []    []       [] |
+     iso_15924          | []           []                 []       []       |
+     iso_3166           | []  [] [] [] []     ()  []   [] [] [] [] [] [] [] |
+     iso_3166_2         | []           []                          []       |
+     iso_4217           | []  []       []     []          [] []    []    [] |
+     iso_639            | []     [] [] []                 [] [] [] []    [] |
+     iso_639_3          |        [] []                                      |
+     jwhois             | []           []         []   []                   |
+     kbd                | []           []              []                   |
+     keytouch           | []           []                       []          |
+     keytouch-editor    | []           []                       []          |
+     keytouch-keyboa... | []           []                       []          |
+     klavaro            | []                      []                        |
+     latrine            |              []                 []                |
+     ld                 |                                                   |
+     leafpad            | []  []       []     []  []      []    [] []    [] |
+     libc               | []           []                 []    []          |
+     libexif            | []           []         ()            []          |
+     libextractor       |                                                   |
+     libgnutls          | []           []                                   |
+     libgpewidget       | []           []                          []       |
+     libgpg-error       |              []              []                   |
+     libgphoto2         | []           []                                   |
+     libgphoto2_port    | []           []         []      []    []          |
+     libgsasl           | []           []              []       []       [] |
+     libiconv           | []           []                       [] []    [] |
+     libidn             | []           []                                   |
+     lifelines          | []           []                                   |
+     liferea            | []           []     []  []   [] ()    ()    []    |
+     lilypond           | []                                                |
+     linkdr             | []                  []          []                |
+     lordsawar          |                                                   |
+     lprng              |              []                                   |
+     lynx               | []                      []      []                |
+     m4                 | []           []         []   [] []                |
+     mailfromd          |              []                                   |
+     mailutils          |              []                                   |
+     make               | []           []         []      []                |
+     man-db             | []           []                 []                |
+     man-db-manpages    | []           []                 []                |
+     minicom            |              []         []   [] []                |
+     mkisofs            | []           []                 []                |
+     myserver           |                                                   |
+     nano               | []           []         []      []                |
+     opcodes            | []                           []                   |
+     parted             | []           []                 []    []          |
+     pies               |              []                                   |
+     popt               | []           []     []          []                |
+     psmisc             | []           []                 []                |
+     pspp               | []                      []                        |
+     pwdutils           |              []                                   |
+     radius             | []           []                 []                |
+     recode             | []           []     []  []   [] []    [] []       |
+     rosegarden         |              ()                 ()                |
+     rpm                | []           []     []                            |
+     rush               | []           []                                   |
+     sarg               |                                                   |
+     screem             |                                                   |
+     scrollkeeper       | []  []       []              [] []    []    [] [] |
+     sed                | []           []     []  []   [] []    [] []    [] |
+     sharutils          | []           []                 []             [] |
+     shishi             |              []                                   |
+     skencil            |                     []  []                        |
+     solfege            | []           []         []      []                |
+     solfege-manual     | []           []         []                        |
+     soundtracker       |                                       []          |
+     sp                 |                                                   |
+     sysstat            | []           []         []      []                |
+     tar                | []           []                 []       []       |
+     texinfo            | []           []              [] []                |
+     tin                |                                 []                |
+     unicode-han-tra... |                                                   |
+     unicode-transla... |                                                   |
+     util-linux-ng      | []           []         []      []       []       |
+     vice               | []                                                |
+     vmm                | []                                                |
+     vorbis-tools       | []           []                                   |
+     wastesedge         | []                                                |
+     wdiff              | []           []                                   |
+     wget               | []           []     []  []      []    [] []       |
+     wyslij-po          | []  []       []                                   |
+     xchat              | []        [] []     []          []    [] [] [] [] |
+     xdg-user-dirs      | []  [] [] [] []  [] []  []   [] []    [] [] [] [] |
+     xkeyboard-config   | []           []                 []                |
+                        +---------------------------------------------------+
+                          nl  nn or pa pl  ps pt pt_BR ro ru rw sk sl sq sr
+                          135 10  4  7 105  1 29  62   47 91  3 54 46  9 37
 
-                          tg th tk tr uk ven vi  wa xh zh_CN zh_HK zh_TW zu
+                          sv  sw ta te tg th tr uk vi  wa zh_CN zh_HK zh_TW
                         +---------------------------------------------------+
-     Compendium         |          []        []         []          []      | 19
-     a2ps               |          [] []     []                             | 19
-     aegis              |                    []                             |  1
-     ant-phone          |          []        []                             |  6
-     anubis             |          [] []     []                             | 11
-     ap-utils           |             ()     []                             |  4
-     aspell             |             []     []  []                         | 16
-     bash               |          []                                       |  6
-     bfd                |                                                   |  2
-     bibshelf           |                    []                             |  7
-     binutils           |          [] []     []                     []      |  9
-     bison              |          [] []     []                     []      | 20
-     bison-runtime      |             []     []         []          []      | 18
-     bluez-pin          |          [] []     []  []     []          []      | 28
-     cflow              |             []     []                             |  5
-     clisp              |                                                   |  9
-     console-tools      |          []        []                             |  5
-     coreutils          |          [] []     []                             | 18
-     cpio               |          [] []     []         []                  | 11
-     cpplib             |          [] []     []         []          []      | 12
-     cryptonit          |                    []                             |  6
-     dialog             |                    []  []     []                  |  9
-     diffutils          |          [] []     []         []          []      | 29
-     doodle             |                    []                             |  6
-     e2fsprogs          |          []        []                             | 10
-     enscript           |          [] []     []                             | 16
-     fetchmail          |          []        []                             | 12
-     findutils          |          [] []     []                             | 11
-     findutils_stable   |          [] []     []                     []      | 18
-     flex               |          []        []                             | 15
-     fslint             |                    []                             |  2
-     gas                |          []                                       |  3
-     gawk               |          []        []         []                  | 16
-     gcal               |          []                                       |  5
-     gcc                |          []                   []          []      |  7
-     gettext-examples   |          [] []     []         []    []    []      | 29
-     gettext-runtime    |          [] []     []         []    []    []      | 28
-     gettext-tools      |          [] []     []         []          []      | 20
-     gip                |                    []                     []      | 13
-     gliv               |          []        []                             | 11
-     glunarclock        |                    []  []                 []      | 15
-     gmult              |          []        []         []          []      | 16
-     gnubiff            |                    []                             |  2
-     gnucash            |          () []                                    |  5
-     gnuedu             |                    []                             |  2
-     gnulib             |                    []                             | 10
-     gnunet             |                                                   |  0
-     gnunet-gtk         |          []        []                             |  3
-     gnutls             |                                                   |  4
-     gpe-aerial         |                    []         []                  | 14
-     gpe-beam           |                    []         []                  | 14
-     gpe-calendar       |                    []  []                         |  7
-     gpe-clock          |          []        []  []     []                  | 21
-     gpe-conf           |                    []  []     []                  | 16
-     gpe-contacts       |                    []         []                  | 10
-     gpe-edit           |          []        []  []     []          []      | 22
-     gpe-filemanager    |                    []  []                         |  7
-     gpe-go             |          []        []  []     []                  | 19
-     gpe-login          |          []        []  []     []          []      | 21
-     gpe-ownerinfo      |          []        []         []          []      | 21
-     gpe-package        |                    []                             |  6
-     gpe-sketchbook     |          []        []                             | 16
-     gpe-su             |          []        []  []     []                  | 21
-     gpe-taskmanager    |          []        []  []     []                  | 21
-     gpe-timesheet      |          []        []         []          []      | 18
-     gpe-today          |          []        []  []     []          []      | 21
-     gpe-todo           |                    []  []                         |  8
-     gphoto2            |             []     []         []          []      | 21
-     gprof              |          []        []                             | 13
-     gpsdrive           |                    []                             |  5
-     gramadoir          |                    []                             |  7
-     grep               |                    []                             | 12
-     gretl              |                                                   |  6
-     gsasl              |                    []         []          []      |  9
-     gss                |                    []                             |  7
-     gst-plugins-bad    |             []     []         []                  | 13
-     gst-plugins-base   |             []     []                             | 11
-     gst-plugins-good   |             []     []         []    []    []      | 16
-     gst-plugins-ugly   |             []     []         []                  | 13
-     gstreamer          |          [] []     []                             | 18
-     gtick              |             []     []                             |  7
-     gtkam              |                    []                             | 16
-     gtkorphan          |                    []                             |  7
-     gtkspell           |             []     []  []     []    []    []      | 27
-     gutenprint         |                                                   |  4
-     hello              |          [] []     []         []          []      | 38
-     herrie             |          []        []                             |  8
-     hylafax            |                                                   |  0
-     idutils            |          []        []                             | 15
-     indent             |          [] []     []         []          []      | 28
-     iso_15924          |                    []         []                  |  4
-     iso_3166           |    [] [] [] []     []  []     []    []    []      | 54
-     iso_3166_2         |                    []         []                  |  4
-     iso_4217           |    []    []        []         []    []            | 24
-     iso_639            |             []     []  []     []    []            | 26
-     jpilot             |          [] []     []         []                  |  7
-     jtag               |                    []                             |  3
-     jwhois             |          []        []                     []      | 13
-     kbd                |          [] []     []                             | 13
-     keytouch           |                    []                             |  8
-     keytouch-editor    |                    []                             |  5
-     keytouch-keyboa... |                    []                             |  5
-     latrine            |          []        []                             |  5
-     ld                 |          []        []         []          []      | 10
-     leafpad            |          [] []     []         []          []      | 24
-     libc               |          []                   []          []      | 19
-     libexif            |                    []                             |  5
-     libextractor       |                    []                             |  5
-     libgpewidget       |                    []  []     []                  | 20
-     libgpg-error       |                    []                             |  6
-     libgphoto2         |             []     []                             |  9
-     libgphoto2_port    |             []     []                     []      | 11
-     libgsasl           |                    []                             |  8
-     libiconv           |                    []  []                         | 11
-     libidn             |                    []         []                  | 11
-     lifelines          |                                                   |  4
-     lilypond           |                    []                             |  6
-     lingoteach         |                    []                             |  6
-     lprng              |                    []                             |  2
-     lynx               |          [] []     []                             | 15
-     m4                 |                    []         []          []      | 18
-     mailfromd          |             []     []                             |  3
-     mailutils          |             []     []                             |  8
-     make               |          []        []         []                  | 20
-     man-db             |                    []                             |  9
-     minicom            |                    []                             | 14
-     nano               |                    []         []          []      | 20
-     opcodes            |          []        []                             | 10
-     parted             |          [] []                            []      | 11
-     pilot-qof          |                    []                             |  1
-     popt               |          []        []         []          []      | 18
-     psmisc             |                    []         []                  | 10
-     pwdutils           |                    []                             |  3
-     qof                |                    []                             |  4
-     radius             |             []     []                             |  7
-     recode             |          []        []         []                  | 25
-     rpm                |          [] []     []                     []      | 13
-     screem             |                    []                             |  2
-     scrollkeeper       |          [] []     []                     []      | 26
-     sed                |          []        []         []          []      | 23
-     shared-mime-info   |             []     []         []                  | 29
-     sharutils          |          []        []                     []      | 23
-     shishi             |                    []                             |  3
-     skencil            |                    []                             |  7
-     solfege            |                    []                             |  3
-     soundtracker       |          []        []                             |  9
-     sp                 |          []                                       |  3
-     system-tools-ba... |    []    [] []     []     []  []          []      | 38
-     tar                |          [] []     []                             | 17
-     texinfo            |          []        []         []                  | 15
-     tin                |                                                   |  1
-     tuxpaint           |                    []  []                 []      | 19
+     a2ps               | []              [] [] [] []                       | 27
+     aegis              |                          []                       |  9
+     ant-phone          | []                 []    []      []               |  9
+     anubis             | []                 [] [] []                       | 15
+     aspell             |                       [] []  []                   | 20
+     bash               | []                    [] []                       | 12
+     bfd                |                          []                       |  6
+     bibshelf           | []                       []      []               | 16
+     binutils           |                       [] []                       |  8
+     bison              | []                       []                       | 12
+     bison-runtime      | []              []    [] []      []          []   | 29
+     bluez-pin          | []              [] [] [] []  []  []          []   | 37
+     bombono-dvd        |                          []                       |  4
+     buzztard           |                          []                       |  7
+     cflow              |                       [] []      []               |  9
+     clisp              |                                                   | 10
+     coreutils          | []                    [] []      []               | 22
+     cpio               | []                 [] [] []      []          []   | 13
+     cppi               |                       [] []                       |  5
+     cpplib             | []                 [] [] []      []          []   | 14
+     cryptsetup         | []                       []                       |  7
+     dfarc              |                          []                       |  9
+     dialog             | []  []          []       []  []  []          []   | 30
+     dico               |                       []                          |  2
+     diffutils          | []                 [] [] []      []          []   | 30
+     dink               |                                                   |  4
+     doodle             | []                       []                       |  7
+     e2fsprogs          | []                 []    []                       | 11
+     enscript           | []                 [] [] []                       | 17
+     exif               | []                       []      []               | 16
+     fetchmail          |                    []    []      []               | 17
+     findutils          | []                 [] [] []      []               | 20
+     flex               | []                 []    []                  []   | 15
+     freedink           |                          []                       | 10
+     gas                |                    []                             |  4
+     gawk               | []                 []    []      []               | 18
+     gcal               | []                 []                             |  5
+     gcc                | []                 []            []               |  7
+     gettext-examples   | []                 [] [] []      []    []    []   | 34
+     gettext-runtime    | []                 [] [] []      []    []    []   | 29
+     gettext-tools      | []                 [] [] []      []          []   | 22
+     gip                | []                       []      []          []   | 22
+     gjay               |                          []                       |  3
+     gliv               | []                 []    []                       | 14
+     glunarclock        | []                       []  []  []          []   | 19
+     gnubiff            | []                       []                       |  4
+     gnucash            |                    () [] ()      []          ()   | 10
+     gnuedu             |                          []                  []   |  7
+     gnulib             | []                    [] []      []               | 16
+     gnunet             |                          []                       |  1
+     gnunet-gtk         | []                 []    []                       |  5
+     gnutls             | []                       []      []               | 10
+     gold               |                          []                       |  4
+     gpe-aerial         | []                       []      []               | 18
+     gpe-beam           | []                       []      []               | 19
+     gpe-bluetooth      | []                       []      []               | 13
+     gpe-calendar       | []                       []  []  []               | 12
+     gpe-clock          | []                 []    []  []  []               | 28
+     gpe-conf           | []                       []  []  []               | 20
+     gpe-contacts       | []                       []      []               | 17
+     gpe-edit           | []                       []      []               | 12
+     gpe-filemanager    | []                       []  []  []               | 16
+     gpe-go             | []                 []    []  []  []               | 25
+     gpe-login          | []                       []      []               | 11
+     gpe-ownerinfo      | []                 []    []      []          []   | 25
+     gpe-package        | []                       []      []               | 13
+     gpe-sketchbook     | []                       []      []               | 20
+     gpe-su             | []                 []    []  []  []               | 30
+     gpe-taskmanager    | []                 []    []  []  []               | 29
+     gpe-timesheet      | []                 []    []      []          []   | 25
+     gpe-today          | []                 []    []  []  []          []   | 30
+     gpe-todo           | []                       []  []  []               | 17
+     gphoto2            | []                    [] []      []          []   | 24
+     gprof              | []                 []    []                       | 15
+     gpsdrive           | []                       []      []               | 11
+     gramadoir          | []                       []      []               | 11
+     grep               |                 []       []      []               | 10
+     grub               | []                       []      []               | 14
+     gsasl              | []                       []      []          []   | 14
+     gss                | []                       []      []               | 11
+     gst-plugins-bad    | []                 []    []      []               | 26
+     gst-plugins-base   | []                 [] [] []      []               | 24
+     gst-plugins-good   | []                 []    []      []               | 24
+     gst-plugins-ugly   | []                 [] [] []      []               | 29
+     gstreamer          | []                    [] []      []               | 22
+     gtick              |                       [] []      []               | 13
+     gtkam              | []                       []      []               | 20
+     gtkorphan          | []                       []      []               | 14
+     gtkspell           | []              [] [] [] []  []  []    []    []   | 45
+     gutenprint         | []                                                | 10
+     hello              | []              [] []    []      []          []   | 21
+     help2man           | []                       []                       |  7
+     hylafax            |                          []                       |  5
+     idutils            | []                 []    []      []               | 17
+     indent             | []                 [] [] []      []          []   | 30
+     iso_15924          |                 ()    [] ()      []          []   | 16
+     iso_3166           | []        []    () [] [] ()  []  []    []    ()   | 53
+     iso_3166_2         |                 ()    [] ()      []               |  9
+     iso_4217           | []              () [] [] ()      []    []         | 26
+     iso_639            | []     [] []    ()    [] ()  []  []    []    []   | 38
+     iso_639_3          |        []                ()                       |  8
+     jwhois             | []                 []    []      []          []   | 16
+     kbd                | []                 [] [] []      []               | 15
+     keytouch           | []                       []      []               | 16
+     keytouch-editor    | []                       []      []               | 14
+     keytouch-keyboa... | []                       []      []               | 14
+     klavaro            |                          []                       | 11
+     latrine            |                    []    []      []               | 10
+     ld                 | []                 []    []                  []   | 11
+     leafpad            | []                 [] [] []      []          []   | 33
+     libc               | []                 []    []      []          []   | 21
+     libexif            |                          []      ()               |  7
+     libextractor       |                          []                       |  1
+     libgnutls          | []                       []      []               |  9
+     libgpewidget       | []                       []      []               | 14
+     libgpg-error       | []                       []      []               |  9
+     libgphoto2         |                       [] []                       |  8
+     libgphoto2_port    | []                    [] []                  []   | 14
+     libgsasl           | []                       []      []               | 13
+     libiconv           | []                       []  []  []               | 21
+     libidn             | ()                       []      []               | 11
+     lifelines          | []                                                |  4
+     liferea            | []                 []            []               | 21
+     lilypond           |                          []                       |  7
+     linkdr             | []                 []    []      []          []   | 17
+     lordsawar          |                                                   |  1
+     lprng              |                          []                       |  3
+     lynx               | []                 [] [] []                       | 17
+     m4                 | []                       []      []          []   | 19
+     mailfromd          |                       [] []                       |  3
+     mailutils          |                          []                       |  5
+     make               | []                 []    []      []               | 21
+     man-db             | []                       []      []               |  8
+     man-db-manpages    |                                                   |  4
+     minicom            | []                       []                       | 16
+     mkisofs            |                          []      []               |  9
+     myserver           |                                                   |  0
+     nano               | []                       []      []          []   | 21
+     opcodes            | []                 []    []                       | 11
+     parted             | []                 [] [] []                  []   | 15
+     pies               |                       [] []                       |  3
+     popt               | []              [] []    []      []          []   | 27
+     psmisc             | []                       []                       | 11
+     pspp               |                                                   |  4
+     pwdutils           | []                       []                       |  6
+     radius             |                       [] []                       |  9
+     recode             | []                 []    []      []               | 28
+     rosegarden         | ()                                                |  0
+     rpm                | []                       []                  []   | 11
+     rush               |                       [] []                       |  4
+     sarg               |                                                   |  1
+     screem             |                          []                       |  3
+     scrollkeeper       | []                 [] [] []                  []   | 27
+     sed                | []                 []    []      []          []   | 30
+     sharutils          | []                 []    []      []          []   | 22
+     shishi             |                          []                       |  3
+     skencil            | []                       []                       |  7
+     solfege            | []                 []    []      []               | 16
+     solfege-manual     |                    []                             |  8
+     soundtracker       | []                 []    []                       |  9
+     sp                 |                    []                             |  3
+     sysstat            |                          []      []               | 15
+     tar                | []                 [] [] []      []          []   | 23
+     texinfo            | []                 [] [] []      []               | 17
+     tin                |                                                   |  4
      unicode-han-tra... |                                                   |  0
      unicode-transla... |                                                   |  2
-     util-linux         |          [] []     []                             | 20
-     util-linux-ng      |          [] []     []                             | 20
-     vorbis-tools       |             []     []                             |  4
-     wastesedge         |                                                   |  1
-     wdiff              |          []        []                             | 23
-     wget               |          []        []                     []      | 20
-     xchat              |             []     []         []          []      | 29
-     xkeyboard-config   |          [] []     []                             | 14
-     xpad               |                    []         []          []      | 15
+     util-linux-ng      | []                 [] [] []                       | 20
+     vice               | ()                 ()                             |  1
+     vmm                |                          []                       |  4
+     vorbis-tools       |                          []                       |  6
+     wastesedge         |                                                   |  2
+     wdiff              | []                       []                       |  7
+     wget               | []                 []    []      []          []   | 26
+     wyslij-po          |                       [] []                       |  8
+     xchat              | []              []    [] []      []          []   | 36
+     xdg-user-dirs      | []     [] []    [] [] [] []      []    []    []   | 63
+     xkeyboard-config   | []                    [] []                       | 22
                         +---------------------------------------------------+
-       76 teams           tg th tk tr uk ven vi  wa xh zh_CN zh_HK zh_TW zu
-      163 domains          0  3  1 74 51  0  143 21  1  57     7    45    0  2036
+       85 teams           sv  sw ta te tg th tr uk vi  wa zh_CN zh_HK zh_TW
+      178 domains         119  1  3  3  0 10 65 51 155 17  98     7    41    2618
 
    Some counters in the preceding matrix are higher than the number of
 visible blocks let us expect.  This is because a few extra PO files are
@@ -1042,12 +1256,12 @@ distributed as such by its maintainer.  There might be an observable
 lag between the mere existence a PO file and its wide availability in a
 distribution.
 
-   If November 2007 seems to be old, you may fetch a more recent copy
-of this `ABOUT-NLS' file on most GNU archive sites.  The most
-up-to-date matrix with full percentage details can be found at
+   If June 2010 seems to be old, you may fetch a more recent copy of
+this `ABOUT-NLS' file on most GNU archive sites.  The most up-to-date
+matrix with full percentage details can be found at
 `http://translationproject.org/extra/matrix.html'.
 
-1.6 Using `gettext' in new packages
+1.5 Using `gettext' in new packages
 ===================================
 
 If you are writing a freely available program and want to
diff --git a/COMPATIBILITY b/COMPATIBILITY
index 485a0b2..7f53670 100644
--- a/COMPATIBILITY
+++ b/COMPATIBILITY
@@ -1,10 +1,10 @@
 CODE_SATURNE VERSION 2.0
 ========================
 
-This is version 2.0-beta2 of the Code_Saturne CFD tool.
+This is version 2.0-rc2 of the Code_Saturne CFD tool.
 It is composed of the following elements:
-* Code_Saturne Kernel version 2.0-beta2 (including Graphical User Interface)
-* Code_Saturne Preprocessor version 2.0-beta2
+* Code_Saturne Kernel version 2.0-rc2 (including Graphical User Interface)
+* Code_Saturne Preprocessor version 2.0-rc2
 Other versions of these elements might not be compatible.
 
 
@@ -13,10 +13,10 @@ Compulsory libraries
 The BFT (Base Functions and Types) and FVM (Finite Volume Mesh) libraries
 are compulsory. The MEI (Mathematical Expressions Interpreter) is optional.
 They are distributed under the LGPL licence (copyright EDF S.A., France).
-Code_Saturne version 2.0-beta2 is compliant with the following versions:
-* BFT 1.1.1 or newer
-* FVM 0.14.0 or newer
-* MEI 1.0.0 or newer
+Code_Saturne version 2.0-rc2 is compliant with the following versions:
+* BFT 1.1.3 or newer
+* FVM 0.15.1 or newer
+* MEI 1.0.2 or newer
 Older versions might yet be compatible, possibly with limited features.
 
 
@@ -27,11 +27,12 @@ Code_Saturne. The version number is the one used for developping and
 testing version 2.0-beta2 of Code_Saturne. Other versions (newer or older)
 might still be compatible.
 * python: > 2.4     - (necessary for the Code_Saturne GUI)
+          > 2.3     - (if Code_Saturne GUI is disabled)
 * pyqt: > 4.3       - (necessary for the Code_Saturne GUI)
 * qt: > 4.3         - (necessary for the Code_Saturne GUI)
 * libxml2: > 2.6.19 - (necessary for the Code_Saturne GUI)
 * swig: > 1.3.30    - (necessary for the MEI library)
-* Metis: 4.0        - (for optimised domain decomposition)
+* Metis: > 4.0      - (for optimised domain decomposition)
 * CGNS: > 2.5
 * MED_fichier:  > 2.3
 * hdf5: > 1.6.4     - (necessary for MED_fichier library)
@@ -46,8 +47,8 @@ number at the time of writing is given), but no specific command is
 used in the code so any other MPI library should work.
 * LAM/MPI: 7.1.4
 * MPICH: 1.2.7p1
-* MPICH2: 1.1.1p1
-* Open-MPI: 1.3.3
+* MPICH2: 1.2.1p1
+* Open-MPI: 1.4.2
 
 
 Specificities of the Matisse module of Code_Saturne
diff --git a/ChangeLog b/ChangeLog
index 054ea8c..124a6bb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,705 @@
-* 18/02/2010 - David Monfort <david.monfort at edf.fr>
+* 17/01/2010 - David Monfort <david.monfort at edf.fr>
+  Upgrade version number to 2.0.1
+  modified script:
+    configure.ac
+
+* 17/12/2010 - David Monfort <david.monfort at edf.fr>
+  Update the compilation flags detection according to Subversion trunk.
+  modified script:
+    config/cs_auto_flags.sh
+
+* 14/12/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Remove memory usage field from PBS batch template and
+  fix handling of PBS batch directives by GUI.
+  modified routines:
+    bin/runcase.in
+    bin/runcase.py.in
+    gui/Pages/BatchRunningPBSJobManagementDialogForm.ui
+    gui/Pages/BatchRunningView.py
+    gui/Pages/BatchRunningModel.py
+
+* 13/12/2010 - David Monfort <david.monfort at edf.fr>
+  Fix the XML definition for boundary conditions with exterior exchange
+  coefficient.
+  modified routines:
+    gui/Pages/BoundaryConditionsScalarsView.py
+    gui/Pages/Boundary.py
+
+* 03/12/2010 - Mehdi Ouraou <mehdi.ouraou at edf.fr>
+  Fix issues when removing the a particle which has exited the fluid domain.
+  modified routine:
+    src/lagr/lageli.f90
+
+* 03/12/2010 - Mehdi Ouraou <mehdi.ouraou at edf.fr>
+  Fix a wrong indirection (using Fortran numbering instead of C) when
+  calculating the head loss coefficients from the graphical user interface.
+  modified routine:
+    src/base/cs_gui.c
+
+* 03/12/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Correct mesh reading bug when FVM is compiled with --enable-long-gnum.
+  modified files:
+    src/base/cs_preprocessor_data.c
+
+* 03/12/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Remove calls to deprecated bft_fp_trap_set() function.
+  modified files:
+    src/apps/cs_solver.c
+
+* 29/11/2010 - Mickael Hassanaly <mickael.hassanaly at edf.fr>
+  Fix a memory bug in the Code_Aster coupling.
+  modified routine:
+    src/base/strini.f90
+
+* 10/11/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Correct bug in which runcase was not saved in results.
+  modified scripts:
+    bin/cs_case.py
+
+* 02/11/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Correct array arguments to MPI_Reduce for memory summary.
+  modified files:
+    src/base/cs_base.c
+
+* 27/10/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Add a developpers guide with coding standards.
+  added file:
+    doc/developper/coding_standards.tex
+  modified files:
+    doc/style/csdoc.sty
+    doc/developper/developper.tex
+  modified scripts:
+    bin/cs_info.py
+    doc/developper/Makefile.am
+    doc/Makefile.am
+
+* 26/10/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Handle processor list under LSF when LSB_MCPU_HOSTS is used instead
+  of LSB_HOSTS
+  modified scripts:
+    bin/cs_exec_environment.py
+    bin/runcase_mpi_env
+
+* 26/10/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Do not buffer standard output and error when executing subprocess.
+  modified scripts:
+    bin/cs_exec_environment.py
+
+* 14/09/2010 - David Monfort <david.monfort at edf.fr>
+  Fix generation of PyQt resource files.
+  modified routine:
+    gui/Pages/Makefile.am
+
+* 10/09/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix a crash when cutting warped faces with periodicity.
+  modified file:
+    src/base/cs_mesh_warping.c
+
+* 31/08/2010 - David Monfort <david.monfort at edf.fr>
+  Fix two small bugs in the Python automatic installer (MEI use and Fortran
+  compiler).
+  modified file:
+    extras/installer/install_saturne.py
+
+* 30/08/2010 - David Monfort <david.monfort at edf.fr>
+  Fix EXTRA_DIST variables in the documentation.
+  modified scripts:
+    doc/tutorial/graphics/Makefile.am
+    doc/tutorial/Makefile.am
+    doc/user/Makefile.am
+
+* 24/08/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix the info command of code_saturne.
+  modified script:
+    bin/cs_info.py
+
+* 23/08/2010 - David Monfort <david.monfort at edf.fr>
+  Fix the copying of the ALE and Lagrangian monitoring files.
+  modified script:
+    bin/runcase.in
+
+* 19/08/2010 - David Monfort <david.monfort at edf.fr>
+  Release of Code_Saturne 2.0.
+  modified routines:
+    configure.ac
+    extras/installer/install_saturne.py
+    QUALITY_ASSURANCE
+
+* 19/08/2010 - Juan Uribe <juan.uribe at manchester.ac.uk>
+  Correct value for the diffusion coefficient in k-omega SST.
+  modified routine:
+    src/base/iniini.f90
+
+* 16/08/2010 - Bertrand Carissimo <bertrand.carissimo at edf.fr>
+  Better correction for uninitialized variable.
+  modified routine:
+    users/base/usatcl.f90
+
+* 30/07/2010 - Benoit de Laage de Meux <benoit.de-laage-de-meux at edf.fr>
+  Add a missing multiplication by the density in a coupling source term.
+  modified routine:
+    src/base/csc2ts.f90
+
+* 30/07/2010 - David Monfort <david.monfort at edf.fr>
+  Move the mass-flux update in case of a rotating mesh, only relevant when
+  disabling the pressure reconstruction (no impact on current simulations).
+  modified routine:
+    src/base/navsto.f90
+
+* 29/07/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix a wrong definition of integers instead of reals.
+  modified routine:
+    src/atmo/atprke.f90
+
+* 27/07/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix a minor bug when echoing I/O structures.
+  modified routine:
+    src/base/cs_io.c
+
+* 27/07/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix a wrong "else if" clause on the size of cs_int_t.
+  modified routine:
+    src/base/cs_post.c
+
+* 26/07/2010 - David Monfort <david.monfort at edf.fr>
+  Update French dictionnary.
+  modified file:
+    po/fr.po
+
+* 26/07/2010 - Maya Milliez <maya.milliez at edf.fr>
+  English translation.
+  modified routine:
+    users/base/usatcl.f90
+
+* 21/07/2010 - David Monfort <david.monfort at edf.fr>
+  Fix issues when running simulations with periodicity (iperio not defined).
+  modified routines:
+    src/apps/cs_solver.c
+    src/base/cs_join_perio.c
+    src/base/cs_preprocessor_data.c
+
+* 21/07/2010 - J�r�me Bonelle <jerome.bonelle at edf.fr>
+  Fix the periodicities definition when using the graphical interface.
+  modified routines:
+    src/base/cs_join.c
+    src/base/cs_join_perio.c
+
+* 19/07/2010 - David Monfort <david.monfort at edf.fr>
+  Correct free memory when using MEI for a variable specific heat.
+  modified routine:
+   src/base/cs_gui.c
+
+* 13/07/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Translate variable and property names in the example Xml files.
+  modified files:
+    examples/1-simple_junction/case1/case1.xml
+    examples/2-full_domain/case2/case2.xml
+    examples/2-full_domain/case3/case3.xml
+    examples/2-full_domain/case4/case4.xml
+    examples/3-stratified_junction/case5/case5.xml
+
+* 07/07/2010 - David Monfort <david.monfort at edf.fr>
+  Fix LES WALE model handling when it is set up in the GUI.
+  modified routine:
+    src/base/cs_gui.c
+
+* 30/06/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+               David Monfort <david.monfort at edf.fr>
+  Fix an issue in MPICH2 detection with the Python runcase.
+  modified script:
+    bin/cs_exec_environment.py
+
+* 29/06/2010 - David Monfort <david.monfort at edf.fr>
+  Update the installer according to the packages URLs.
+  modified script:
+    extras/installer/install_saturne.py
+
+* 28/06/2010 - David Monfort <david.monfort at edf.fr>
+  Fix the version number output.
+  modified script:
+    bin/cs_info.py
+
+* 25/06/2010 - David Monfort <david.monfort at edf.fr>
+  Little fixes and improvement for code/code coupling.
+  modified routines:
+    src/base/cscpfb.f90
+    src/base/cs_sat_coupling.c
+
+* 25/06/2010 - Benoit de Laage de Meux <benoit.de-laage-de-meux at edf.fr>
+  Add a missing local variable definition (epsilon for the RHS sweep).
+  modified routine:
+    src/base/resv2f.f90
+
+* 23/06/2010 - David Monfort <david.monfort at edf.fr>
+  Fix the working directory option for MPI MPMD parameters.
+  modified script:
+    bin/cs_case.py
+
+* 22/06/2010 - David Monfort <david.monfort at edf.fr>
+  Release of Code_Saturne 2.0-rc2.
+
+* 21/06/2010 - Pascal Nicolas <pascal.nicolas at incka.fr>
+               David Monfort <david.monfort at edf.fr>
+  Code_Saturne examples update, according to 2.0-rc2 version.
+  modified files:
+    examples/1-simple_junction/case1/case1.xml
+    examples/2-full_domain/case2/case2.xml
+    examples/2-full_domain/case3/case3.xml
+    examples/2-full_domain/case3/usclim.f90
+    examples/2-full_domain/case4/case4.xml
+    examples/2-full_domain/case4/usclim.f90
+    examples/2-full_domain/case4/usproj.f90
+    examples/3-stratified_junction/case5/case5.xml
+    examples/3-stratified_junction/case5/usdpst.f90
+    examples/3-stratified_junction/case5/usmpst.f90
+    examples/3-stratified_junction/case5/usvpst.f90
+  removed files:
+    examples/1-simple_junction/case1/runcase
+    examples/2-full_domain/case2/lance
+    examples/2-full_domain/case2/runcase
+    examples/2-full_domain/case3/runcase
+    examples/2-full_domain/case3/usphyv.f90
+    examples/2-full_domain/case4/runcase
+    examples/2-full_domain/case4/uskpdc.f90
+    examples/2-full_domain/case4/usphyv.f90
+    examples/3-stratified_junction/case5/runcase
+    examples/3-stratified_junction/case5/usphyv.f90
+
+* 21/06/2010 - David Monfort <david.monfort at edf.fr>
+  Minor correction for the tutorial documentation.
+  modified file:
+    doc/tutorial/tuto_case2.tex
+
+* 21/06/2010 - David Monfort <david.monfort at edf.fr>
+  Missing initialization in memory handling.
+  modified routine:
+    src/base/memdyp.f90
+
+* 21/06/2010 - David Monfort <david.monfort at edf.fr>
+  By-pass a possible bug with the flush Fortran 2003 statement on BG systems.
+  modified script:
+    config/cs_fortran.m4
+
+* 21/06/2010 - David Monfort <david.monfort at edf.fr>
+  On BlueGene systems, RUSAGE_CHILDREN is not available.
+  modified routine:
+    src/base/tremai.c
+
+* 21/06/2010 - David Monfort <david.monfort at edf.fr>
+  Make the particles output compliant with EnSight 6 format and improve the
+  robustness of the output for visualizing with ParaView.
+  Thanks to St�phane Blanchet for reporting this issue.
+  modified routine:
+    src/lagr/enslag.f90
+    src/lagr/enswaf.f90
+
+* 15/06/2010 - David Monfort <david.monfort at edf.fr>
+  Add a potential patch for pressure outlet rescaling.
+  added routine:
+    patches/typecl.f90
+  modified file:
+    patches/README
+
+* 15/06/2010 - David Monfort <david.monfort at edf.fr>
+  Fix a crash when asking for the check_mesh help.
+  modified script:
+    bin/cs_check_mesh.py
+
+* 15/06/2010 - Mehdi Ouraou <mehdi.ouraou at edf.fr>
+  Fix two issues in the coal combustion modelling.
+  modified routines:
+    src/cplv/cpphy1.f90
+    src/cplv/cpphyv.f90
+
+* 15/06/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  English translation.
+  modified routine:
+    users/base/usphyv.f90
+
+* 15/06/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Set the reference pressure to the atmospheric pressure.
+  modified routine:
+    users/base/usini1.f90
+
+* 15/06/2010 - David Monfort <david.monfort at edf.fr>
+  Update version number to 2.0-rc2.
+  modified script:
+    configure.ac
+
+* 15/06/2010 - David Monfort <david.monfort at edf.fr>
+  Properly set the version number of the different pre-requisites,
+  especially Python.
+  modified script:
+    configure.ac
+  modified file:
+    COMPATIBILITY
+
+* 15/06/2010 - David Monfort <david.monfort at edf.fr>
+  Correct comments in specific physics definition.
+  modified routine:
+    users/pprt/usppmo.f90
+
+* 13/06/2010 - David Monfort <david.monfort at edf.fr>
+  Update of the French dictionnary.
+  modified files:
+   po/POTFILES.in
+   po/fr.po
+
+* 10/06/2010 - David Monfort <david.monfort at edf.fr>
+  Improve the robustness of the Python installer.
+  modified files:
+    extras/installer/README
+    extras/installer/install_saturne.py
+    extras/installer/setup
+
+* 08/06/2010 - J�r�me Bonelle <jerome.bonelle at edf.fr>
+  Miscellaneous fixes for the parallel joining algorithm.
+  modified routines:
+    include/base/cs_join_util.h
+    src/base/cs_join_intersect.c
+    src/base/cs_join_merge.c
+    src/base/cs_join_mesh.c
+    src/base/cs_join_perio.c
+    src/base/cs_join_split.c
+    src/base/cs_join_update.c
+    src/base/cs_join_util.c
+
+* 08/06/2010 - David Monfort <david.monfort at edf.fr>
+  Miscellaneous fixes for code/code coupling.
+  modified routines:
+    include/base/cplsat.h
+    src/base/csc2cl.f90
+    src/base/cscini.f90
+    src/base/cscpfb.f90
+    src/base/cs_sat_coupling.c
+    users/base/ussatc.f90
+
+* 08/06/2010 - David Monfort <david.monfort at edf.fr>
+  Missing initialization in memory handling.
+  modified routine:
+    src/base/memdis.f90
+
+* 08/06/2010 - David Monfort <david.monfort at edf.fr>
+  Missing header in previous commit.
+  modified routine:
+    src/base/clptrg.f90
+
+* 28/05/2010 - David Monfort <david.monfort at edf.fr>
+  Same fix as the one below on clptur, now concerns the rough walls.
+  modified routine:
+    src/base/clptrg.f90
+
+* 28/05/2010 - David Monfort <david.monfort at edf.fr>
+  Don't use the type bool, use cs_bool_t instead (thanks to Charles Moulinec).
+  modified routine:
+    src/base/cs_join_set.c
+
+* 26/05/2010 - David Monfort <david.monfort at edf.fr>
+  Fix the wall treatment management in case of mobile mesh for rotating
+  machinery (or ALE formulation). The velocity was not correctly projected.
+  modified routine:
+    src/base/clptur.f90
+
+* 25/05/2010 - David Monfort <david.monfort at edf.fr>
+  Minor fixes to alleviate cross-compilation issues with mingw32 compilers.
+  modified script:
+    configure.ac
+  modified routines:
+    src/base/cs_base.c
+    src/base/tremai.c
+
+* 22/05/2010 - David Monfort <david.monfort at edf.fr>
+  Fix a wrong initizaliation for the thermal roughness (when using the
+  graphical interface). Thanks to Maxime Nibart for reporting this bug.
+  modified routine:
+    src/base/cs_gui_boundary_conditions.c
+
+* 21/05/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Improve the cs_solver options management so that the error message is clearer
+  in case the code is not compiled with X feature support.
+  modified routine:
+    src/base/cs_opts.c
+
+* 21/05/2010 - Alexandre Douce <alexandre.douce at edf.fr>
+  Fix small bugs in post-processing management of the Lagrangian module.
+  modified routines:
+    src/lagr/enswaf.f90
+    src/lagr/lagopt.f90
+
+* 21/05/2010 - Maya Milliez <maya.milliez at edf.fr>
+               Bertrand Carissimo <bertrand.carissimo at edf.fr>
+  Several little fixes and improvements for the atmospheric module.
+  modified routine:
+    src/atmo/atiniv.f90
+    src/atmo/atmcls.f90
+    src/atmo/atphyv.f90
+    src/atmo/atprke.f90
+    src/atmo/attycl.f90
+    src/base/clptrg.f90
+    src/base/turbke.f90
+    users/atmo/usatcl.f90
+    users/atmo/usati1.f90
+
+* 21/05/2010 - Pascal Nicolas <pascal.nicolas at incka.fr>
+  Update the tutorial description.
+  modified files:
+    doc/tutorial/case4.tex
+    doc/tutorial/graphics/V-11.png
+    doc/tutorial/graphics/V-12.png
+    doc/tutorial/graphics/V-14.png
+    doc/tutorial/graphics/V-15.png
+    doc/tutorial/graphics/V-16.png
+    doc/tutorial/graphics/V-17.png
+    doc/tutorial/graphics/V-3.png
+    doc/tutorial/graphics/V-5.png
+    doc/tutorial/graphics/V-6.png
+    doc/tutorial/graphics/V-7.png
+    doc/tutorial/graphics/V-9.png
+    doc/tutorial/tuto_case1.tex
+    doc/tutorial/tuto_case3.tex
+    doc/tutorial/tuto_case4.tex
+
+* 21/05/2010 - David Monfort <david.monfort at edf.fr>
+  Enable silent rules with recent automake (>= 1.11.1). The default mode is
+  verbose, the silent mode can be activated with --enable-silent-rules at
+  configure stage or make V=0 at compilation stage.
+  modified script:
+    configure.ac
+
+* 19/05/2010 - David Monfort <david.monfort at edf.fr>
+  Revert a changeset regarding the turbulence relaxation (k/epsilon/omega) to
+  avoid stability issues in some calculations. This still needs to be
+  investigated in order to have a correct unsteadyness when needed.
+  modified routine:
+    src/base/modini.f90
+
+* 19/05/2010 - David Monfort <david.monfort at edf.fr>
+  Fix a bug in the user files results copy in the Python runcase.
+  modified script:
+    bin/cs_case_domain.py
+
+* 12/05/2010 - Alexandre Douce <alexandre.douce at edf.fr>
+  Fix a useless test on the number of directions in the radiative transfer
+  module when using the P1 model.
+  modified routine:
+    src/rayt/rayopt.f90
+
+* 05/05/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Improve Code_Saturne manuals launch from the main script.
+  modified script:
+    bin/cs_info.py
+
+* 05/05/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Improve MPICH2 detection and some MPI shell commands.
+  modified scritps:
+    bin/cs_case.py
+    bin/cs_exec_environment.py
+
+* 16/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix YACS command line handling.
+  modified script:
+    bin/cs_case.py
+
+* 15/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Handle the difference between HP-UX hppa and Itanium systems.
+  modified script:
+    config/cs_auto_flags.sh
+
+* 15/04/2010 - David Monfort <david.monfort at edf.fr>
+  Fix an uninitialized variable in fioul combustion module.
+  modified routine:
+    src/fuel/fuiniv.f90
+
+* 15/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix minor issue for SYRTHES coupling and JANAF file handling.
+  modified script:
+    bin/cs_case_domain.py
+
+* 15/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Add YACS detection in the runcase script.
+  modified script:
+    bin/cs_case.py
+
+* 09/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Minor update to the documentation (mostly English corrections).
+  modified files:
+    doc/theory/bilsc2.tex
+    doc/theory/combbase.tex
+    doc/theory/combfuel.tex
+    doc/theory/combgaz.tex
+    doc/theory/thermo.tex
+    doc/user/a1_autovalid.tex
+    doc/user/graphics/cs_components.fig
+    doc/user/saturne1.tex
+    doc/user/saturne2.tex
+
+* 09/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix a valgrind warning for an uninitialized array in the quality tests.
+  modified routine:
+    src/base/testel.f90
+
+* 09/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix some integer sizes in the reduced-neighborhood algorithm (only relevant
+  for big meshes).
+  modified routine:
+    src/base/cs_ext_neighborhood.c
+
+* 09/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Free temporary mesh structure in the Code_Aster coupling.
+  modified routine:
+    src/base/cs_ast_coupling.c
+
+* 02/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Miscellaneous improvement for robustness.
+  modified routines:
+    src/base/cs_benchmark.c
+    src/base/cs_gui_boundary_conditions.c
+    src/base/cs_io.c
+    src/base/cs_matrix.c
+    src/base/cs_preprocessor_data.c
+    src/base/testel.f90
+
+* 02/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Cast all the printing in unsigned long long instead of unsigned long.
+  modified routines:
+    src/base/cs_base.c
+    src/base/cs_boundary_conditions.c
+    src/base/cs_ext_neighborhood.c
+    src/base/cs_io.c
+    src/base/cs_join_intersect.c
+    src/base/cs_mesh.c
+    src/base/cs_mesh_quantities.c
+    src/base/cs_multigrid.c
+    src/base/cs_preprocessor_data.c
+    src/base/cs_restart.c
+    src/base/cs_syr4_coupling.c
+
+* 01/04/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Minor modifications to the joining alogrithm (mostly English translation
+  and switch from unsigned long to unsigned long long for printing).
+  modified routines:
+    include/base/cs_prototypes.h
+    src/apps/cs_solver.c
+    src/base/cs_join_f2c.f90
+    src/base/cs_join_intersect.c
+    src/base/cs_join_merge.c
+    src/base/cs_join_mesh.c
+    src/base/cs_join_perio.c
+    src/base/cs_join_perio_f2c.f90
+    src/base/cs_join_set.c
+    src/base/cs_join_split.c
+    src/base/cs_join_util.c
+    users/base/usjoin.f90
+    users/base/usperi.f90
+
+* 31/03/2010 - J�r�me Bonelle <jerome.bonelle at edf.fr>
+  Add the periodicity "joining" handling in parallel by the solver.
+  modified script:
+    src/base/Makefile.am
+  added routines:
+    include/base/cs_join_perio.h
+    src/base/cs_join_perio.c
+    src/base/cs_join_perio_f2c.f90
+    users/base/usperi.f90
+  modified routines:
+    include/base/cs_join.h
+    include/base/cs_join_mesh.h
+    include/base/cs_join_split.h
+    include/base/cs_join_util.h
+    include/base/cs_mesh.h
+    src/apps/cs_solver.c
+    src/base/cs_join.c
+    src/base/cs_join_f2c.f90
+    src/base/cs_join_intersect.c
+    src/base/cs_join_merge.c
+    src/base/cs_join_mesh.c
+    src/base/cs_join_split.c
+    src/base/cs_join_update.c
+    src/base/cs_join_util.c
+    src/base/cs_mesh.c
+
+* 31/03/2010 - J�r�me Bonelle <jerome.bonelle at edf.fr>
+  Miscellaneous improvements for the parallel joining algorithm and
+  preparation for the periodicity handling.
+  modified routines:
+    include/base/cs_join.h
+    include/base/cs_join_intersect.h
+    include/base/cs_join_merge.h
+    include/base/cs_join_mesh.h
+    include/base/cs_join_post.h
+    include/base/cs_join_set.h
+    include/base/cs_join_update.h
+    include/base/cs_join_util.h
+    src/base/cs_join.c
+    src/base/cs_join_intersect.c
+    src/base/cs_join_merge.c
+    src/base/cs_join_mesh.c
+    src/base/cs_join_post.c
+    src/base/cs_join_set.c
+    src/base/cs_join_split.c
+    src/base/cs_join_update.c
+    src/base/cs_join_util.c
+    users/base/usjoin.f90
+
+* 31/03/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix a bug in the standard initaliziation of MPI class.
+  modified script:
+    bin/cs_exec_environment.py
+
+* 31/03/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Add many comments to the Python runcase script.
+  Expose the VALGRIND option.
+  modified script:
+    bin/runcase.py.in
+
+* 22/03/2010 - David Monfort <david.monfort at edf.fr>
+  Update the tutorial documentation and replace .jpg by .png files.
+
+* 24/02/2010 - David Monfort <david.monfort at edf.fr>
+  Fix a couple of remaining issues related to compilation on BlueGene systems.
+  modified scripts:
+    config/cs_auto_flags.sh
+    config/cs_blas.m4
+    config/cs_fortran.m4
+    config/cs_mpi.m4
+    configure.ac
+  modified routine:
+    src/base/cs_opts.c
+
+* 23/02/2010 - David Monfort <david.monfort at edf.fr>
+  Fix PyQt dev tools detection (pyuic4/pyrcc4) for kfreebsd-* systems.
+  Thanks to Petr Salinger for providing the hack.
+  modified script:
+    configure.ac
+
+* 19/02/2010 - David Monfort <david.monfort at edf.fr>
   Release of Code_Saturne 2.0-rc1.
 
+* 19/02/2010 - David Monfort <david.monfort at edf.fr>
+  Remove a line introduced twice in the arguments of usray4.
+  modified routine:
+    src/rayt/raycli.f90
+
+* 19/02/2010 - David Monfort <david.monfort at edf.fr>
+  Add Clamart 2 cluster "scratchdir" to the list of the temporary directories.
+  modified scripts:
+    bin/runcase.in
+    bin/runcase.py.in
+
+* 19/02/2010 - Yvan Fournier <yvan.fournier at edf.fr>
+  Fix a bug in handling FVM long-gnum option in the restart files.
+  modified routine:
+    src/base/cs_io.c
+
+* 19/02/2010 - David Monfort <david.monfort at edf.fr>
+  Fix last-minute bug where the number of arguments of a subroutine did not
+  match (with no impact on the calculation).
+  modified routine:
+    src/cfbl/cfvarp.f90
+
+* 18/02/2010 - David Monfort <david.monfort at edf.fr>
+  Pre-release of Code_Saturne 2.0-rc1.
+
 * 18/02/2010 - Pierre Plion <pierre.plion at edf.fr>
   Improve combustion documentation in the theory manual.
   added files:
diff --git a/Makefile.in b/Makefile.in
index 6d7e857..56adbe7 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -84,9 +84,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
@@ -123,6 +128,12 @@ am__installdirs = "$(DESTDIR)$(pkgdatadir)" "$(DESTDIR)$(bindir)" \
 	"$(DESTDIR)$(pkgdatadir)" "$(DESTDIR)$(pkgdatadir)" \
 	"$(DESTDIR)$(pkgdatadir)" "$(DESTDIR)$(includedir)"
 SCRIPTS = $(dist_pkgdata_SCRIPTS) $(nodist_bin_SCRIPTS)
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -185,6 +196,7 @@ distuninstallcheck_listfiles = find . -type f -print
 distcleancheck_listfiles = find . -type f -print
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -208,6 +220,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -259,6 +272,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -315,6 +329,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -352,7 +367,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/QUALITY_ASSURANCE b/QUALITY_ASSURANCE
index c769b65..d487b89 100644
--- a/QUALITY_ASSURANCE
+++ b/QUALITY_ASSURANCE
@@ -1,4 +1,4 @@
 QUALITY ASSURANCE
 =================
-This version of Code_Saturne is a development version that
-has not been validated under EDF quality assurance.
+This version of Code_Saturne is a production version that
+has been validated under EDF quality assurance.
diff --git a/aclocal.m4 b/aclocal.m4
deleted file mode 100644
index 863ea98..0000000
--- a/aclocal.m4
+++ /dev/null
@@ -1,9228 +0,0 @@
-# generated automatically by aclocal 1.11.1 -*- Autoconf -*-
-
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008, 2009  Free Software Foundation, Inc.
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-m4_ifndef([AC_AUTOCONF_VERSION],
-  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],,
-[m4_warning([this file was generated for autoconf 2.65.
-You have another version of autoconf.  It may work, but is not guaranteed to.
-If you have problems, you may need to regenerate the build system entirely.
-To do so, use the procedure documented by the package, typically `autoreconf'.])])
-
-# intlmacosx.m4 serial 1 (gettext-0.17)
-dnl Copyright (C) 2004-2007 Free Software Foundation, Inc.
-dnl This file is free software; the Free Software Foundation
-dnl gives unlimited permission to copy and/or distribute it,
-dnl with or without modifications, as long as this notice is preserved.
-dnl
-dnl This file can can be used in projects which are not available under
-dnl the GNU General Public License or the GNU Library General Public
-dnl License but which still want to provide support for the GNU gettext
-dnl functionality.
-dnl Please note that the actual code of the GNU gettext library is covered
-dnl by the GNU Library General Public License, and the rest of the GNU
-dnl gettext package package is covered by the GNU General Public License.
-dnl They are *not* in the public domain.
-
-dnl Checks for special options needed on MacOS X.
-dnl Defines INTL_MACOSX_LIBS.
-AC_DEFUN([gt_INTL_MACOSX],
-[
-  dnl Check for API introduced in MacOS X 10.2.
-  AC_CACHE_CHECK([for CFPreferencesCopyAppValue],
-    gt_cv_func_CFPreferencesCopyAppValue,
-    [gt_save_LIBS="$LIBS"
-     LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
-     AC_TRY_LINK([#include <CoreFoundation/CFPreferences.h>],
-       [CFPreferencesCopyAppValue(NULL, NULL)],
-       [gt_cv_func_CFPreferencesCopyAppValue=yes],
-       [gt_cv_func_CFPreferencesCopyAppValue=no])
-     LIBS="$gt_save_LIBS"])
-  if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-    AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], 1,
-      [Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in the CoreFoundation framework.])
-  fi
-  dnl Check for API introduced in MacOS X 10.3.
-  AC_CACHE_CHECK([for CFLocaleCopyCurrent], gt_cv_func_CFLocaleCopyCurrent,
-    [gt_save_LIBS="$LIBS"
-     LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
-     AC_TRY_LINK([#include <CoreFoundation/CFLocale.h>], [CFLocaleCopyCurrent();],
-       [gt_cv_func_CFLocaleCopyCurrent=yes],
-       [gt_cv_func_CFLocaleCopyCurrent=no])
-     LIBS="$gt_save_LIBS"])
-  if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
-    AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], 1,
-      [Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the CoreFoundation framework.])
-  fi
-  INTL_MACOSX_LIBS=
-  if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
-    INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
-  fi
-  AC_SUBST([INTL_MACOSX_LIBS])
-])
-
-# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
-#
-#   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-#                 2006, 2007, 2008 Free Software Foundation, Inc.
-#   Written by Gordon Matzigkeit, 1996
-#
-# This file is free software; the Free Software Foundation gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-
-m4_define([_LT_COPYING], [dnl
-#   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-#                 2006, 2007, 2008 Free Software Foundation, Inc.
-#   Written by Gordon Matzigkeit, 1996
-#
-#   This file is part of GNU Libtool.
-#
-# GNU Libtool is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation; either version 2 of
-# the License, or (at your option) any later version.
-#
-# As a special exception to the GNU General Public License,
-# if you distribute this file as part of a program or library that
-# is built using GNU Libtool, you may include this file under the
-# same distribution terms that you use for the rest of that program.
-#
-# GNU Libtool 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 General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Libtool; see the file COPYING.  If not, a copy
-# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
-# obtained by writing to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-])
-
-# serial 56 LT_INIT
-
-
-# LT_PREREQ(VERSION)
-# ------------------
-# Complain and exit if this libtool version is less that VERSION.
-m4_defun([LT_PREREQ],
-[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
-       [m4_default([$3],
-		   [m4_fatal([Libtool version $1 or higher is required],
-		             63)])],
-       [$2])])
-
-
-# _LT_CHECK_BUILDDIR
-# ------------------
-# Complain if the absolute build directory name contains unusual characters
-m4_defun([_LT_CHECK_BUILDDIR],
-[case `pwd` in
-  *\ * | *\	*)
-    AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
-esac
-])
-
-
-# LT_INIT([OPTIONS])
-# ------------------
-AC_DEFUN([LT_INIT],
-[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
-AC_BEFORE([$0], [LT_LANG])dnl
-AC_BEFORE([$0], [LT_OUTPUT])dnl
-AC_BEFORE([$0], [LTDL_INIT])dnl
-m4_require([_LT_CHECK_BUILDDIR])dnl
-
-dnl Autoconf doesn't catch unexpanded LT_ macros by default:
-m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
-m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
-dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
-dnl unless we require an AC_DEFUNed macro:
-AC_REQUIRE([LTOPTIONS_VERSION])dnl
-AC_REQUIRE([LTSUGAR_VERSION])dnl
-AC_REQUIRE([LTVERSION_VERSION])dnl
-AC_REQUIRE([LTOBSOLETE_VERSION])dnl
-m4_require([_LT_PROG_LTMAIN])dnl
-
-dnl Parse OPTIONS
-_LT_SET_OPTIONS([$0], [$1])
-
-# This can be used to rebuild libtool when needed
-LIBTOOL_DEPS="$ltmain"
-
-# Always use our own libtool.
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-AC_SUBST(LIBTOOL)dnl
-
-_LT_SETUP
-
-# Only expand once:
-m4_define([LT_INIT])
-])# LT_INIT
-
-# Old names:
-AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
-AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
-dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
-
-
-# _LT_CC_BASENAME(CC)
-# -------------------
-# Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
-m4_defun([_LT_CC_BASENAME],
-[for cc_temp in $1""; do
-  case $cc_temp in
-    compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
-    distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
-    \-*) ;;
-    *) break;;
-  esac
-done
-cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
-])
-
-
-# _LT_FILEUTILS_DEFAULTS
-# ----------------------
-# It is okay to use these file commands and assume they have been set
-# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
-m4_defun([_LT_FILEUTILS_DEFAULTS],
-[: ${CP="cp -f"}
-: ${MV="mv -f"}
-: ${RM="rm -f"}
-])# _LT_FILEUTILS_DEFAULTS
-
-
-# _LT_SETUP
-# ---------
-m4_defun([_LT_SETUP],
-[AC_REQUIRE([AC_CANONICAL_HOST])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-_LT_DECL([], [host_alias], [0], [The host system])dnl
-_LT_DECL([], [host], [0])dnl
-_LT_DECL([], [host_os], [0])dnl
-dnl
-_LT_DECL([], [build_alias], [0], [The build system])dnl
-_LT_DECL([], [build], [0])dnl
-_LT_DECL([], [build_os], [0])dnl
-dnl
-AC_REQUIRE([AC_PROG_CC])dnl
-AC_REQUIRE([LT_PATH_LD])dnl
-AC_REQUIRE([LT_PATH_NM])dnl
-dnl
-AC_REQUIRE([AC_PROG_LN_S])dnl
-test -z "$LN_S" && LN_S="ln -s"
-_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
-dnl
-AC_REQUIRE([LT_CMD_MAX_LEN])dnl
-_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
-_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
-dnl
-m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-m4_require([_LT_CHECK_SHELL_FEATURES])dnl
-m4_require([_LT_CMD_RELOAD])dnl
-m4_require([_LT_CHECK_MAGIC_METHOD])dnl
-m4_require([_LT_CMD_OLD_ARCHIVE])dnl
-m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
-
-_LT_CONFIG_LIBTOOL_INIT([
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes INIT.
-if test -n "\${ZSH_VERSION+set}" ; then
-   setopt NO_GLOB_SUBST
-fi
-])
-if test -n "${ZSH_VERSION+set}" ; then
-   setopt NO_GLOB_SUBST
-fi
-
-_LT_CHECK_OBJDIR
-
-m4_require([_LT_TAG_COMPILER])dnl
-_LT_PROG_ECHO_BACKSLASH
-
-case $host_os in
-aix3*)
-  # AIX sometimes has problems with the GCC collect2 program.  For some
-  # reason, if we set the COLLECT_NAMES environment variable, the problems
-  # vanish in a puff of smoke.
-  if test "X${COLLECT_NAMES+set}" != Xset; then
-    COLLECT_NAMES=
-    export COLLECT_NAMES
-  fi
-  ;;
-esac
-
-# Sed substitution that helps us do robust quoting.  It backslashifies
-# metacharacters that are still active within double-quoted strings.
-sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\([["`\\]]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
-# Global variables:
-ofile=libtool
-can_build_shared=yes
-
-# All known linkers require a `.a' archive for static linking (except MSVC,
-# which needs '.lib').
-libext=a
-
-with_gnu_ld="$lt_cv_prog_gnu_ld"
-
-old_CC="$CC"
-old_CFLAGS="$CFLAGS"
-
-# Set sane defaults for various variables
-test -z "$CC" && CC=cc
-test -z "$LTCC" && LTCC=$CC
-test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
-test -z "$LD" && LD=ld
-test -z "$ac_objext" && ac_objext=o
-
-_LT_CC_BASENAME([$compiler])
-
-# Only perform the check for file, if the check method requires it
-test -z "$MAGIC_CMD" && MAGIC_CMD=file
-case $deplibs_check_method in
-file_magic*)
-  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
-    _LT_PATH_MAGIC
-  fi
-  ;;
-esac
-
-# Use C for the default configuration in the libtool script
-LT_SUPPORTED_TAG([CC])
-_LT_LANG_C_CONFIG
-_LT_LANG_DEFAULT_CONFIG
-_LT_CONFIG_COMMANDS
-])# _LT_SETUP
-
-
-# _LT_PROG_LTMAIN
-# ---------------
-# Note that this code is called both from `configure', and `config.status'
-# now that we use AC_CONFIG_COMMANDS to generate libtool.  Notably,
-# `config.status' has no value for ac_aux_dir unless we are using Automake,
-# so we pass a copy along to make sure it has a sensible value anyway.
-m4_defun([_LT_PROG_LTMAIN],
-[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
-_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
-ltmain="$ac_aux_dir/ltmain.sh"
-])# _LT_PROG_LTMAIN
-
-
-
-# So that we can recreate a full libtool script including additional
-# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
-# in macros and then make a single call at the end using the `libtool'
-# label.
-
-
-# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
-# ----------------------------------------
-# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
-m4_define([_LT_CONFIG_LIBTOOL_INIT],
-[m4_ifval([$1],
-          [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
-                     [$1
-])])])
-
-# Initialize.
-m4_define([_LT_OUTPUT_LIBTOOL_INIT])
-
-
-# _LT_CONFIG_LIBTOOL([COMMANDS])
-# ------------------------------
-# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
-m4_define([_LT_CONFIG_LIBTOOL],
-[m4_ifval([$1],
-          [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
-                     [$1
-])])])
-
-# Initialize.
-m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
-
-
-# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
-# -----------------------------------------------------
-m4_defun([_LT_CONFIG_SAVE_COMMANDS],
-[_LT_CONFIG_LIBTOOL([$1])
-_LT_CONFIG_LIBTOOL_INIT([$2])
-])
-
-
-# _LT_FORMAT_COMMENT([COMMENT])
-# -----------------------------
-# Add leading comment marks to the start of each line, and a trailing
-# full-stop to the whole comment if one is not present already.
-m4_define([_LT_FORMAT_COMMENT],
-[m4_ifval([$1], [
-m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
-              [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
-)])
-
-
-
-
-
-# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
-# -------------------------------------------------------------------
-# CONFIGNAME is the name given to the value in the libtool script.
-# VARNAME is the (base) name used in the configure script.
-# VALUE may be 0, 1 or 2 for a computed quote escaped value based on
-# VARNAME.  Any other value will be used directly.
-m4_define([_LT_DECL],
-[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
-    [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
-	[m4_ifval([$1], [$1], [$2])])
-    lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
-    m4_ifval([$4],
-	[lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
-    lt_dict_add_subkey([lt_decl_dict], [$2],
-	[tagged?], [m4_ifval([$5], [yes], [no])])])
-])
-
-
-# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
-# --------------------------------------------------------
-m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
-
-
-# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
-# ------------------------------------------------
-m4_define([lt_decl_tag_varnames],
-[_lt_decl_filter([tagged?], [yes], $@)])
-
-
-# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
-# ---------------------------------------------------------
-m4_define([_lt_decl_filter],
-[m4_case([$#],
-  [0], [m4_fatal([$0: too few arguments: $#])],
-  [1], [m4_fatal([$0: too few arguments: $#: $1])],
-  [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
-  [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
-  [lt_dict_filter([lt_decl_dict], $@)])[]dnl
-])
-
-
-# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
-# --------------------------------------------------
-m4_define([lt_decl_quote_varnames],
-[_lt_decl_filter([value], [1], $@)])
-
-
-# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
-# ---------------------------------------------------
-m4_define([lt_decl_dquote_varnames],
-[_lt_decl_filter([value], [2], $@)])
-
-
-# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
-# ---------------------------------------------------
-m4_define([lt_decl_varnames_tagged],
-[m4_assert([$# <= 2])dnl
-_$0(m4_quote(m4_default([$1], [[, ]])),
-    m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
-    m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
-m4_define([_lt_decl_varnames_tagged],
-[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
-
-
-# lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
-# ------------------------------------------------
-m4_define([lt_decl_all_varnames],
-[_$0(m4_quote(m4_default([$1], [[, ]])),
-     m4_if([$2], [],
-	   m4_quote(lt_decl_varnames),
-	m4_quote(m4_shift($@))))[]dnl
-])
-m4_define([_lt_decl_all_varnames],
-[lt_join($@, lt_decl_varnames_tagged([$1],
-			lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
-])
-
-
-# _LT_CONFIG_STATUS_DECLARE([VARNAME])
-# ------------------------------------
-# Quote a variable value, and forward it to `config.status' so that its
-# declaration there will have the same value as in `configure'.  VARNAME
-# must have a single quote delimited value for this to work.
-m4_define([_LT_CONFIG_STATUS_DECLARE],
-[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
-
-
-# _LT_CONFIG_STATUS_DECLARATIONS
-# ------------------------------
-# We delimit libtool config variables with single quotes, so when
-# we write them to config.status, we have to be sure to quote all
-# embedded single quotes properly.  In configure, this macro expands
-# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
-#
-#    <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
-m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
-[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
-    [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
-
-
-# _LT_LIBTOOL_TAGS
-# ----------------
-# Output comment and list of tags supported by the script
-m4_defun([_LT_LIBTOOL_TAGS],
-[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
-available_tags="_LT_TAGS"dnl
-])
-
-
-# _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
-# -----------------------------------
-# Extract the dictionary values for VARNAME (optionally with TAG) and
-# expand to a commented shell variable setting:
-#
-#    # Some comment about what VAR is for.
-#    visible_name=$lt_internal_name
-m4_define([_LT_LIBTOOL_DECLARE],
-[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
-					   [description])))[]dnl
-m4_pushdef([_libtool_name],
-    m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
-m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
-    [0], [_libtool_name=[$]$1],
-    [1], [_libtool_name=$lt_[]$1],
-    [2], [_libtool_name=$lt_[]$1],
-    [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
-m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
-])
-
-
-# _LT_LIBTOOL_CONFIG_VARS
-# -----------------------
-# Produce commented declarations of non-tagged libtool config variables
-# suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
-# script.  Tagged libtool config variables (even for the LIBTOOL CONFIG
-# section) are produced by _LT_LIBTOOL_TAG_VARS.
-m4_defun([_LT_LIBTOOL_CONFIG_VARS],
-[m4_foreach([_lt_var],
-    m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
-    [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
-
-
-# _LT_LIBTOOL_TAG_VARS(TAG)
-# -------------------------
-m4_define([_LT_LIBTOOL_TAG_VARS],
-[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
-    [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
-
-
-# _LT_TAGVAR(VARNAME, [TAGNAME])
-# ------------------------------
-m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
-
-
-# _LT_CONFIG_COMMANDS
-# -------------------
-# Send accumulated output to $CONFIG_STATUS.  Thanks to the lists of
-# variables for single and double quote escaping we saved from calls
-# to _LT_DECL, we can put quote escaped variables declarations
-# into `config.status', and then the shell code to quote escape them in
-# for loops in `config.status'.  Finally, any additional code accumulated
-# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
-m4_defun([_LT_CONFIG_COMMANDS],
-[AC_PROVIDE_IFELSE([LT_OUTPUT],
-	dnl If the libtool generation code has been placed in $CONFIG_LT,
-	dnl instead of duplicating it all over again into config.status,
-	dnl then we will have config.status run $CONFIG_LT later, so it
-	dnl needs to know what name is stored there:
-        [AC_CONFIG_COMMANDS([libtool],
-            [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
-    dnl If the libtool generation code is destined for config.status,
-    dnl expand the accumulated commands and init code now:
-    [AC_CONFIG_COMMANDS([libtool],
-        [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
-])#_LT_CONFIG_COMMANDS
-
-
-# Initialize.
-m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
-[
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-sed_quote_subst='$sed_quote_subst'
-double_quote_subst='$double_quote_subst'
-delay_variable_subst='$delay_variable_subst'
-_LT_CONFIG_STATUS_DECLARATIONS
-LTCC='$LTCC'
-LTCFLAGS='$LTCFLAGS'
-compiler='$compiler_DEFAULT'
-
-# Quote evaled strings.
-for var in lt_decl_all_varnames([[ \
-]], lt_decl_quote_varnames); do
-    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
-    *[[\\\\\\\`\\"\\\$]]*)
-      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
-      ;;
-    *)
-      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
-      ;;
-    esac
-done
-
-# Double-quote double-evaled strings.
-for var in lt_decl_all_varnames([[ \
-]], lt_decl_dquote_varnames); do
-    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
-    *[[\\\\\\\`\\"\\\$]]*)
-      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
-      ;;
-    *)
-      eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
-      ;;
-    esac
-done
-
-# Fix-up fallback echo if it was mangled by the above quoting rules.
-case \$lt_ECHO in
-*'\\\[$]0 --fallback-echo"')dnl "
-  lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
-  ;;
-esac
-
-_LT_OUTPUT_LIBTOOL_INIT
-])
-
-
-# LT_OUTPUT
-# ---------
-# This macro allows early generation of the libtool script (before
-# AC_OUTPUT is called), incase it is used in configure for compilation
-# tests.
-AC_DEFUN([LT_OUTPUT],
-[: ${CONFIG_LT=./config.lt}
-AC_MSG_NOTICE([creating $CONFIG_LT])
-cat >"$CONFIG_LT" <<_LTEOF
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate a libtool stub with the current configuration.
-
-lt_cl_silent=false
-SHELL=\${CONFIG_SHELL-$SHELL}
-_LTEOF
-
-cat >>"$CONFIG_LT" <<\_LTEOF
-AS_SHELL_SANITIZE
-_AS_PREPARE
-
-exec AS_MESSAGE_FD>&1
-exec AS_MESSAGE_LOG_FD>>config.log
-{
-  echo
-  AS_BOX([Running $as_me.])
-} >&AS_MESSAGE_LOG_FD
-
-lt_cl_help="\
-\`$as_me' creates a local libtool stub from the current configuration,
-for use in further configure time tests before the real libtool is
-generated.
-
-Usage: $[0] [[OPTIONS]]
-
-  -h, --help      print this help, then exit
-  -V, --version   print version number, then exit
-  -q, --quiet     do not print progress messages
-  -d, --debug     don't remove temporary files
-
-Report bugs to <bug-libtool at gnu.org>."
-
-lt_cl_version="\
-m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
-m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
-configured by $[0], generated by m4_PACKAGE_STRING.
-
-Copyright (C) 2008 Free Software Foundation, Inc.
-This config.lt script is free software; the Free Software Foundation
-gives unlimited permision to copy, distribute and modify it."
-
-while test $[#] != 0
-do
-  case $[1] in
-    --version | --v* | -V )
-      echo "$lt_cl_version"; exit 0 ;;
-    --help | --h* | -h )
-      echo "$lt_cl_help"; exit 0 ;;
-    --debug | --d* | -d )
-      debug=: ;;
-    --quiet | --q* | --silent | --s* | -q )
-      lt_cl_silent=: ;;
-
-    -*) AC_MSG_ERROR([unrecognized option: $[1]
-Try \`$[0] --help' for more information.]) ;;
-
-    *) AC_MSG_ERROR([unrecognized argument: $[1]
-Try \`$[0] --help' for more information.]) ;;
-  esac
-  shift
-done
-
-if $lt_cl_silent; then
-  exec AS_MESSAGE_FD>/dev/null
-fi
-_LTEOF
-
-cat >>"$CONFIG_LT" <<_LTEOF
-_LT_OUTPUT_LIBTOOL_COMMANDS_INIT
-_LTEOF
-
-cat >>"$CONFIG_LT" <<\_LTEOF
-AC_MSG_NOTICE([creating $ofile])
-_LT_OUTPUT_LIBTOOL_COMMANDS
-AS_EXIT(0)
-_LTEOF
-chmod +x "$CONFIG_LT"
-
-# configure is writing to config.log, but config.lt does its own redirection,
-# appending to config.log, which fails on DOS, as config.log is still kept
-# open by configure.  Here we exec the FD to /dev/null, effectively closing
-# config.log, so it can be properly (re)opened and appended to by config.lt.
-if test "$no_create" != yes; then
-  lt_cl_success=:
-  test "$silent" = yes &&
-    lt_config_lt_args="$lt_config_lt_args --quiet"
-  exec AS_MESSAGE_LOG_FD>/dev/null
-  $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
-  exec AS_MESSAGE_LOG_FD>>config.log
-  $lt_cl_success || AS_EXIT(1)
-fi
-])# LT_OUTPUT
-
-
-# _LT_CONFIG(TAG)
-# ---------------
-# If TAG is the built-in tag, create an initial libtool script with a
-# default configuration from the untagged config vars.  Otherwise add code
-# to config.status for appending the configuration named by TAG from the
-# matching tagged config vars.
-m4_defun([_LT_CONFIG],
-[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-_LT_CONFIG_SAVE_COMMANDS([
-  m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
-  m4_if(_LT_TAG, [C], [
-    # See if we are running on zsh, and set the options which allow our
-    # commands through without removal of \ escapes.
-    if test -n "${ZSH_VERSION+set}" ; then
-      setopt NO_GLOB_SUBST
-    fi
-
-    cfgfile="${ofile}T"
-    trap "$RM \"$cfgfile\"; exit 1" 1 2 15
-    $RM "$cfgfile"
-
-    cat <<_LT_EOF >> "$cfgfile"
-#! $SHELL
-
-# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
-# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-# NOTE: Changes made to this file will be lost: look at ltmain.sh.
-#
-_LT_COPYING
-_LT_LIBTOOL_TAGS
-
-# ### BEGIN LIBTOOL CONFIG
-_LT_LIBTOOL_CONFIG_VARS
-_LT_LIBTOOL_TAG_VARS
-# ### END LIBTOOL CONFIG
-
-_LT_EOF
-
-  case $host_os in
-  aix3*)
-    cat <<\_LT_EOF >> "$cfgfile"
-# AIX sometimes has problems with the GCC collect2 program.  For some
-# reason, if we set the COLLECT_NAMES environment variable, the problems
-# vanish in a puff of smoke.
-if test "X${COLLECT_NAMES+set}" != Xset; then
-  COLLECT_NAMES=
-  export COLLECT_NAMES
-fi
-_LT_EOF
-    ;;
-  esac
-
-  _LT_PROG_LTMAIN
-
-  # We use sed instead of cat because bash on DJGPP gets confused if
-  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
-  # text mode, it properly converts lines to CR/LF.  This bash problem
-  # is reportedly fixed, but why not run on old versions too?
-  sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
-    || (rm -f "$cfgfile"; exit 1)
-
-  _LT_PROG_XSI_SHELLFNS
-
-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
-    || (rm -f "$cfgfile"; exit 1)
-
-  mv -f "$cfgfile" "$ofile" ||
-    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
-  chmod +x "$ofile"
-],
-[cat <<_LT_EOF >> "$ofile"
-
-dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
-dnl in a comment (ie after a #).
-# ### BEGIN LIBTOOL TAG CONFIG: $1
-_LT_LIBTOOL_TAG_VARS(_LT_TAG)
-# ### END LIBTOOL TAG CONFIG: $1
-_LT_EOF
-])dnl /m4_if
-],
-[m4_if([$1], [], [
-    PACKAGE='$PACKAGE'
-    VERSION='$VERSION'
-    TIMESTAMP='$TIMESTAMP'
-    RM='$RM'
-    ofile='$ofile'], [])
-])dnl /_LT_CONFIG_SAVE_COMMANDS
-])# _LT_CONFIG
-
-
-# LT_SUPPORTED_TAG(TAG)
-# ---------------------
-# Trace this macro to discover what tags are supported by the libtool
-# --tag option, using:
-#    autoconf --trace 'LT_SUPPORTED_TAG:$1'
-AC_DEFUN([LT_SUPPORTED_TAG], [])
-
-
-# C support is built-in for now
-m4_define([_LT_LANG_C_enabled], [])
-m4_define([_LT_TAGS], [])
-
-
-# LT_LANG(LANG)
-# -------------
-# Enable libtool support for the given language if not already enabled.
-AC_DEFUN([LT_LANG],
-[AC_BEFORE([$0], [LT_OUTPUT])dnl
-m4_case([$1],
-  [C],			[_LT_LANG(C)],
-  [C++],		[_LT_LANG(CXX)],
-  [Java],		[_LT_LANG(GCJ)],
-  [Fortran 77],		[_LT_LANG(F77)],
-  [Fortran],		[_LT_LANG(FC)],
-  [Windows Resource],	[_LT_LANG(RC)],
-  [m4_ifdef([_LT_LANG_]$1[_CONFIG],
-    [_LT_LANG($1)],
-    [m4_fatal([$0: unsupported language: "$1"])])])dnl
-])# LT_LANG
-
-
-# _LT_LANG(LANGNAME)
-# ------------------
-m4_defun([_LT_LANG],
-[m4_ifdef([_LT_LANG_]$1[_enabled], [],
-  [LT_SUPPORTED_TAG([$1])dnl
-  m4_append([_LT_TAGS], [$1 ])dnl
-  m4_define([_LT_LANG_]$1[_enabled], [])dnl
-  _LT_LANG_$1_CONFIG($1)])dnl
-])# _LT_LANG
-
-
-# _LT_LANG_DEFAULT_CONFIG
-# -----------------------
-m4_defun([_LT_LANG_DEFAULT_CONFIG],
-[AC_PROVIDE_IFELSE([AC_PROG_CXX],
-  [LT_LANG(CXX)],
-  [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
-
-AC_PROVIDE_IFELSE([AC_PROG_F77],
-  [LT_LANG(F77)],
-  [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
-
-AC_PROVIDE_IFELSE([AC_PROG_FC],
-  [LT_LANG(FC)],
-  [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
-
-dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
-dnl pulling things in needlessly.
-AC_PROVIDE_IFELSE([AC_PROG_GCJ],
-  [LT_LANG(GCJ)],
-  [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
-    [LT_LANG(GCJ)],
-    [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
-      [LT_LANG(GCJ)],
-      [m4_ifdef([AC_PROG_GCJ],
-	[m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
-       m4_ifdef([A][M_PROG_GCJ],
-	[m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
-       m4_ifdef([LT_PROG_GCJ],
-	[m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
-
-AC_PROVIDE_IFELSE([LT_PROG_RC],
-  [LT_LANG(RC)],
-  [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
-])# _LT_LANG_DEFAULT_CONFIG
-
-# Obsolete macros:
-AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
-AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
-AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
-AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
-dnl AC_DEFUN([AC_LIBTOOL_F77], [])
-dnl AC_DEFUN([AC_LIBTOOL_FC], [])
-dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
-
-
-# _LT_TAG_COMPILER
-# ----------------
-m4_defun([_LT_TAG_COMPILER],
-[AC_REQUIRE([AC_PROG_CC])dnl
-
-_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
-_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
-_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
-_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-])# _LT_TAG_COMPILER
-
-
-# _LT_COMPILER_BOILERPLATE
-# ------------------------
-# Check for compiler boilerplate output or warnings with
-# the simple compiler test code.
-m4_defun([_LT_COMPILER_BOILERPLATE],
-[m4_require([_LT_DECL_SED])dnl
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-])# _LT_COMPILER_BOILERPLATE
-
-
-# _LT_LINKER_BOILERPLATE
-# ----------------------
-# Check for linker boilerplate output or warnings with
-# the simple link test code.
-m4_defun([_LT_LINKER_BOILERPLATE],
-[m4_require([_LT_DECL_SED])dnl
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-])# _LT_LINKER_BOILERPLATE
-
-# _LT_REQUIRED_DARWIN_CHECKS
-# -------------------------
-m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
-  case $host_os in
-    rhapsody* | darwin*)
-    AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
-    AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
-    AC_CHECK_TOOL([LIPO], [lipo], [:])
-    AC_CHECK_TOOL([OTOOL], [otool], [:])
-    AC_CHECK_TOOL([OTOOL64], [otool64], [:])
-    _LT_DECL([], [DSYMUTIL], [1],
-      [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
-    _LT_DECL([], [NMEDIT], [1],
-      [Tool to change global to local symbols on Mac OS X])
-    _LT_DECL([], [LIPO], [1],
-      [Tool to manipulate fat objects and archives on Mac OS X])
-    _LT_DECL([], [OTOOL], [1],
-      [ldd/readelf like tool for Mach-O binaries on Mac OS X])
-    _LT_DECL([], [OTOOL64], [1],
-      [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
-
-    AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
-      [lt_cv_apple_cc_single_mod=no
-      if test -z "${LT_MULTI_MODULE}"; then
-	# By default we will add the -single_module flag. You can override
-	# by either setting the environment variable LT_MULTI_MODULE
-	# non-empty at configure time, or by adding -multi_module to the
-	# link flags.
-	rm -rf libconftest.dylib*
-	echo "int foo(void){return 1;}" > conftest.c
-	echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
--dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
-	$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
-	  -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
-        _lt_result=$?
-	if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
-	  lt_cv_apple_cc_single_mod=yes
-	else
-	  cat conftest.err >&AS_MESSAGE_LOG_FD
-	fi
-	rm -rf libconftest.dylib*
-	rm -f conftest.*
-      fi])
-    AC_CACHE_CHECK([for -exported_symbols_list linker flag],
-      [lt_cv_ld_exported_symbols_list],
-      [lt_cv_ld_exported_symbols_list=no
-      save_LDFLAGS=$LDFLAGS
-      echo "_main" > conftest.sym
-      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
-      AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
-	[lt_cv_ld_exported_symbols_list=yes],
-	[lt_cv_ld_exported_symbols_list=no])
-	LDFLAGS="$save_LDFLAGS"
-    ])
-    case $host_os in
-    rhapsody* | darwin1.[[012]])
-      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
-    darwin1.*)
-      _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
-    darwin*) # darwin 5.x on
-      # if running on 10.5 or later, the deployment target defaults
-      # to the OS version, if on x86, and 10.4, the deployment
-      # target defaults to 10.4. Don't you love it?
-      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
-	10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
-	  _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
-	10.[[012]]*)
-	  _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
-	10.*)
-	  _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
-      esac
-    ;;
-  esac
-    if test "$lt_cv_apple_cc_single_mod" = "yes"; then
-      _lt_dar_single_mod='$single_module'
-    fi
-    if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
-      _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
-    else
-      _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
-    fi
-    if test "$DSYMUTIL" != ":"; then
-      _lt_dsymutil='~$DSYMUTIL $lib || :'
-    else
-      _lt_dsymutil=
-    fi
-    ;;
-  esac
-])
-
-
-# _LT_DARWIN_LINKER_FEATURES
-# --------------------------
-# Checks for linker and compiler features on darwin
-m4_defun([_LT_DARWIN_LINKER_FEATURES],
-[
-  m4_require([_LT_REQUIRED_DARWIN_CHECKS])
-  _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-  _LT_TAGVAR(hardcode_direct, $1)=no
-  _LT_TAGVAR(hardcode_automatic, $1)=yes
-  _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
-  _LT_TAGVAR(whole_archive_flag_spec, $1)=''
-  _LT_TAGVAR(link_all_deplibs, $1)=yes
-  _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
-  case $cc_basename in
-     ifort*) _lt_dar_can_shared=yes ;;
-     *) _lt_dar_can_shared=$GCC ;;
-  esac
-  if test "$_lt_dar_can_shared" = "yes"; then
-    output_verbose_link_cmd=echo
-    _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
-    _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
-    _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
-    _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
-    m4_if([$1], [CXX],
-[   if test "$lt_cv_apple_cc_single_mod" != "yes"; then
-      _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
-      _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
-    fi
-],[])
-  else
-  _LT_TAGVAR(ld_shlibs, $1)=no
-  fi
-])
-
-# _LT_SYS_MODULE_PATH_AIX
-# -----------------------
-# Links a minimal program and checks the executable
-# for the system default hardcoded library path. In most cases,
-# this is /usr/lib:/lib, but when the MPI compilers are used
-# the location of the communication and MPI libs are included too.
-# If we don't find anything, use the default library path according
-# to the aix ld manual.
-m4_defun([_LT_SYS_MODULE_PATH_AIX],
-[m4_require([_LT_DECL_SED])dnl
-AC_LINK_IFELSE(AC_LANG_PROGRAM,[
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi],[])
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-])# _LT_SYS_MODULE_PATH_AIX
-
-
-# _LT_SHELL_INIT(ARG)
-# -------------------
-m4_define([_LT_SHELL_INIT],
-[ifdef([AC_DIVERSION_NOTICE],
-	     [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
-	 [AC_DIVERT_PUSH(NOTICE)])
-$1
-AC_DIVERT_POP
-])# _LT_SHELL_INIT
-
-
-# _LT_PROG_ECHO_BACKSLASH
-# -----------------------
-# Add some code to the start of the generated configure script which
-# will find an echo command which doesn't interpret backslashes.
-m4_defun([_LT_PROG_ECHO_BACKSLASH],
-[_LT_SHELL_INIT([
-# Check that we are running under the correct shell.
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-case X$lt_ECHO in
-X*--fallback-echo)
-  # Remove one level of quotation (which was required for Make).
-  ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
-  ;;
-esac
-
-ECHO=${lt_ECHO-echo}
-if test "X[$]1" = X--no-reexec; then
-  # Discard the --no-reexec flag, and continue.
-  shift
-elif test "X[$]1" = X--fallback-echo; then
-  # Avoid inline document here, it may be left over
-  :
-elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
-  # Yippee, $ECHO works!
-  :
-else
-  # Restart under the correct shell.
-  exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
-fi
-
-if test "X[$]1" = X--fallback-echo; then
-  # used as fallback echo
-  shift
-  cat <<_LT_EOF
-[$]*
-_LT_EOF
-  exit 0
-fi
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-if test -z "$lt_ECHO"; then
-  if test "X${echo_test_string+set}" != Xset; then
-    # find a string as large as possible, as long as the shell can cope with it
-    for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
-      # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
-      if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
-	 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
-      then
-        break
-      fi
-    done
-  fi
-
-  if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
-     echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
-     test "X$echo_testing_string" = "X$echo_test_string"; then
-    :
-  else
-    # The Solaris, AIX, and Digital Unix default echo programs unquote
-    # backslashes.  This makes it impossible to quote backslashes using
-    #   echo "$something" | sed 's/\\/\\\\/g'
-    #
-    # So, first we look for a working echo in the user's PATH.
-
-    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-    for dir in $PATH /usr/ucb; do
-      IFS="$lt_save_ifs"
-      if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
-         test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
-         echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
-         test "X$echo_testing_string" = "X$echo_test_string"; then
-        ECHO="$dir/echo"
-        break
-      fi
-    done
-    IFS="$lt_save_ifs"
-
-    if test "X$ECHO" = Xecho; then
-      # We didn't find a better echo, so look for alternatives.
-      if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
-         echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
-         test "X$echo_testing_string" = "X$echo_test_string"; then
-        # This shell has a builtin print -r that does the trick.
-        ECHO='print -r'
-      elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
-	   test "X$CONFIG_SHELL" != X/bin/ksh; then
-        # If we have ksh, try running configure again with it.
-        ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
-        export ORIGINAL_CONFIG_SHELL
-        CONFIG_SHELL=/bin/ksh
-        export CONFIG_SHELL
-        exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
-      else
-        # Try using printf.
-        ECHO='printf %s\n'
-        if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
-	   echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
-	   test "X$echo_testing_string" = "X$echo_test_string"; then
-	  # Cool, printf works
-	  :
-        elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
-	     test "X$echo_testing_string" = 'X\t' &&
-	     echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
-	     test "X$echo_testing_string" = "X$echo_test_string"; then
-	  CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
-	  export CONFIG_SHELL
-	  SHELL="$CONFIG_SHELL"
-	  export SHELL
-	  ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
-        elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
-	     test "X$echo_testing_string" = 'X\t' &&
-	     echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
-	     test "X$echo_testing_string" = "X$echo_test_string"; then
-	  ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
-        else
-	  # maybe with a smaller string...
-	  prev=:
-
-	  for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
-	    if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
-	    then
-	      break
-	    fi
-	    prev="$cmd"
-	  done
-
-	  if test "$prev" != 'sed 50q "[$]0"'; then
-	    echo_test_string=`eval $prev`
-	    export echo_test_string
-	    exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
-	  else
-	    # Oops.  We lost completely, so just stick with echo.
-	    ECHO=echo
-	  fi
-        fi
-      fi
-    fi
-  fi
-fi
-
-# Copy echo and quote the copy suitably for passing to libtool from
-# the Makefile, instead of quoting the original, which is used later.
-lt_ECHO=$ECHO
-if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
-   lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
-fi
-
-AC_SUBST(lt_ECHO)
-])
-_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
-_LT_DECL([], [ECHO], [1],
-    [An echo program that does not interpret backslashes])
-])# _LT_PROG_ECHO_BACKSLASH
-
-
-# _LT_ENABLE_LOCK
-# ---------------
-m4_defun([_LT_ENABLE_LOCK],
-[AC_ARG_ENABLE([libtool-lock],
-  [AS_HELP_STRING([--disable-libtool-lock],
-    [avoid locking (might break parallel builds)])])
-test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
-
-# Some flags need to be propagated to the compiler or linker for good
-# libtool support.
-case $host in
-ia64-*-hpux*)
-  # Find out which ABI we are using.
-  echo 'int i;' > conftest.$ac_ext
-  if AC_TRY_EVAL(ac_compile); then
-    case `/usr/bin/file conftest.$ac_objext` in
-      *ELF-32*)
-	HPUX_IA64_MODE="32"
-	;;
-      *ELF-64*)
-	HPUX_IA64_MODE="64"
-	;;
-    esac
-  fi
-  rm -rf conftest*
-  ;;
-*-*-irix6*)
-  # Find out which ABI we are using.
-  echo '[#]line __oline__ "configure"' > conftest.$ac_ext
-  if AC_TRY_EVAL(ac_compile); then
-    if test "$lt_cv_prog_gnu_ld" = yes; then
-      case `/usr/bin/file conftest.$ac_objext` in
-	*32-bit*)
-	  LD="${LD-ld} -melf32bsmip"
-	  ;;
-	*N32*)
-	  LD="${LD-ld} -melf32bmipn32"
-	  ;;
-	*64-bit*)
-	  LD="${LD-ld} -melf64bmip"
-	;;
-      esac
-    else
-      case `/usr/bin/file conftest.$ac_objext` in
-	*32-bit*)
-	  LD="${LD-ld} -32"
-	  ;;
-	*N32*)
-	  LD="${LD-ld} -n32"
-	  ;;
-	*64-bit*)
-	  LD="${LD-ld} -64"
-	  ;;
-      esac
-    fi
-  fi
-  rm -rf conftest*
-  ;;
-
-x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
-s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
-  # Find out which ABI we are using.
-  echo 'int i;' > conftest.$ac_ext
-  if AC_TRY_EVAL(ac_compile); then
-    case `/usr/bin/file conftest.o` in
-      *32-bit*)
-	case $host in
-	  x86_64-*kfreebsd*-gnu)
-	    LD="${LD-ld} -m elf_i386_fbsd"
-	    ;;
-	  x86_64-*linux*)
-	    LD="${LD-ld} -m elf_i386"
-	    ;;
-	  ppc64-*linux*|powerpc64-*linux*)
-	    LD="${LD-ld} -m elf32ppclinux"
-	    ;;
-	  s390x-*linux*)
-	    LD="${LD-ld} -m elf_s390"
-	    ;;
-	  sparc64-*linux*)
-	    LD="${LD-ld} -m elf32_sparc"
-	    ;;
-	esac
-	;;
-      *64-bit*)
-	case $host in
-	  x86_64-*kfreebsd*-gnu)
-	    LD="${LD-ld} -m elf_x86_64_fbsd"
-	    ;;
-	  x86_64-*linux*)
-	    LD="${LD-ld} -m elf_x86_64"
-	    ;;
-	  ppc*-*linux*|powerpc*-*linux*)
-	    LD="${LD-ld} -m elf64ppc"
-	    ;;
-	  s390*-*linux*|s390*-*tpf*)
-	    LD="${LD-ld} -m elf64_s390"
-	    ;;
-	  sparc*-*linux*)
-	    LD="${LD-ld} -m elf64_sparc"
-	    ;;
-	esac
-	;;
-    esac
-  fi
-  rm -rf conftest*
-  ;;
-
-*-*-sco3.2v5*)
-  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
-  SAVE_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS -belf"
-  AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
-    [AC_LANG_PUSH(C)
-     AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
-     AC_LANG_POP])
-  if test x"$lt_cv_cc_needs_belf" != x"yes"; then
-    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
-    CFLAGS="$SAVE_CFLAGS"
-  fi
-  ;;
-sparc*-*solaris*)
-  # Find out which ABI we are using.
-  echo 'int i;' > conftest.$ac_ext
-  if AC_TRY_EVAL(ac_compile); then
-    case `/usr/bin/file conftest.o` in
-    *64-bit*)
-      case $lt_cv_prog_gnu_ld in
-      yes*) LD="${LD-ld} -m elf64_sparc" ;;
-      *)
-	if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
-	  LD="${LD-ld} -64"
-	fi
-	;;
-      esac
-      ;;
-    esac
-  fi
-  rm -rf conftest*
-  ;;
-esac
-
-need_locks="$enable_libtool_lock"
-])# _LT_ENABLE_LOCK
-
-
-# _LT_CMD_OLD_ARCHIVE
-# -------------------
-m4_defun([_LT_CMD_OLD_ARCHIVE],
-[AC_CHECK_TOOL(AR, ar, false)
-test -z "$AR" && AR=ar
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-_LT_DECL([], [AR], [1], [The archiver])
-_LT_DECL([], [AR_FLAGS], [1])
-
-AC_CHECK_TOOL(STRIP, strip, :)
-test -z "$STRIP" && STRIP=:
-_LT_DECL([], [STRIP], [1], [A symbol stripping program])
-
-AC_CHECK_TOOL(RANLIB, ranlib, :)
-test -z "$RANLIB" && RANLIB=:
-_LT_DECL([], [RANLIB], [1],
-    [Commands used to install an old-style archive])
-
-# Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
-old_postinstall_cmds='chmod 644 $oldlib'
-old_postuninstall_cmds=
-
-if test -n "$RANLIB"; then
-  case $host_os in
-  openbsd*)
-    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
-    ;;
-  *)
-    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
-    ;;
-  esac
-  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
-fi
-_LT_DECL([], [old_postinstall_cmds], [2])
-_LT_DECL([], [old_postuninstall_cmds], [2])
-_LT_TAGDECL([], [old_archive_cmds], [2],
-    [Commands used to build an old-style archive])
-])# _LT_CMD_OLD_ARCHIVE
-
-
-# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
-#		[OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
-# ----------------------------------------------------------------
-# Check whether the given compiler option works
-AC_DEFUN([_LT_COMPILER_OPTION],
-[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-m4_require([_LT_DECL_SED])dnl
-AC_CACHE_CHECK([$1], [$2],
-  [$2=no
-   m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
-   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-   lt_compiler_flag="$3"
-   # Insert the option either (1) after the last *FLAGS variable, or
-   # (2) before a word containing "conftest.", or (3) at the end.
-   # Note that $ac_compile itself does not contain backslashes and begins
-   # with a dollar sign (not a hyphen), so the echo should work correctly.
-   # The option is referenced via a variable to avoid confusing sed.
-   lt_compile=`echo "$ac_compile" | $SED \
-   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
-   -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
-   (eval "$lt_compile" 2>conftest.err)
-   ac_status=$?
-   cat conftest.err >&AS_MESSAGE_LOG_FD
-   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
-   if (exit $ac_status) && test -s "$ac_outfile"; then
-     # The compiler can only warn and ignore the option if not recognized
-     # So say no if there are warnings other than the usual output.
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
-     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
-     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
-       $2=yes
-     fi
-   fi
-   $RM conftest*
-])
-
-if test x"[$]$2" = xyes; then
-    m4_if([$5], , :, [$5])
-else
-    m4_if([$6], , :, [$6])
-fi
-])# _LT_COMPILER_OPTION
-
-# Old name:
-AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
-
-
-# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
-#                  [ACTION-SUCCESS], [ACTION-FAILURE])
-# ----------------------------------------------------
-# Check whether the given linker option works
-AC_DEFUN([_LT_LINKER_OPTION],
-[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-m4_require([_LT_DECL_SED])dnl
-AC_CACHE_CHECK([$1], [$2],
-  [$2=no
-   save_LDFLAGS="$LDFLAGS"
-   LDFLAGS="$LDFLAGS $3"
-   echo "$lt_simple_link_test_code" > conftest.$ac_ext
-   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
-     # The linker can only warn and ignore the option if not recognized
-     # So say no if there are warnings
-     if test -s conftest.err; then
-       # Append any errors to the config.log.
-       cat conftest.err 1>&AS_MESSAGE_LOG_FD
-       $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
-       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
-       if diff conftest.exp conftest.er2 >/dev/null; then
-         $2=yes
-       fi
-     else
-       $2=yes
-     fi
-   fi
-   $RM -r conftest*
-   LDFLAGS="$save_LDFLAGS"
-])
-
-if test x"[$]$2" = xyes; then
-    m4_if([$4], , :, [$4])
-else
-    m4_if([$5], , :, [$5])
-fi
-])# _LT_LINKER_OPTION
-
-# Old name:
-AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
-
-
-# LT_CMD_MAX_LEN
-#---------------
-AC_DEFUN([LT_CMD_MAX_LEN],
-[AC_REQUIRE([AC_CANONICAL_HOST])dnl
-# find the maximum length of command line arguments
-AC_MSG_CHECKING([the maximum length of command line arguments])
-AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
-  i=0
-  teststring="ABCD"
-
-  case $build_os in
-  msdosdjgpp*)
-    # On DJGPP, this test can blow up pretty badly due to problems in libc
-    # (any single argument exceeding 2000 bytes causes a buffer overrun
-    # during glob expansion).  Even if it were fixed, the result of this
-    # check would be larger than it should be.
-    lt_cv_sys_max_cmd_len=12288;    # 12K is about right
-    ;;
-
-  gnu*)
-    # Under GNU Hurd, this test is not required because there is
-    # no limit to the length of command line arguments.
-    # Libtool will interpret -1 as no limit whatsoever
-    lt_cv_sys_max_cmd_len=-1;
-    ;;
-
-  cygwin* | mingw* | cegcc*)
-    # On Win9x/ME, this test blows up -- it succeeds, but takes
-    # about 5 minutes as the teststring grows exponentially.
-    # Worse, since 9x/ME are not pre-emptively multitasking,
-    # you end up with a "frozen" computer, even though with patience
-    # the test eventually succeeds (with a max line length of 256k).
-    # Instead, let's just punt: use the minimum linelength reported by
-    # all of the supported platforms: 8192 (on NT/2K/XP).
-    lt_cv_sys_max_cmd_len=8192;
-    ;;
-
-  amigaos*)
-    # On AmigaOS with pdksh, this test takes hours, literally.
-    # So we just punt and use a minimum line length of 8192.
-    lt_cv_sys_max_cmd_len=8192;
-    ;;
-
-  netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
-    # This has been around since 386BSD, at least.  Likely further.
-    if test -x /sbin/sysctl; then
-      lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
-    elif test -x /usr/sbin/sysctl; then
-      lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
-    else
-      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
-    fi
-    # And add a safety zone
-    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
-    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
-    ;;
-
-  interix*)
-    # We know the value 262144 and hardcode it with a safety zone (like BSD)
-    lt_cv_sys_max_cmd_len=196608
-    ;;
-
-  osf*)
-    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
-    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
-    # nice to cause kernel panics so lets avoid the loop below.
-    # First set a reasonable default.
-    lt_cv_sys_max_cmd_len=16384
-    #
-    if test -x /sbin/sysconfig; then
-      case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
-        *1*) lt_cv_sys_max_cmd_len=-1 ;;
-      esac
-    fi
-    ;;
-  sco3.2v5*)
-    lt_cv_sys_max_cmd_len=102400
-    ;;
-  sysv5* | sco5v6* | sysv4.2uw2*)
-    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
-    if test -n "$kargmax"; then
-      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[	 ]]//'`
-    else
-      lt_cv_sys_max_cmd_len=32768
-    fi
-    ;;
-  *)
-    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
-    if test -n "$lt_cv_sys_max_cmd_len"; then
-      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
-      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
-    else
-      # Make teststring a little bigger before we do anything with it.
-      # a 1K string should be a reasonable start.
-      for i in 1 2 3 4 5 6 7 8 ; do
-        teststring=$teststring$teststring
-      done
-      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
-      # If test is not a shell built-in, we'll probably end up computing a
-      # maximum length that is only half of the actual maximum length, but
-      # we can't tell.
-      while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
-	         = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
-	      test $i != 17 # 1/2 MB should be enough
-      do
-        i=`expr $i + 1`
-        teststring=$teststring$teststring
-      done
-      # Only check the string length outside the loop.
-      lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
-      teststring=
-      # Add a significant safety factor because C++ compilers can tack on
-      # massive amounts of additional arguments before passing them to the
-      # linker.  It appears as though 1/2 is a usable value.
-      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
-    fi
-    ;;
-  esac
-])
-if test -n $lt_cv_sys_max_cmd_len ; then
-  AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
-else
-  AC_MSG_RESULT(none)
-fi
-max_cmd_len=$lt_cv_sys_max_cmd_len
-_LT_DECL([], [max_cmd_len], [0],
-    [What is the maximum length of a command?])
-])# LT_CMD_MAX_LEN
-
-# Old name:
-AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
-
-
-# _LT_HEADER_DLFCN
-# ----------------
-m4_defun([_LT_HEADER_DLFCN],
-[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
-])# _LT_HEADER_DLFCN
-
-
-# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
-#                      ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
-# ----------------------------------------------------------------
-m4_defun([_LT_TRY_DLOPEN_SELF],
-[m4_require([_LT_HEADER_DLFCN])dnl
-if test "$cross_compiling" = yes; then :
-  [$4]
-else
-  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
-  lt_status=$lt_dlunknown
-  cat > conftest.$ac_ext <<_LT_EOF
-[#line __oline__ "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-#  define LT_DLGLOBAL		RTLD_GLOBAL
-#else
-#  ifdef DL_GLOBAL
-#    define LT_DLGLOBAL		DL_GLOBAL
-#  else
-#    define LT_DLGLOBAL		0
-#  endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
-   find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-#  ifdef RTLD_LAZY
-#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
-#  else
-#    ifdef DL_LAZY
-#      define LT_DLLAZY_OR_NOW		DL_LAZY
-#    else
-#      ifdef RTLD_NOW
-#        define LT_DLLAZY_OR_NOW	RTLD_NOW
-#      else
-#        ifdef DL_NOW
-#          define LT_DLLAZY_OR_NOW	DL_NOW
-#        else
-#          define LT_DLLAZY_OR_NOW	0
-#        endif
-#      endif
-#    endif
-#  endif
-#endif
-
-void fnord() { int i=42;}
-int main ()
-{
-  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-  int status = $lt_dlunknown;
-
-  if (self)
-    {
-      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
-      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
-      /* dlclose (self); */
-    }
-  else
-    puts (dlerror ());
-
-  return status;
-}]
-_LT_EOF
-  if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
-    (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
-    lt_status=$?
-    case x$lt_status in
-      x$lt_dlno_uscore) $1 ;;
-      x$lt_dlneed_uscore) $2 ;;
-      x$lt_dlunknown|x*) $3 ;;
-    esac
-  else :
-    # compilation failed
-    $3
-  fi
-fi
-rm -fr conftest*
-])# _LT_TRY_DLOPEN_SELF
-
-
-# LT_SYS_DLOPEN_SELF
-# ------------------
-AC_DEFUN([LT_SYS_DLOPEN_SELF],
-[m4_require([_LT_HEADER_DLFCN])dnl
-if test "x$enable_dlopen" != xyes; then
-  enable_dlopen=unknown
-  enable_dlopen_self=unknown
-  enable_dlopen_self_static=unknown
-else
-  lt_cv_dlopen=no
-  lt_cv_dlopen_libs=
-
-  case $host_os in
-  beos*)
-    lt_cv_dlopen="load_add_on"
-    lt_cv_dlopen_libs=
-    lt_cv_dlopen_self=yes
-    ;;
-
-  mingw* | pw32* | cegcc*)
-    lt_cv_dlopen="LoadLibrary"
-    lt_cv_dlopen_libs=
-    ;;
-
-  cygwin*)
-    lt_cv_dlopen="dlopen"
-    lt_cv_dlopen_libs=
-    ;;
-
-  darwin*)
-  # if libdl is installed we need to link against it
-    AC_CHECK_LIB([dl], [dlopen],
-		[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
-    lt_cv_dlopen="dyld"
-    lt_cv_dlopen_libs=
-    lt_cv_dlopen_self=yes
-    ])
-    ;;
-
-  *)
-    AC_CHECK_FUNC([shl_load],
-	  [lt_cv_dlopen="shl_load"],
-      [AC_CHECK_LIB([dld], [shl_load],
-	    [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
-	[AC_CHECK_FUNC([dlopen],
-	      [lt_cv_dlopen="dlopen"],
-	  [AC_CHECK_LIB([dl], [dlopen],
-		[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
-	    [AC_CHECK_LIB([svld], [dlopen],
-		  [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
-	      [AC_CHECK_LIB([dld], [dld_link],
-		    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
-	      ])
-	    ])
-	  ])
-	])
-      ])
-    ;;
-  esac
-
-  if test "x$lt_cv_dlopen" != xno; then
-    enable_dlopen=yes
-  else
-    enable_dlopen=no
-  fi
-
-  case $lt_cv_dlopen in
-  dlopen)
-    save_CPPFLAGS="$CPPFLAGS"
-    test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
-    save_LDFLAGS="$LDFLAGS"
-    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
-    save_LIBS="$LIBS"
-    LIBS="$lt_cv_dlopen_libs $LIBS"
-
-    AC_CACHE_CHECK([whether a program can dlopen itself],
-	  lt_cv_dlopen_self, [dnl
-	  _LT_TRY_DLOPEN_SELF(
-	    lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
-	    lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
-    ])
-
-    if test "x$lt_cv_dlopen_self" = xyes; then
-      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
-      AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
-	  lt_cv_dlopen_self_static, [dnl
-	  _LT_TRY_DLOPEN_SELF(
-	    lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
-	    lt_cv_dlopen_self_static=no,  lt_cv_dlopen_self_static=cross)
-      ])
-    fi
-
-    CPPFLAGS="$save_CPPFLAGS"
-    LDFLAGS="$save_LDFLAGS"
-    LIBS="$save_LIBS"
-    ;;
-  esac
-
-  case $lt_cv_dlopen_self in
-  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
-  *) enable_dlopen_self=unknown ;;
-  esac
-
-  case $lt_cv_dlopen_self_static in
-  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
-  *) enable_dlopen_self_static=unknown ;;
-  esac
-fi
-_LT_DECL([dlopen_support], [enable_dlopen], [0],
-	 [Whether dlopen is supported])
-_LT_DECL([dlopen_self], [enable_dlopen_self], [0],
-	 [Whether dlopen of programs is supported])
-_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
-	 [Whether dlopen of statically linked programs is supported])
-])# LT_SYS_DLOPEN_SELF
-
-# Old name:
-AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
-
-
-# _LT_COMPILER_C_O([TAGNAME])
-# ---------------------------
-# Check to see if options -c and -o are simultaneously supported by compiler.
-# This macro does not hard code the compiler like AC_PROG_CC_C_O.
-m4_defun([_LT_COMPILER_C_O],
-[m4_require([_LT_DECL_SED])dnl
-m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-m4_require([_LT_TAG_COMPILER])dnl
-AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
-  [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
-  [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
-   $RM -r conftest 2>/dev/null
-   mkdir conftest
-   cd conftest
-   mkdir out
-   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
-   lt_compiler_flag="-o out/conftest2.$ac_objext"
-   # Insert the option either (1) after the last *FLAGS variable, or
-   # (2) before a word containing "conftest.", or (3) at the end.
-   # Note that $ac_compile itself does not contain backslashes and begins
-   # with a dollar sign (not a hyphen), so the echo should work correctly.
-   lt_compile=`echo "$ac_compile" | $SED \
-   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-   -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
-   -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
-   (eval "$lt_compile" 2>out/conftest.err)
-   ac_status=$?
-   cat out/conftest.err >&AS_MESSAGE_LOG_FD
-   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
-   if (exit $ac_status) && test -s out/conftest2.$ac_objext
-   then
-     # The compiler can only warn and ignore the option if not recognized
-     # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
-     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
-     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
-       _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
-     fi
-   fi
-   chmod u+w . 2>&AS_MESSAGE_LOG_FD
-   $RM conftest*
-   # SGI C++ compiler will create directory out/ii_files/ for
-   # template instantiation
-   test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
-   $RM out/* && rmdir out
-   cd ..
-   $RM -r conftest
-   $RM conftest*
-])
-_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
-	[Does compiler simultaneously support -c and -o options?])
-])# _LT_COMPILER_C_O
-
-
-# _LT_COMPILER_FILE_LOCKS([TAGNAME])
-# ----------------------------------
-# Check to see if we can do hard links to lock some files if needed
-m4_defun([_LT_COMPILER_FILE_LOCKS],
-[m4_require([_LT_ENABLE_LOCK])dnl
-m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-_LT_COMPILER_C_O([$1])
-
-hard_links="nottested"
-if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
-  # do not overwrite the value of need_locks provided by the user
-  AC_MSG_CHECKING([if we can lock with hard links])
-  hard_links=yes
-  $RM conftest*
-  ln conftest.a conftest.b 2>/dev/null && hard_links=no
-  touch conftest.a
-  ln conftest.a conftest.b 2>&5 || hard_links=no
-  ln conftest.a conftest.b 2>/dev/null && hard_links=no
-  AC_MSG_RESULT([$hard_links])
-  if test "$hard_links" = no; then
-    AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
-    need_locks=warn
-  fi
-else
-  need_locks=no
-fi
-_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
-])# _LT_COMPILER_FILE_LOCKS
-
-
-# _LT_CHECK_OBJDIR
-# ----------------
-m4_defun([_LT_CHECK_OBJDIR],
-[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
-[rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
-  lt_cv_objdir=.libs
-else
-  # MS-DOS does not allow filenames that begin with a dot.
-  lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null])
-objdir=$lt_cv_objdir
-_LT_DECL([], [objdir], [0],
-         [The name of the directory that contains temporary libtool files])dnl
-m4_pattern_allow([LT_OBJDIR])dnl
-AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
-  [Define to the sub-directory in which libtool stores uninstalled libraries.])
-])# _LT_CHECK_OBJDIR
-
-
-# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
-# --------------------------------------
-# Check hardcoding attributes.
-m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
-[AC_MSG_CHECKING([how to hardcode library paths into programs])
-_LT_TAGVAR(hardcode_action, $1)=
-if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
-   test -n "$_LT_TAGVAR(runpath_var, $1)" ||
-   test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
-
-  # We can hardcode non-existent directories.
-  if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
-     # If the only mechanism to avoid hardcoding is shlibpath_var, we
-     # have to relink, otherwise we might link with an installed library
-     # when we should be linking with a yet-to-be-installed one
-     ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
-     test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
-    # Linking always hardcodes the temporary library directory.
-    _LT_TAGVAR(hardcode_action, $1)=relink
-  else
-    # We can link without hardcoding, and we can hardcode nonexisting dirs.
-    _LT_TAGVAR(hardcode_action, $1)=immediate
-  fi
-else
-  # We cannot hardcode anything, or else we can only hardcode existing
-  # directories.
-  _LT_TAGVAR(hardcode_action, $1)=unsupported
-fi
-AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
-
-if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
-   test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
-  # Fast installation is not supported
-  enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
-     test "$enable_shared" = no; then
-  # Fast installation is not necessary
-  enable_fast_install=needless
-fi
-_LT_TAGDECL([], [hardcode_action], [0],
-    [How to hardcode a shared library path into an executable])
-])# _LT_LINKER_HARDCODE_LIBPATH
-
-
-# _LT_CMD_STRIPLIB
-# ----------------
-m4_defun([_LT_CMD_STRIPLIB],
-[m4_require([_LT_DECL_EGREP])
-striplib=
-old_striplib=
-AC_MSG_CHECKING([whether stripping libraries is possible])
-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
-  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
-  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
-  AC_MSG_RESULT([yes])
-else
-# FIXME - insert some real tests, host_os isn't really good enough
-  case $host_os in
-  darwin*)
-    if test -n "$STRIP" ; then
-      striplib="$STRIP -x"
-      old_striplib="$STRIP -S"
-      AC_MSG_RESULT([yes])
-    else
-      AC_MSG_RESULT([no])
-    fi
-    ;;
-  *)
-    AC_MSG_RESULT([no])
-    ;;
-  esac
-fi
-_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
-_LT_DECL([], [striplib], [1])
-])# _LT_CMD_STRIPLIB
-
-
-# _LT_SYS_DYNAMIC_LINKER([TAG])
-# -----------------------------
-# PORTME Fill in your ld.so characteristics
-m4_defun([_LT_SYS_DYNAMIC_LINKER],
-[AC_REQUIRE([AC_CANONICAL_HOST])dnl
-m4_require([_LT_DECL_EGREP])dnl
-m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-m4_require([_LT_DECL_OBJDUMP])dnl
-m4_require([_LT_DECL_SED])dnl
-AC_MSG_CHECKING([dynamic linker characteristics])
-m4_if([$1],
-	[], [
-if test "$GCC" = yes; then
-  case $host_os in
-    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
-    *) lt_awk_arg="/^libraries:/" ;;
-  esac
-  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-  if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
-    # if the path contains ";" then we assume it to be the separator
-    # otherwise default to the standard path separator (i.e. ":") - it is
-    # assumed that no part of a normal pathname contains ";" but that should
-    # okay in the real world where ";" in dirpaths is itself problematic.
-    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
-  else
-    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-  fi
-  # Ok, now we have the path, separated by spaces, we can step through it
-  # and add multilib dir if necessary.
-  lt_tmp_lt_search_path_spec=
-  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
-  for lt_sys_path in $lt_search_path_spec; do
-    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
-      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
-    else
-      test -d "$lt_sys_path" && \
-	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
-    fi
-  done
-  lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
-BEGIN {RS=" "; FS="/|\n";} {
-  lt_foo="";
-  lt_count=0;
-  for (lt_i = NF; lt_i > 0; lt_i--) {
-    if ($lt_i != "" && $lt_i != ".") {
-      if ($lt_i == "..") {
-        lt_count++;
-      } else {
-        if (lt_count == 0) {
-          lt_foo="/" $lt_i lt_foo;
-        } else {
-          lt_count--;
-        }
-      }
-    }
-  }
-  if (lt_foo != "") { lt_freq[[lt_foo]]++; }
-  if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
-}'`
-  sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
-else
-  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi])
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
-  version_type=linux
-  library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
-  shlibpath_var=LIBPATH
-
-  # AIX 3 has no versioning support, so we append a major version to the name.
-  soname_spec='${libname}${release}${shared_ext}$major'
-  ;;
-
-aix[[4-9]]*)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  hardcode_into_libs=yes
-  if test "$host_cpu" = ia64; then
-    # AIX 5 supports IA64
-    library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
-    shlibpath_var=LD_LIBRARY_PATH
-  else
-    # With GCC up to 2.95.x, collect2 would create an import file
-    # for dependence libraries.  The import file would start with
-    # the line `#! .'.  This would cause the generated library to
-    # depend on `.', always an invalid library.  This was fixed in
-    # development snapshots of GCC prior to 3.0.
-    case $host_os in
-      aix4 | aix4.[[01]] | aix4.[[01]].*)
-      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
-	   echo ' yes '
-	   echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
-	:
-      else
-	can_build_shared=no
-      fi
-      ;;
-    esac
-    # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
-    # soname into executable. Probably we can add versioning support to
-    # collect2, so additional links can be useful in future.
-    if test "$aix_use_runtimelinking" = yes; then
-      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
-      # instead of lib<name>.a to let people know that these are not
-      # typical AIX shared libraries.
-      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-    else
-      # We preserve .a as extension for shared libraries through AIX4.2
-      # and later when we are not doing run time linking.
-      library_names_spec='${libname}${release}.a $libname.a'
-      soname_spec='${libname}${release}${shared_ext}$major'
-    fi
-    shlibpath_var=LIBPATH
-  fi
-  ;;
-
-amigaos*)
-  case $host_cpu in
-  powerpc)
-    # Since July 2007 AmigaOS4 officially supports .so libraries.
-    # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
-    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-    ;;
-  m68k)
-    library_names_spec='$libname.ixlibrary $libname.a'
-    # Create ${libname}_ixlibrary.a entries in /sys/libs.
-    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
-    ;;
-  esac
-  ;;
-
-beos*)
-  library_names_spec='${libname}${shared_ext}'
-  dynamic_linker="$host_os ld.so"
-  shlibpath_var=LIBRARY_PATH
-  ;;
-
-bsdi[[45]]*)
-  version_type=linux
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
-  shlibpath_var=LD_LIBRARY_PATH
-  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
-  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
-  # the default ld.so.conf also contains /usr/contrib/lib and
-  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
-  # libtool to hard-code these into programs
-  ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
-  version_type=windows
-  shrext_cmds=".dll"
-  need_version=no
-  need_lib_prefix=no
-
-  case $GCC,$host_os in
-  yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
-    library_names_spec='$libname.dll.a'
-    # DLL is installed to $(libdir)/../bin by postinstall_cmds
-    postinstall_cmds='base_file=`basename \${file}`~
-      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
-      dldir=$destdir/`dirname \$dlpath`~
-      test -d \$dldir || mkdir -p \$dldir~
-      $install_prog $dir/$dlname \$dldir/$dlname~
-      chmod a+x \$dldir/$dlname~
-      if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
-        eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
-      fi'
-    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
-      dlpath=$dir/\$dldll~
-       $RM \$dlpath'
-    shlibpath_overrides_runpath=yes
-
-    case $host_os in
-    cygwin*)
-      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
-      soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
-      ;;
-    mingw* | cegcc*)
-      # MinGW DLLs use traditional 'lib' prefix
-      soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-      if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
-        # It is most probably a Windows format PATH printed by
-        # mingw gcc, but we are running on Cygwin. Gcc prints its search
-        # path with ; separators, and with drive letters. We can handle the
-        # drive letters (cygwin fileutils understands them), so leave them,
-        # especially as we might pass files found there to a mingw objdump,
-        # which wouldn't understand a cygwinified path. Ahh.
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
-      else
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-      fi
-      ;;
-    pw32*)
-      # pw32 DLLs use 'pw' prefix rather than 'lib'
-      library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
-      ;;
-    esac
-    ;;
-
-  *)
-    library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
-    ;;
-  esac
-  dynamic_linker='Win32 ld.exe'
-  # FIXME: first we should search . and the directory the executable is in
-  shlibpath_var=PATH
-  ;;
-
-darwin* | rhapsody*)
-  dynamic_linker="$host_os dyld"
-  version_type=darwin
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
-  soname_spec='${libname}${release}${major}$shared_ext'
-  shlibpath_overrides_runpath=yes
-  shlibpath_var=DYLD_LIBRARY_PATH
-  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-m4_if([$1], [],[
-  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
-  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
-  ;;
-
-dgux*)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  ;;
-
-freebsd1*)
-  dynamic_linker=no
-  ;;
-
-freebsd* | dragonfly*)
-  # DragonFly does not have aout.  When/if they implement a new
-  # versioning mechanism, adjust this.
-  if test -x /usr/bin/objformat; then
-    objformat=`/usr/bin/objformat`
-  else
-    case $host_os in
-    freebsd[[123]]*) objformat=aout ;;
-    *) objformat=elf ;;
-    esac
-  fi
-  version_type=freebsd-$objformat
-  case $version_type in
-    freebsd-elf*)
-      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
-      need_version=no
-      need_lib_prefix=no
-      ;;
-    freebsd-*)
-      library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
-      need_version=yes
-      ;;
-  esac
-  shlibpath_var=LD_LIBRARY_PATH
-  case $host_os in
-  freebsd2*)
-    shlibpath_overrides_runpath=yes
-    ;;
-  freebsd3.[[01]]* | freebsdelf3.[[01]]*)
-    shlibpath_overrides_runpath=yes
-    hardcode_into_libs=yes
-    ;;
-  freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
-  freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
-    shlibpath_overrides_runpath=no
-    hardcode_into_libs=yes
-    ;;
-  *) # from 4.6 on, and DragonFly
-    shlibpath_overrides_runpath=yes
-    hardcode_into_libs=yes
-    ;;
-  esac
-  ;;
-
-gnu*)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  hardcode_into_libs=yes
-  ;;
-
-hpux9* | hpux10* | hpux11*)
-  # Give a soname corresponding to the major version so that dld.sl refuses to
-  # link against other versions.
-  version_type=sunos
-  need_lib_prefix=no
-  need_version=no
-  case $host_cpu in
-  ia64*)
-    shrext_cmds='.so'
-    hardcode_into_libs=yes
-    dynamic_linker="$host_os dld.so"
-    shlibpath_var=LD_LIBRARY_PATH
-    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
-    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-    soname_spec='${libname}${release}${shared_ext}$major'
-    if test "X$HPUX_IA64_MODE" = X32; then
-      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
-    else
-      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
-    fi
-    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
-    ;;
-  hppa*64*)
-    shrext_cmds='.sl'
-    hardcode_into_libs=yes
-    dynamic_linker="$host_os dld.sl"
-    shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
-    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
-    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-    soname_spec='${libname}${release}${shared_ext}$major'
-    sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
-    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
-    ;;
-  *)
-    shrext_cmds='.sl'
-    dynamic_linker="$host_os dld.sl"
-    shlibpath_var=SHLIB_PATH
-    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
-    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-    soname_spec='${libname}${release}${shared_ext}$major'
-    ;;
-  esac
-  # HP-UX runs *really* slowly unless shared libraries are mode 555.
-  postinstall_cmds='chmod 555 $lib'
-  ;;
-
-interix[[3-9]]*)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  ;;
-
-irix5* | irix6* | nonstopux*)
-  case $host_os in
-    nonstopux*) version_type=nonstopux ;;
-    *)
-	if test "$lt_cv_prog_gnu_ld" = yes; then
-		version_type=linux
-	else
-		version_type=irix
-	fi ;;
-  esac
-  need_lib_prefix=no
-  need_version=no
-  soname_spec='${libname}${release}${shared_ext}$major'
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
-  case $host_os in
-  irix5* | nonstopux*)
-    libsuff= shlibsuff=
-    ;;
-  *)
-    case $LD in # libtool.m4 will add one of these switches to LD
-    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
-      libsuff= shlibsuff= libmagic=32-bit;;
-    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
-      libsuff=32 shlibsuff=N32 libmagic=N32;;
-    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
-      libsuff=64 shlibsuff=64 libmagic=64-bit;;
-    *) libsuff= shlibsuff= libmagic=never-match;;
-    esac
-    ;;
-  esac
-  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
-  shlibpath_overrides_runpath=no
-  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
-  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
-  hardcode_into_libs=yes
-  ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
-  dynamic_linker=no
-  ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  # Some binutils ld are patched to set DT_RUNPATH
-  save_LDFLAGS=$LDFLAGS
-  save_libdir=$libdir
-  eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
-       LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
-  AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
-    [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
-       [shlibpath_overrides_runpath=yes])])
-  LDFLAGS=$save_LDFLAGS
-  libdir=$save_libdir
-
-  # This implies no fast_install, which is unacceptable.
-  # Some rework will be needed to allow for fast_install
-  # before this can be enabled.
-  hardcode_into_libs=yes
-
-  # Append ld.so.conf contents to the search path
-  if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
-    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
-  fi
-
-  # We used to test for /lib/ld.so.1 and disable shared libraries on
-  # powerpc, because MkLinux only supported shared libraries with the
-  # GNU dynamic linker.  Since this was broken with cross compilers,
-  # most powerpc-linux boxes support dynamic linking these days and
-  # people can always --disable-shared, the test was removed, and we
-  # assume the GNU/Linux dynamic linker is in use.
-  dynamic_linker='GNU/Linux ld.so'
-  ;;
-
-netbsd*)
-  version_type=sunos
-  need_lib_prefix=no
-  need_version=no
-  if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
-    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
-    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
-    dynamic_linker='NetBSD (a.out) ld.so'
-  else
-    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-    soname_spec='${libname}${release}${shared_ext}$major'
-    dynamic_linker='NetBSD ld.elf_so'
-  fi
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=yes
-  hardcode_into_libs=yes
-  ;;
-
-newsos6)
-  version_type=linux
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=yes
-  ;;
-
-*nto* | *qnx*)
-  version_type=qnx
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='ldqnx.so'
-  ;;
-
-openbsd*)
-  version_type=sunos
-  sys_lib_dlsearch_path_spec="/usr/lib"
-  need_lib_prefix=no
-  # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
-  case $host_os in
-    openbsd3.3 | openbsd3.3.*)	need_version=yes ;;
-    *)				need_version=no  ;;
-  esac
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
-  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
-  shlibpath_var=LD_LIBRARY_PATH
-  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-    case $host_os in
-      openbsd2.[[89]] | openbsd2.[[89]].*)
-	shlibpath_overrides_runpath=no
-	;;
-      *)
-	shlibpath_overrides_runpath=yes
-	;;
-      esac
-  else
-    shlibpath_overrides_runpath=yes
-  fi
-  ;;
-
-os2*)
-  libname_spec='$name'
-  shrext_cmds=".dll"
-  need_lib_prefix=no
-  library_names_spec='$libname${shared_ext} $libname.a'
-  dynamic_linker='OS/2 ld.exe'
-  shlibpath_var=LIBPATH
-  ;;
-
-osf3* | osf4* | osf5*)
-  version_type=osf
-  need_lib_prefix=no
-  need_version=no
-  soname_spec='${libname}${release}${shared_ext}$major'
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  shlibpath_var=LD_LIBRARY_PATH
-  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
-  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
-  ;;
-
-rdos*)
-  dynamic_linker=no
-  ;;
-
-solaris*)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=yes
-  hardcode_into_libs=yes
-  # ldd complains unless libraries are executable
-  postinstall_cmds='chmod +x $lib'
-  ;;
-
-sunos4*)
-  version_type=sunos
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
-  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=yes
-  if test "$with_gnu_ld" = yes; then
-    need_lib_prefix=no
-  fi
-  need_version=yes
-  ;;
-
-sysv4 | sysv4.3*)
-  version_type=linux
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  case $host_vendor in
-    sni)
-      shlibpath_overrides_runpath=no
-      need_lib_prefix=no
-      runpath_var=LD_RUN_PATH
-      ;;
-    siemens)
-      need_lib_prefix=no
-      ;;
-    motorola)
-      need_lib_prefix=no
-      need_version=no
-      shlibpath_overrides_runpath=no
-      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
-      ;;
-  esac
-  ;;
-
-sysv4*MP*)
-  if test -d /usr/nec ;then
-    version_type=linux
-    library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
-    soname_spec='$libname${shared_ext}.$major'
-    shlibpath_var=LD_LIBRARY_PATH
-  fi
-  ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
-  version_type=freebsd-elf
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=yes
-  hardcode_into_libs=yes
-  if test "$with_gnu_ld" = yes; then
-    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
-  else
-    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
-    case $host_os in
-      sco3.2v5*)
-        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
-	;;
-    esac
-  fi
-  sys_lib_dlsearch_path_spec='/usr/lib'
-  ;;
-
-tpf*)
-  # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  ;;
-
-uts4*)
-  version_type=linux
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  ;;
-
-*)
-  dynamic_linker=no
-  ;;
-esac
-AC_MSG_RESULT([$dynamic_linker])
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
-  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
-  sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
-  sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-_LT_DECL([], [variables_saved_for_relink], [1],
-    [Variables whose values should be saved in libtool wrapper scripts and
-    restored at link time])
-_LT_DECL([], [need_lib_prefix], [0],
-    [Do we need the "lib" prefix for modules?])
-_LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
-_LT_DECL([], [version_type], [0], [Library versioning type])
-_LT_DECL([], [runpath_var], [0],  [Shared library runtime path variable])
-_LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
-_LT_DECL([], [shlibpath_overrides_runpath], [0],
-    [Is shlibpath searched before the hard-coded library search path?])
-_LT_DECL([], [libname_spec], [1], [Format of library name prefix])
-_LT_DECL([], [library_names_spec], [1],
-    [[List of archive names.  First name is the real one, the rest are links.
-    The last name is the one that the linker finds with -lNAME]])
-_LT_DECL([], [soname_spec], [1],
-    [[The coded name of the library, if different from the real name]])
-_LT_DECL([], [postinstall_cmds], [2],
-    [Command to use after installation of a shared archive])
-_LT_DECL([], [postuninstall_cmds], [2],
-    [Command to use after uninstallation of a shared archive])
-_LT_DECL([], [finish_cmds], [2],
-    [Commands used to finish a libtool library installation in a directory])
-_LT_DECL([], [finish_eval], [1],
-    [[As "finish_cmds", except a single script fragment to be evaled but
-    not shown]])
-_LT_DECL([], [hardcode_into_libs], [0],
-    [Whether we should hardcode library paths into libraries])
-_LT_DECL([], [sys_lib_search_path_spec], [2],
-    [Compile-time system search path for libraries])
-_LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
-    [Run-time system search path for libraries])
-])# _LT_SYS_DYNAMIC_LINKER
-
-
-# _LT_PATH_TOOL_PREFIX(TOOL)
-# --------------------------
-# find a file program which can recognize shared library
-AC_DEFUN([_LT_PATH_TOOL_PREFIX],
-[m4_require([_LT_DECL_EGREP])dnl
-AC_MSG_CHECKING([for $1])
-AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
-[case $MAGIC_CMD in
-[[\\/*] |  ?:[\\/]*])
-  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
-  ;;
-*)
-  lt_save_MAGIC_CMD="$MAGIC_CMD"
-  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-dnl $ac_dummy forces splitting on constant user-supplied paths.
-dnl POSIX.2 word splitting is done only on the output of word expansions,
-dnl not every word.  This closes a longstanding sh security hole.
-  ac_dummy="m4_if([$2], , $PATH, [$2])"
-  for ac_dir in $ac_dummy; do
-    IFS="$lt_save_ifs"
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$1; then
-      lt_cv_path_MAGIC_CMD="$ac_dir/$1"
-      if test -n "$file_magic_test_file"; then
-	case $deplibs_check_method in
-	"file_magic "*)
-	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
-	  MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
-	    $EGREP "$file_magic_regex" > /dev/null; then
-	    :
-	  else
-	    cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such.  This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem.  Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool at gnu.org
-
-_LT_EOF
-	  fi ;;
-	esac
-      fi
-      break
-    fi
-  done
-  IFS="$lt_save_ifs"
-  MAGIC_CMD="$lt_save_MAGIC_CMD"
-  ;;
-esac])
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
-  AC_MSG_RESULT($MAGIC_CMD)
-else
-  AC_MSG_RESULT(no)
-fi
-_LT_DECL([], [MAGIC_CMD], [0],
-	 [Used to examine libraries when file_magic_cmd begins with "file"])dnl
-])# _LT_PATH_TOOL_PREFIX
-
-# Old name:
-AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
-
-
-# _LT_PATH_MAGIC
-# --------------
-# find a file program which can recognize a shared library
-m4_defun([_LT_PATH_MAGIC],
-[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
-if test -z "$lt_cv_path_MAGIC_CMD"; then
-  if test -n "$ac_tool_prefix"; then
-    _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
-  else
-    MAGIC_CMD=:
-  fi
-fi
-])# _LT_PATH_MAGIC
-
-
-# LT_PATH_LD
-# ----------
-# find the pathname to the GNU or non-GNU linker
-AC_DEFUN([LT_PATH_LD],
-[AC_REQUIRE([AC_PROG_CC])dnl
-AC_REQUIRE([AC_CANONICAL_HOST])dnl
-AC_REQUIRE([AC_CANONICAL_BUILD])dnl
-m4_require([_LT_DECL_SED])dnl
-m4_require([_LT_DECL_EGREP])dnl
-
-AC_ARG_WITH([gnu-ld],
-    [AS_HELP_STRING([--with-gnu-ld],
-	[assume the C compiler uses GNU ld @<:@default=no@:>@])],
-    [test "$withval" = no || with_gnu_ld=yes],
-    [with_gnu_ld=no])dnl
-
-ac_prog=ld
-if test "$GCC" = yes; then
-  # Check if gcc -print-prog-name=ld gives a path.
-  AC_MSG_CHECKING([for ld used by $CC])
-  case $host in
-  *-*-mingw*)
-    # gcc leaves a trailing carriage return which upsets mingw
-    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
-  *)
-    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
-  esac
-  case $ac_prog in
-    # Accept absolute paths.
-    [[\\/]]* | ?:[[\\/]]*)
-      re_direlt='/[[^/]][[^/]]*/\.\./'
-      # Canonicalize the pathname of ld
-      ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
-      while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
-	ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
-      done
-      test -z "$LD" && LD="$ac_prog"
-      ;;
-  "")
-    # If it fails, then pretend we aren't using GCC.
-    ac_prog=ld
-    ;;
-  *)
-    # If it is relative, then search for the first ld in PATH.
-    with_gnu_ld=unknown
-    ;;
-  esac
-elif test "$with_gnu_ld" = yes; then
-  AC_MSG_CHECKING([for GNU ld])
-else
-  AC_MSG_CHECKING([for non-GNU ld])
-fi
-AC_CACHE_VAL(lt_cv_path_LD,
-[if test -z "$LD"; then
-  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-  for ac_dir in $PATH; do
-    IFS="$lt_save_ifs"
-    test -z "$ac_dir" && ac_dir=.
-    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
-      lt_cv_path_LD="$ac_dir/$ac_prog"
-      # Check to see if the program is GNU ld.  I'd rather use --version,
-      # but apparently some variants of GNU ld only accept -v.
-      # Break only if it was the GNU/non-GNU ld that we prefer.
-      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
-      *GNU* | *'with BFD'*)
-	test "$with_gnu_ld" != no && break
-	;;
-      *)
-	test "$with_gnu_ld" != yes && break
-	;;
-      esac
-    fi
-  done
-  IFS="$lt_save_ifs"
-else
-  lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi])
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
-  AC_MSG_RESULT($LD)
-else
-  AC_MSG_RESULT(no)
-fi
-test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
-_LT_PATH_LD_GNU
-AC_SUBST([LD])
-
-_LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
-])# LT_PATH_LD
-
-# Old names:
-AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
-AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AM_PROG_LD], [])
-dnl AC_DEFUN([AC_PROG_LD], [])
-
-
-# _LT_PATH_LD_GNU
-#- --------------
-m4_defun([_LT_PATH_LD_GNU],
-[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
-[# I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
-  lt_cv_prog_gnu_ld=yes
-  ;;
-*)
-  lt_cv_prog_gnu_ld=no
-  ;;
-esac])
-with_gnu_ld=$lt_cv_prog_gnu_ld
-])# _LT_PATH_LD_GNU
-
-
-# _LT_CMD_RELOAD
-# --------------
-# find reload flag for linker
-#   -- PORTME Some linkers may need a different reload flag.
-m4_defun([_LT_CMD_RELOAD],
-[AC_CACHE_CHECK([for $LD option to reload object files],
-  lt_cv_ld_reload_flag,
-  [lt_cv_ld_reload_flag='-r'])
-reload_flag=$lt_cv_ld_reload_flag
-case $reload_flag in
-"" | " "*) ;;
-*) reload_flag=" $reload_flag" ;;
-esac
-reload_cmds='$LD$reload_flag -o $output$reload_objs'
-case $host_os in
-  darwin*)
-    if test "$GCC" = yes; then
-      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-    else
-      reload_cmds='$LD$reload_flag -o $output$reload_objs'
-    fi
-    ;;
-esac
-_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
-_LT_DECL([], [reload_cmds], [2])dnl
-])# _LT_CMD_RELOAD
-
-
-# _LT_CHECK_MAGIC_METHOD
-# ----------------------
-# how to check for library dependencies
-#  -- PORTME fill in with the dynamic library characteristics
-m4_defun([_LT_CHECK_MAGIC_METHOD],
-[m4_require([_LT_DECL_EGREP])
-m4_require([_LT_DECL_OBJDUMP])
-AC_CACHE_CHECK([how to recognize dependent libraries],
-lt_cv_deplibs_check_method,
-[lt_cv_file_magic_cmd='$MAGIC_CMD'
-lt_cv_file_magic_test_file=
-lt_cv_deplibs_check_method='unknown'
-# Need to set the preceding variable on all platforms that support
-# interlibrary dependencies.
-# 'none' -- dependencies not supported.
-# `unknown' -- same as none, but documents that we really don't know.
-# 'pass_all' -- all dependencies passed with no checks.
-# 'test_compile' -- check by making test program.
-# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given extended regex.
-# If you have `file' or equivalent on your system and you're not sure
-# whether `pass_all' will *always* work, you probably want this one.
-
-case $host_os in
-aix[[4-9]]*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-beos*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-bsdi[[45]]*)
-  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
-  lt_cv_file_magic_cmd='/usr/bin/file -L'
-  lt_cv_file_magic_test_file=/shlib/libc.so
-  ;;
-
-cygwin*)
-  # func_win32_libid is a shell function defined in ltmain.sh
-  lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
-  lt_cv_file_magic_cmd='func_win32_libid'
-  ;;
-
-mingw* | pw32*)
-  # Base MSYS/MinGW do not provide the 'file' command needed by
-  # func_win32_libid shell function, so use a weaker test based on 'objdump',
-  # unless we find 'file', for example because we are cross-compiling.
-  if ( file / ) >/dev/null 2>&1; then
-    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
-    lt_cv_file_magic_cmd='func_win32_libid'
-  else
-    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
-    lt_cv_file_magic_cmd='$OBJDUMP -f'
-  fi
-  ;;
-
-cegcc)
-  # use the weaker test based on 'objdump'. See mingw*.
-  lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
-  lt_cv_file_magic_cmd='$OBJDUMP -f'
-  ;;
-
-darwin* | rhapsody*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-freebsd* | dragonfly*)
-  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
-    case $host_cpu in
-    i*86 )
-      # Not sure whether the presence of OpenBSD here was a mistake.
-      # Let's accept both of them until this is cleared up.
-      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
-      lt_cv_file_magic_cmd=/usr/bin/file
-      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
-      ;;
-    esac
-  else
-    lt_cv_deplibs_check_method=pass_all
-  fi
-  ;;
-
-gnu*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-hpux10.20* | hpux11*)
-  lt_cv_file_magic_cmd=/usr/bin/file
-  case $host_cpu in
-  ia64*)
-    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
-    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
-    ;;
-  hppa*64*)
-    [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
-    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
-    ;;
-  *)
-    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
-    lt_cv_file_magic_test_file=/usr/lib/libc.sl
-    ;;
-  esac
-  ;;
-
-interix[[3-9]]*)
-  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
-  lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
-  ;;
-
-irix5* | irix6* | nonstopux*)
-  case $LD in
-  *-32|*"-32 ") libmagic=32-bit;;
-  *-n32|*"-n32 ") libmagic=N32;;
-  *-64|*"-64 ") libmagic=64-bit;;
-  *) libmagic=never-match;;
-  esac
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-netbsd*)
-  if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
-    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
-  else
-    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
-  fi
-  ;;
-
-newos6*)
-  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
-  lt_cv_file_magic_cmd=/usr/bin/file
-  lt_cv_file_magic_test_file=/usr/lib/libnls.so
-  ;;
-
-*nto* | *qnx*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-openbsd*)
-  if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
-  else
-    lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
-  fi
-  ;;
-
-osf3* | osf4* | osf5*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-rdos*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-solaris*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-
-sysv4 | sysv4.3*)
-  case $host_vendor in
-  motorola)
-    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
-    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
-    ;;
-  ncr)
-    lt_cv_deplibs_check_method=pass_all
-    ;;
-  sequent)
-    lt_cv_file_magic_cmd='/bin/file'
-    lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
-    ;;
-  sni)
-    lt_cv_file_magic_cmd='/bin/file'
-    lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
-    lt_cv_file_magic_test_file=/lib/libc.so
-    ;;
-  siemens)
-    lt_cv_deplibs_check_method=pass_all
-    ;;
-  pc)
-    lt_cv_deplibs_check_method=pass_all
-    ;;
-  esac
-  ;;
-
-tpf*)
-  lt_cv_deplibs_check_method=pass_all
-  ;;
-esac
-])
-file_magic_cmd=$lt_cv_file_magic_cmd
-deplibs_check_method=$lt_cv_deplibs_check_method
-test -z "$deplibs_check_method" && deplibs_check_method=unknown
-
-_LT_DECL([], [deplibs_check_method], [1],
-    [Method to check whether dependent libraries are shared objects])
-_LT_DECL([], [file_magic_cmd], [1],
-    [Command to use when deplibs_check_method == "file_magic"])
-])# _LT_CHECK_MAGIC_METHOD
-
-
-# LT_PATH_NM
-# ----------
-# find the pathname to a BSD- or MS-compatible name lister
-AC_DEFUN([LT_PATH_NM],
-[AC_REQUIRE([AC_PROG_CC])dnl
-AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
-[if test -n "$NM"; then
-  # Let the user override the test.
-  lt_cv_path_NM="$NM"
-else
-  lt_nm_to_check="${ac_tool_prefix}nm"
-  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
-    lt_nm_to_check="$lt_nm_to_check nm"
-  fi
-  for lt_tmp_nm in $lt_nm_to_check; do
-    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
-      IFS="$lt_save_ifs"
-      test -z "$ac_dir" && ac_dir=.
-      tmp_nm="$ac_dir/$lt_tmp_nm"
-      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
-	# Check to see if the nm accepts a BSD-compat flag.
-	# Adding the `sed 1q' prevents false positives on HP-UX, which says:
-	#   nm: unknown option "B" ignored
-	# Tru64's nm complains that /dev/null is an invalid object file
-	case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
-	*/dev/null* | *'Invalid file or object type'*)
-	  lt_cv_path_NM="$tmp_nm -B"
-	  break
-	  ;;
-	*)
-	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
-	  */dev/null*)
-	    lt_cv_path_NM="$tmp_nm -p"
-	    break
-	    ;;
-	  *)
-	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
-	    continue # so that we can try to find one that supports BSD flags
-	    ;;
-	  esac
-	  ;;
-	esac
-      fi
-    done
-    IFS="$lt_save_ifs"
-  done
-  : ${lt_cv_path_NM=no}
-fi])
-if test "$lt_cv_path_NM" != "no"; then
-  NM="$lt_cv_path_NM"
-else
-  # Didn't find any BSD compatible name lister, look for dumpbin.
-  AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
-  AC_SUBST([DUMPBIN])
-  if test "$DUMPBIN" != ":"; then
-    NM="$DUMPBIN"
-  fi
-fi
-test -z "$NM" && NM=nm
-AC_SUBST([NM])
-_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
-
-AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
-  [lt_cv_nm_interface="BSD nm"
-  echo "int some_variable = 0;" > conftest.$ac_ext
-  (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
-  (eval "$ac_compile" 2>conftest.err)
-  cat conftest.err >&AS_MESSAGE_LOG_FD
-  (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
-  (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
-  cat conftest.err >&AS_MESSAGE_LOG_FD
-  (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
-  cat conftest.out >&AS_MESSAGE_LOG_FD
-  if $GREP 'External.*some_variable' conftest.out > /dev/null; then
-    lt_cv_nm_interface="MS dumpbin"
-  fi
-  rm -f conftest*])
-])# LT_PATH_NM
-
-# Old names:
-AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
-AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AM_PROG_NM], [])
-dnl AC_DEFUN([AC_PROG_NM], [])
-
-
-# LT_LIB_M
-# --------
-# check for math library
-AC_DEFUN([LT_LIB_M],
-[AC_REQUIRE([AC_CANONICAL_HOST])dnl
-LIBM=
-case $host in
-*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
-  # These system don't have libm, or don't need it
-  ;;
-*-ncr-sysv4.3*)
-  AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
-  AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
-  ;;
-*)
-  AC_CHECK_LIB(m, cos, LIBM="-lm")
-  ;;
-esac
-AC_SUBST([LIBM])
-])# LT_LIB_M
-
-# Old name:
-AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_CHECK_LIBM], [])
-
-
-# _LT_COMPILER_NO_RTTI([TAGNAME])
-# -------------------------------
-m4_defun([_LT_COMPILER_NO_RTTI],
-[m4_require([_LT_TAG_COMPILER])dnl
-
-_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
-
-if test "$GCC" = yes; then
-  _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
-
-  _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
-    lt_cv_prog_compiler_rtti_exceptions,
-    [-fno-rtti -fno-exceptions], [],
-    [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
-fi
-_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
-	[Compiler flag to turn off builtin functions])
-])# _LT_COMPILER_NO_RTTI
-
-
-# _LT_CMD_GLOBAL_SYMBOLS
-# ----------------------
-m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
-[AC_REQUIRE([AC_CANONICAL_HOST])dnl
-AC_REQUIRE([AC_PROG_CC])dnl
-AC_REQUIRE([LT_PATH_NM])dnl
-AC_REQUIRE([LT_PATH_LD])dnl
-m4_require([_LT_DECL_SED])dnl
-m4_require([_LT_DECL_EGREP])dnl
-m4_require([_LT_TAG_COMPILER])dnl
-
-# Check for command to grab the raw symbol name followed by C symbol from nm.
-AC_MSG_CHECKING([command to parse $NM output from $compiler object])
-AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
-[
-# These are sane defaults that work on at least a few old systems.
-# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
-
-# Character class describing NM global symbol codes.
-symcode='[[BCDEGRST]]'
-
-# Regexp to match symbols that can be accessed directly from C.
-sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
-
-# Define system-specific variables.
-case $host_os in
-aix*)
-  symcode='[[BCDT]]'
-  ;;
-cygwin* | mingw* | pw32* | cegcc*)
-  symcode='[[ABCDGISTW]]'
-  ;;
-hpux*)
-  if test "$host_cpu" = ia64; then
-    symcode='[[ABCDEGRST]]'
-  fi
-  ;;
-irix* | nonstopux*)
-  symcode='[[BCDEGRST]]'
-  ;;
-osf*)
-  symcode='[[BCDEGQRST]]'
-  ;;
-solaris*)
-  symcode='[[BDRT]]'
-  ;;
-sco3.2v5*)
-  symcode='[[DT]]'
-  ;;
-sysv4.2uw2*)
-  symcode='[[DT]]'
-  ;;
-sysv5* | sco5v6* | unixware* | OpenUNIX*)
-  symcode='[[ABDT]]'
-  ;;
-sysv4)
-  symcode='[[DFNSTU]]'
-  ;;
-esac
-
-# If we're using GNU nm, then use its standard symbol codes.
-case `$NM -V 2>&1` in
-*GNU* | *'with BFD'*)
-  symcode='[[ABCDGIRSTW]]' ;;
-esac
-
-# Transform an extracted symbol line into a proper C declaration.
-# Some systems (esp. on ia64) link data and code symbols differently,
-# so use this general approach.
-lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
-
-# Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
-
-# Handle CRLF in mingw tool chain
-opt_cr=
-case $build_os in
-mingw*)
-  opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
-  ;;
-esac
-
-# Try without a prefix underscore, then with it.
-for ac_symprfx in "" "_"; do
-
-  # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
-  symxfrm="\\1 $ac_symprfx\\2 \\2"
-
-  # Write the raw and C identifiers.
-  if test "$lt_cv_nm_interface" = "MS dumpbin"; then
-    # Fake it for dumpbin and say T for any non-static function
-    # and D for any global variable.
-    # Also find C++ and __fastcall symbols from MSVC++,
-    # which start with @ or ?.
-    lt_cv_sys_global_symbol_pipe="$AWK ['"\
-"     {last_section=section; section=\$ 3};"\
-"     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
-"     \$ 0!~/External *\|/{next};"\
-"     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
-"     {if(hide[section]) next};"\
-"     {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-"     {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-"     s[1]~/^[@?]/{print s[1], s[1]; next};"\
-"     s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
-"     ' prfx=^$ac_symprfx]"
-  else
-    lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[	 ]]\($symcode$symcode*\)[[	 ]][[	 ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
-  fi
-
-  # Check to see that the pipe works correctly.
-  pipe_works=no
-
-  rm -f conftest*
-  cat > conftest.$ac_ext <<_LT_EOF
-#ifdef __cplusplus
-extern "C" {
-#endif
-char nm_test_var;
-void nm_test_func(void);
-void nm_test_func(void){}
-#ifdef __cplusplus
-}
-#endif
-int main(){nm_test_var='a';nm_test_func();return(0);}
-_LT_EOF
-
-  if AC_TRY_EVAL(ac_compile); then
-    # Now try to grab the symbols.
-    nlist=conftest.nm
-    if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
-      # Try sorting and uniquifying the output.
-      if sort "$nlist" | uniq > "$nlist"T; then
-	mv -f "$nlist"T "$nlist"
-      else
-	rm -f "$nlist"T
-      fi
-
-      # Make sure that we snagged all the symbols we need.
-      if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
-	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
-	  cat <<_LT_EOF > conftest.$ac_ext
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-_LT_EOF
-	  # Now generate the symbol file.
-	  eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
-
-	  cat <<_LT_EOF >> conftest.$ac_ext
-
-/* The mapping between symbol names and symbols.  */
-const struct {
-  const char *name;
-  void       *address;
-}
-lt__PROGRAM__LTX_preloaded_symbols[[]] =
-{
-  { "@PROGRAM@", (void *) 0 },
-_LT_EOF
-	  $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
-	  cat <<\_LT_EOF >> conftest.$ac_ext
-  {0, (void *) 0}
-};
-
-/* This works around a problem in FreeBSD linker */
-#ifdef FREEBSD_WORKAROUND
-static const void *lt_preloaded_setup() {
-  return lt__PROGRAM__LTX_preloaded_symbols;
-}
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-_LT_EOF
-	  # Now try linking the two files.
-	  mv conftest.$ac_objext conftstm.$ac_objext
-	  lt_save_LIBS="$LIBS"
-	  lt_save_CFLAGS="$CFLAGS"
-	  LIBS="conftstm.$ac_objext"
-	  CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
-	  if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
-	    pipe_works=yes
-	  fi
-	  LIBS="$lt_save_LIBS"
-	  CFLAGS="$lt_save_CFLAGS"
-	else
-	  echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
-	fi
-      else
-	echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
-      fi
-    else
-      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
-    fi
-  else
-    echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
-    cat conftest.$ac_ext >&5
-  fi
-  rm -rf conftest* conftst*
-
-  # Do not use the global_symbol_pipe unless it works.
-  if test "$pipe_works" = yes; then
-    break
-  else
-    lt_cv_sys_global_symbol_pipe=
-  fi
-done
-])
-if test -z "$lt_cv_sys_global_symbol_pipe"; then
-  lt_cv_sys_global_symbol_to_cdecl=
-fi
-if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
-  AC_MSG_RESULT(failed)
-else
-  AC_MSG_RESULT(ok)
-fi
-
-_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
-    [Take the output of nm and produce a listing of raw symbols and C names])
-_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
-    [Transform the output of nm in a proper C declaration])
-_LT_DECL([global_symbol_to_c_name_address],
-    [lt_cv_sys_global_symbol_to_c_name_address], [1],
-    [Transform the output of nm in a C name address pair])
-_LT_DECL([global_symbol_to_c_name_address_lib_prefix],
-    [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
-    [Transform the output of nm in a C name address pair when lib prefix is needed])
-]) # _LT_CMD_GLOBAL_SYMBOLS
-
-
-# _LT_COMPILER_PIC([TAGNAME])
-# ---------------------------
-m4_defun([_LT_COMPILER_PIC],
-[m4_require([_LT_TAG_COMPILER])dnl
-_LT_TAGVAR(lt_prog_compiler_wl, $1)=
-_LT_TAGVAR(lt_prog_compiler_pic, $1)=
-_LT_TAGVAR(lt_prog_compiler_static, $1)=
-
-AC_MSG_CHECKING([for $compiler option to produce PIC])
-m4_if([$1], [CXX], [
-  # C++ specific cases for pic, static, wl, etc.
-  if test "$GXX" = yes; then
-    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
-
-    case $host_os in
-    aix*)
-      # All AIX code is PIC.
-      if test "$host_cpu" = ia64; then
-	# AIX 5 now supports IA64 processor
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      fi
-      ;;
-
-    amigaos*)
-      case $host_cpu in
-      powerpc)
-            # see comment about AmigaOS4 .so support
-            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-        ;;
-      m68k)
-            # FIXME: we need at least 68020 code to build shared libraries, but
-            # adding the `-m68020' flag to GCC prevents building anything better,
-            # like `-m68040'.
-            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
-        ;;
-      esac
-      ;;
-
-    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
-      # PIC is the default for these OSes.
-      ;;
-    mingw* | cygwin* | os2* | pw32* | cegcc*)
-      # This hack is so that the source file can tell whether it is being
-      # built for inclusion in a dll (and should export symbols for example).
-      # Although the cygwin gcc ignores -fPIC, still need this for old-style
-      # (--disable-auto-import) libraries
-      m4_if([$1], [GCJ], [],
-	[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
-      ;;
-    darwin* | rhapsody*)
-      # PIC is the default on this platform
-      # Common symbols not allowed in MH_DYLIB files
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
-      ;;
-    *djgpp*)
-      # DJGPP does not support shared libraries at all
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)=
-      ;;
-    interix[[3-9]]*)
-      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
-      # Instead, we relocate shared libraries at runtime.
-      ;;
-    sysv4*MP*)
-      if test -d /usr/nec; then
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
-      fi
-      ;;
-    hpux*)
-      # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
-      # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
-      # sets the default TLS model and affects inlining.
-      case $host_cpu in
-      hppa*64*)
-	;;
-      *)
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-	;;
-      esac
-      ;;
-    *qnx* | *nto*)
-      # QNX uses GNU C++, but need to define -shared option too, otherwise
-      # it will coredump.
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
-      ;;
-    *)
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-      ;;
-    esac
-  else
-    case $host_os in
-      aix[[4-9]]*)
-	# All AIX code is PIC.
-	if test "$host_cpu" = ia64; then
-	  # AIX 5 now supports IA64 processor
-	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	else
-	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
-	fi
-	;;
-      chorus*)
-	case $cc_basename in
-	cxch68*)
-	  # Green Hills C++ Compiler
-	  # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
-	  ;;
-	esac
-	;;
-      dgux*)
-	case $cc_basename in
-	  ec++*)
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	    ;;
-	  ghcx*)
-	    # Green Hills C++ Compiler
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      freebsd* | dragonfly*)
-	# FreeBSD uses GNU C++
-	;;
-      hpux9* | hpux10* | hpux11*)
-	case $cc_basename in
-	  CC*)
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
-	    if test "$host_cpu" != ia64; then
-	      _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
-	    fi
-	    ;;
-	  aCC*)
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
-	    case $host_cpu in
-	    hppa*64*|ia64*)
-	      # +Z the default
-	      ;;
-	    *)
-	      _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
-	      ;;
-	    esac
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      interix*)
-	# This is c89, which is MS Visual C++ (no shared libs)
-	# Anyone wants to do a port?
-	;;
-      irix5* | irix6* | nonstopux*)
-	case $cc_basename in
-	  CC*)
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
-	    # CC pic flag -KPIC is the default.
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      linux* | k*bsd*-gnu)
-	case $cc_basename in
-	  KCC*)
-	    # KAI C++ Compiler
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-	    ;;
-	  ecpc* )
-	    # old Intel C++ for x86_64 which still supported -KPIC.
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
-	    ;;
-	  icpc* )
-	    # Intel C++, used to be incompatible with GCC.
-	    # ICC 10 doesn't accept -KPIC any more.
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
-	    ;;
-	  pgCC* | pgcpp*)
-	    # Portland Group C++ compiler
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	    ;;
-	  cxx*)
-	    # Compaq C++
-	    # Make sure the PIC flag is empty.  It appears that all Alpha
-	    # Linux and Compaq Tru64 Unix objects are PIC.
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)=
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
-	    ;;
-	  xlc* | xlC*)
-	    # IBM XL 8.0 on PPC
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
-	    ;;
-	  *)
-	    case `$CC -V 2>&1 | sed 5q` in
-	    *Sun\ C*)
-	      # Sun C++ 5.9
-	      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
-	      ;;
-	    esac
-	    ;;
-	esac
-	;;
-      lynxos*)
-	;;
-      m88k*)
-	;;
-      mvs*)
-	case $cc_basename in
-	  cxx*)
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      netbsd*)
-	;;
-      *qnx* | *nto*)
-        # QNX uses GNU C++, but need to define -shared option too, otherwise
-        # it will coredump.
-        _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
-        ;;
-      osf3* | osf4* | osf5*)
-	case $cc_basename in
-	  KCC*)
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
-	    ;;
-	  RCC*)
-	    # Rational C++ 2.4.1
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
-	    ;;
-	  cxx*)
-	    # Digital/Compaq C++
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    # Make sure the PIC flag is empty.  It appears that all Alpha
-	    # Linux and Compaq Tru64 Unix objects are PIC.
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)=
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      psos*)
-	;;
-      solaris*)
-	case $cc_basename in
-	  CC*)
-	    # Sun C++ 4.2, 5.x and Centerline C++
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
-	    ;;
-	  gcx*)
-	    # Green Hills C++ Compiler
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      sunos4*)
-	case $cc_basename in
-	  CC*)
-	    # Sun C++ 4.x
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	    ;;
-	  lcc*)
-	    # Lucid
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
-	case $cc_basename in
-	  CC*)
-	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	    ;;
-	esac
-	;;
-      tandem*)
-	case $cc_basename in
-	  NCC*)
-	    # NonStop-UX NCC 3.20
-	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
-      vxworks*)
-	;;
-      *)
-	_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
-	;;
-    esac
-  fi
-],
-[
-  if test "$GCC" = yes; then
-    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-    _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
-
-    case $host_os in
-      aix*)
-      # All AIX code is PIC.
-      if test "$host_cpu" = ia64; then
-	# AIX 5 now supports IA64 processor
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      fi
-      ;;
-
-    amigaos*)
-      case $host_cpu in
-      powerpc)
-            # see comment about AmigaOS4 .so support
-            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-        ;;
-      m68k)
-            # FIXME: we need at least 68020 code to build shared libraries, but
-            # adding the `-m68020' flag to GCC prevents building anything better,
-            # like `-m68040'.
-            _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
-        ;;
-      esac
-      ;;
-
-    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
-      # PIC is the default for these OSes.
-      ;;
-
-    mingw* | cygwin* | pw32* | os2* | cegcc*)
-      # This hack is so that the source file can tell whether it is being
-      # built for inclusion in a dll (and should export symbols for example).
-      # Although the cygwin gcc ignores -fPIC, still need this for old-style
-      # (--disable-auto-import) libraries
-      m4_if([$1], [GCJ], [],
-	[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
-      ;;
-
-    darwin* | rhapsody*)
-      # PIC is the default on this platform
-      # Common symbols not allowed in MH_DYLIB files
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
-      ;;
-
-    hpux*)
-      # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
-      # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
-      # sets the default TLS model and affects inlining.
-      case $host_cpu in
-      hppa*64*)
-	# +Z the default
-	;;
-      *)
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-	;;
-      esac
-      ;;
-
-    interix[[3-9]]*)
-      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
-      # Instead, we relocate shared libraries at runtime.
-      ;;
-
-    msdosdjgpp*)
-      # Just because we use GCC doesn't mean we suddenly get shared libraries
-      # on systems that don't support them.
-      _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
-      enable_shared=no
-      ;;
-
-    *nto* | *qnx*)
-      # QNX uses GNU C++, but need to define -shared option too, otherwise
-      # it will coredump.
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
-      ;;
-
-    sysv4*MP*)
-      if test -d /usr/nec; then
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
-      fi
-      ;;
-
-    *)
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-      ;;
-    esac
-  else
-    # PORTME Check for flag to pass linker flags through the system compiler.
-    case $host_os in
-    aix*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-      if test "$host_cpu" = ia64; then
-	# AIX 5 now supports IA64 processor
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      else
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
-      fi
-      ;;
-
-    mingw* | cygwin* | pw32* | os2* | cegcc*)
-      # This hack is so that the source file can tell whether it is being
-      # built for inclusion in a dll (and should export symbols for example).
-      m4_if([$1], [GCJ], [],
-	[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
-      ;;
-
-    hpux9* | hpux10* | hpux11*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
-      # not for PA HP-UX.
-      case $host_cpu in
-      hppa*64*|ia64*)
-	# +Z the default
-	;;
-      *)
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
-	;;
-      esac
-      # Is there a better lt_prog_compiler_static that works with the bundled CC?
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
-      ;;
-
-    irix5* | irix6* | nonstopux*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-      # PIC (with -KPIC) is the default.
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
-      ;;
-
-    linux* | k*bsd*-gnu)
-      case $cc_basename in
-      # old Intel for x86_64 which still supported -KPIC.
-      ecc*)
-	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
-        ;;
-      # icc used to be incompatible with GCC.
-      # ICC 10 doesn't accept -KPIC any more.
-      icc* | ifort*)
-	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
-        ;;
-      # Lahey Fortran 8.1.
-      lf95*)
-	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
-	;;
-      pgcc* | pgf77* | pgf90* | pgf95*)
-        # Portland Group compilers (*not* the Pentium gcc compiler,
-	# which looks to be a dead project)
-	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-        ;;
-      ccc*)
-        _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-        # All Alpha code is PIC.
-        _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
-        ;;
-      xl*)
-	# IBM XL C 8.0/Fortran 10.1 on PPC
-	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
-	;;
-      *)
-	case `$CC -V 2>&1 | sed 5q` in
-	*Sun\ C*)
-	  # Sun C 5.9
-	  _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	  _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	  ;;
-	*Sun\ F*)
-	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
-	  _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	  _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
-	  ;;
-	esac
-	;;
-      esac
-      ;;
-
-    newsos6)
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      ;;
-
-    *nto* | *qnx*)
-      # QNX uses GNU C++, but need to define -shared option too, otherwise
-      # it will coredump.
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
-      ;;
-
-    osf3* | osf4* | osf5*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-      # All OSF/1 code is PIC.
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
-      ;;
-
-    rdos*)
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
-      ;;
-
-    solaris*)
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      case $cc_basename in
-      f77* | f90* | f95*)
-	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
-      *)
-	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
-      esac
-      ;;
-
-    sunos4*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      ;;
-
-    sysv4 | sysv4.2uw2* | sysv4.3*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      ;;
-
-    sysv4*MP*)
-      if test -d /usr/nec ;then
-	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
-	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      fi
-      ;;
-
-    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      ;;
-
-    unicos*)
-      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-      _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
-      ;;
-
-    uts4*)
-      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
-      _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-      ;;
-
-    *)
-      _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
-      ;;
-    esac
-  fi
-])
-case $host_os in
-  # For platforms which do not support PIC, -DPIC is meaningless:
-  *djgpp*)
-    _LT_TAGVAR(lt_prog_compiler_pic, $1)=
-    ;;
-  *)
-    _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t at m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
-    ;;
-esac
-AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
-_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
-	[How to pass a linker flag through the compiler])
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
-  _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
-    [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
-    [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t at m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
-    [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
-     "" | " "*) ;;
-     *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
-     esac],
-    [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
-     _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
-fi
-_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
-	[Additional compiler flags for building library objects])
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
-_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
-  _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
-  $lt_tmp_static_flag,
-  [],
-  [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
-_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
-	[Compiler flag to prevent dynamic linking])
-])# _LT_COMPILER_PIC
-
-
-# _LT_LINKER_SHLIBS([TAGNAME])
-# ----------------------------
-# See if the linker supports building shared libraries.
-m4_defun([_LT_LINKER_SHLIBS],
-[AC_REQUIRE([LT_PATH_LD])dnl
-AC_REQUIRE([LT_PATH_NM])dnl
-m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-m4_require([_LT_DECL_EGREP])dnl
-m4_require([_LT_DECL_SED])dnl
-m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
-m4_require([_LT_TAG_COMPILER])dnl
-AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
-m4_if([$1], [CXX], [
-  _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
-  case $host_os in
-  aix[[4-9]]*)
-    # If we're using GNU nm, then we don't want the "-C" option.
-    # -C means demangle to AIX nm, but means don't demangle with GNU nm
-    if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
-      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
-    else
-      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
-    fi
-    ;;
-  pw32*)
-    _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
-  ;;
-  cygwin* | mingw* | cegcc*)
-    _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
-  ;;
-  *)
-    _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
-  ;;
-  esac
-  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
-], [
-  runpath_var=
-  _LT_TAGVAR(allow_undefined_flag, $1)=
-  _LT_TAGVAR(always_export_symbols, $1)=no
-  _LT_TAGVAR(archive_cmds, $1)=
-  _LT_TAGVAR(archive_expsym_cmds, $1)=
-  _LT_TAGVAR(compiler_needs_object, $1)=no
-  _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
-  _LT_TAGVAR(export_dynamic_flag_spec, $1)=
-  _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
-  _LT_TAGVAR(hardcode_automatic, $1)=no
-  _LT_TAGVAR(hardcode_direct, $1)=no
-  _LT_TAGVAR(hardcode_direct_absolute, $1)=no
-  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-  _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
-  _LT_TAGVAR(hardcode_libdir_separator, $1)=
-  _LT_TAGVAR(hardcode_minus_L, $1)=no
-  _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
-  _LT_TAGVAR(inherit_rpath, $1)=no
-  _LT_TAGVAR(link_all_deplibs, $1)=unknown
-  _LT_TAGVAR(module_cmds, $1)=
-  _LT_TAGVAR(module_expsym_cmds, $1)=
-  _LT_TAGVAR(old_archive_from_new_cmds, $1)=
-  _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
-  _LT_TAGVAR(thread_safe_flag_spec, $1)=
-  _LT_TAGVAR(whole_archive_flag_spec, $1)=
-  # include_expsyms should be a list of space-separated symbols to be *always*
-  # included in the symbol list
-  _LT_TAGVAR(include_expsyms, $1)=
-  # exclude_expsyms can be an extended regexp of symbols to exclude
-  # it will be wrapped by ` (' and `)$', so one must not match beginning or
-  # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
-  # as well as any symbol that contains `d'.
-  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
-  # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
-  # platforms (ab)use it in PIC code, but their linkers get confused if
-  # the symbol is explicitly referenced.  Since portable code cannot
-  # rely on this symbol name, it's probably fine to never include it in
-  # preloaded symbol tables.
-  # Exclude shared library initialization/finalization symbols.
-dnl Note also adjust exclude_expsyms for C++ above.
-  extract_expsyms_cmds=
-
-  case $host_os in
-  cygwin* | mingw* | pw32* | cegcc*)
-    # FIXME: the MSVC++ port hasn't been tested in a loooong time
-    # When not using gcc, we currently assume that we are using
-    # Microsoft Visual C++.
-    if test "$GCC" != yes; then
-      with_gnu_ld=no
-    fi
-    ;;
-  interix*)
-    # we just hope/assume this is gcc and not c89 (= MSVC++)
-    with_gnu_ld=yes
-    ;;
-  openbsd*)
-    with_gnu_ld=no
-    ;;
-  esac
-
-  _LT_TAGVAR(ld_shlibs, $1)=yes
-  if test "$with_gnu_ld" = yes; then
-    # If archive_cmds runs LD, not CC, wlarc should be empty
-    wlarc='${wl}'
-
-    # Set some defaults for GNU ld with shared library support. These
-    # are reset later if shared libraries are not supported. Putting them
-    # here allows them to be overridden if necessary.
-    runpath_var=LD_RUN_PATH
-    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
-    # ancient GNU ld didn't support --whole-archive et. al.
-    if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
-      _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
-    else
-      _LT_TAGVAR(whole_archive_flag_spec, $1)=
-    fi
-    supports_anon_versioning=no
-    case `$LD -v 2>&1` in
-      *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
-      *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
-      *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
-      *\ 2.11.*) ;; # other 2.11 versions
-      *) supports_anon_versioning=yes ;;
-    esac
-
-    # See if GNU ld supports shared libraries.
-    case $host_os in
-    aix[[3-9]]*)
-      # On AIX/PPC, the GNU linker is very broken
-      if test "$host_cpu" != ia64; then
-	_LT_TAGVAR(ld_shlibs, $1)=no
-	cat <<_LT_EOF 1>&2
-
-*** Warning: the GNU linker, at least up to release 2.9.1, is reported
-*** to be unable to reliably create shared libraries on AIX.
-*** Therefore, libtool is disabling shared libraries support.  If you
-*** really care for shared libraries, you may want to modify your PATH
-*** so that a non-GNU linker is found, and then restart.
-
-_LT_EOF
-      fi
-      ;;
-
-    amigaos*)
-      case $host_cpu in
-      powerpc)
-            # see comment about AmigaOS4 .so support
-            _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-            _LT_TAGVAR(archive_expsym_cmds, $1)=''
-        ;;
-      m68k)
-            _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
-            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-            _LT_TAGVAR(hardcode_minus_L, $1)=yes
-        ;;
-      esac
-      ;;
-
-    beos*)
-      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-	# Joseph Beckenbach <jrb3 at best.com> says some releases of gcc
-	# support --undefined.  This deserves some investigation.  FIXME
-	_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-      else
-	_LT_TAGVAR(ld_shlibs, $1)=no
-      fi
-      ;;
-
-    cygwin* | mingw* | pw32* | cegcc*)
-      # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
-      # as there is no search path for DLLs.
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-      _LT_TAGVAR(always_export_symbols, $1)=no
-      _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
-      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
-
-      if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
-        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-	# If the export-symbols file already is a .def file (1st line
-	# is EXPORTS), use it as is; otherwise, prepend...
-	_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
-	  cp $export_symbols $output_objdir/$soname.def;
-	else
-	  echo EXPORTS > $output_objdir/$soname.def;
-	  cat $export_symbols >> $output_objdir/$soname.def;
-	fi~
-	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-      else
-	_LT_TAGVAR(ld_shlibs, $1)=no
-      fi
-      ;;
-
-    interix[[3-9]]*)
-      _LT_TAGVAR(hardcode_direct, $1)=no
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
-      # Instead, shared libraries are loaded at an image base (0x10000000 by
-      # default) and relocated if they conflict, which is a slow very memory
-      # consuming and fragmenting process.  To avoid this, we pick a random,
-      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
-      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
-      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
-      _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
-      ;;
-
-    gnu* | linux* | tpf* | k*bsd*-gnu)
-      tmp_diet=no
-      if test "$host_os" = linux-dietlibc; then
-	case $cc_basename in
-	  diet\ *) tmp_diet=yes;;	# linux-dietlibc with static linking (!diet-dyn)
-	esac
-      fi
-      if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
-	 && test "$tmp_diet" = no
-      then
-	tmp_addflag=
-	tmp_sharedflag='-shared'
-	case $cc_basename,$host_cpu in
-        pgcc*)				# Portland Group C compiler
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
-	  tmp_addflag=' $pic_flag'
-	  ;;
-	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
-	  tmp_addflag=' $pic_flag -Mnomain' ;;
-	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
-	  tmp_addflag=' -i_dynamic' ;;
-	efc*,ia64* | ifort*,ia64*)	# Intel Fortran compiler on ia64
-	  tmp_addflag=' -i_dynamic -nofor_main' ;;
-	ifc* | ifort*)			# Intel Fortran compiler
-	  tmp_addflag=' -nofor_main' ;;
-	lf95*)				# Lahey Fortran 8.1
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)=
-	  tmp_sharedflag='--shared' ;;
-	xl[[cC]]*)			# IBM XL C 8.0 on PPC (deal with xlf below)
-	  tmp_sharedflag='-qmkshrobj'
-	  tmp_addflag= ;;
-	esac
-	case `$CC -V 2>&1 | sed 5q` in
-	*Sun\ C*)			# Sun C 5.9
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
-	  _LT_TAGVAR(compiler_needs_object, $1)=yes
-	  tmp_sharedflag='-G' ;;
-	*Sun\ F*)			# Sun Fortran 8.3
-	  tmp_sharedflag='-G' ;;
-	esac
-	_LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-
-        if test "x$supports_anon_versioning" = xyes; then
-          _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
-	    cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
-	    echo "local: *; };" >> $output_objdir/$libname.ver~
-	    $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
-        fi
-
-	case $cc_basename in
-	xlf*)
-	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
-	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-	  _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
-	  _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
-	  if test "x$supports_anon_versioning" = xyes; then
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
-	      cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
-	      echo "local: *; };" >> $output_objdir/$libname.ver~
-	      $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
-	  fi
-	  ;;
-	esac
-      else
-        _LT_TAGVAR(ld_shlibs, $1)=no
-      fi
-      ;;
-
-    netbsd*)
-      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
-	_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
-	wlarc=
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-      fi
-      ;;
-
-    solaris*)
-      if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
-	_LT_TAGVAR(ld_shlibs, $1)=no
-	cat <<_LT_EOF 1>&2
-
-*** Warning: The releases 2.8.* of the GNU linker cannot reliably
-*** create shared libraries on Solaris systems.  Therefore, libtool
-*** is disabling shared libraries support.  We urge you to upgrade GNU
-*** binutils to release 2.9.1 or newer.  Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
-      elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-      else
-	_LT_TAGVAR(ld_shlibs, $1)=no
-      fi
-      ;;
-
-    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
-      case `$LD -v 2>&1` in
-        *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
-	_LT_TAGVAR(ld_shlibs, $1)=no
-	cat <<_LT_EOF 1>&2
-
-*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
-*** reliably create shared libraries on SCO systems.  Therefore, libtool
-*** is disabling shared libraries support.  We urge you to upgrade GNU
-*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
-	;;
-	*)
-	  # For security reasons, it is highly recommended that you always
-	  # use absolute paths for naming shared libraries, and exclude the
-	  # DT_RUNPATH tag from executables and libraries.  But doing so
-	  # requires that you compile everything twice, which is a pain.
-	  if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-	  else
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	  fi
-	;;
-      esac
-      ;;
-
-    sunos4*)
-      _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-      wlarc=
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    *)
-      if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-      else
-	_LT_TAGVAR(ld_shlibs, $1)=no
-      fi
-      ;;
-    esac
-
-    if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
-      runpath_var=
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-      _LT_TAGVAR(export_dynamic_flag_spec, $1)=
-      _LT_TAGVAR(whole_archive_flag_spec, $1)=
-    fi
-  else
-    # PORTME fill in a description of your system's linker (not GNU ld)
-    case $host_os in
-    aix3*)
-      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-      _LT_TAGVAR(always_export_symbols, $1)=yes
-      _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
-      # Note: this linker hardcodes the directories in LIBPATH if there
-      # are no directories specified by -L.
-      _LT_TAGVAR(hardcode_minus_L, $1)=yes
-      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
-	# Neither direct hardcoding nor static linking is supported with a
-	# broken collect2.
-	_LT_TAGVAR(hardcode_direct, $1)=unsupported
-      fi
-      ;;
-
-    aix[[4-9]]*)
-      if test "$host_cpu" = ia64; then
-	# On IA64, the linker does run time linking by default, so we don't
-	# have to do anything special.
-	aix_use_runtimelinking=no
-	exp_sym_flag='-Bexport'
-	no_entry_flag=""
-      else
-	# If we're using GNU nm, then we don't want the "-C" option.
-	# -C means demangle to AIX nm, but means don't demangle with GNU nm
-	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
-	  _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
-	else
-	  _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
-	fi
-	aix_use_runtimelinking=no
-
-	# Test if we are trying to use run time linking or normal
-	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
-	# need to do runtime linking.
-	case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
-	  for ld_flag in $LDFLAGS; do
-	  if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
-	    aix_use_runtimelinking=yes
-	    break
-	  fi
-	  done
-	  ;;
-	esac
-
-	exp_sym_flag='-bexport'
-	no_entry_flag='-bnoentry'
-      fi
-
-      # When large executables or shared objects are built, AIX ld can
-      # have problems creating the table of contents.  If linking a library
-      # or program results in "error TOC overflow" add -mminimal-toc to
-      # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
-      # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
-      _LT_TAGVAR(archive_cmds, $1)=''
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
-      _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
-      _LT_TAGVAR(link_all_deplibs, $1)=yes
-      _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
-
-      if test "$GCC" = yes; then
-	case $host_os in aix4.[[012]]|aix4.[[012]].*)
-	# We only want to do this on AIX 4.2 and lower, the check
-	# below for broken collect2 doesn't work under 4.3+
-	  collect2name=`${CC} -print-prog-name=collect2`
-	  if test -f "$collect2name" &&
-	   strings "$collect2name" | $GREP resolve_lib_name >/dev/null
-	  then
-	  # We have reworked collect2
-	  :
-	  else
-	  # We have old collect2
-	  _LT_TAGVAR(hardcode_direct, $1)=unsupported
-	  # It fails to find uninstalled libraries when the uninstalled
-	  # path is not listed in the libpath.  Setting hardcode_minus_L
-	  # to unsupported forces relinking
-	  _LT_TAGVAR(hardcode_minus_L, $1)=yes
-	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-	  _LT_TAGVAR(hardcode_libdir_separator, $1)=
-	  fi
-	  ;;
-	esac
-	shared_flag='-shared'
-	if test "$aix_use_runtimelinking" = yes; then
-	  shared_flag="$shared_flag "'${wl}-G'
-	fi
-      else
-	# not using gcc
-	if test "$host_cpu" = ia64; then
-	# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
-	# chokes on -Wl,-G. The following line is correct:
-	  shared_flag='-G'
-	else
-	  if test "$aix_use_runtimelinking" = yes; then
-	    shared_flag='${wl}-G'
-	  else
-	    shared_flag='${wl}-bM:SRE'
-	  fi
-	fi
-      fi
-
-      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
-      # It seems that -bexpall does not export symbols beginning with
-      # underscore (_), so it is better to generate a list of symbols to export.
-      _LT_TAGVAR(always_export_symbols, $1)=yes
-      if test "$aix_use_runtimelinking" = yes; then
-	# Warning - without using the other runtime loading flags (-brtl),
-	# -berok will link without error, but may produce a broken library.
-	_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
-        # Determine the default libpath from the value encoded in an
-        # empty executable.
-        _LT_SYS_MODULE_PATH_AIX
-        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
-        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-      else
-	if test "$host_cpu" = ia64; then
-	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
-	  _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
-	  _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
-	else
-	 # Determine the default libpath from the value encoded in an
-	 # empty executable.
-	 _LT_SYS_MODULE_PATH_AIX
-	 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
-	  # Warning - without using the other run time loading flags,
-	  # -berok will link without error, but may produce a broken library.
-	  _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
-	  _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	  # Exported symbols can be pulled into shared objects from archives
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
-	  _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
-	  # This is similar to how AIX traditionally builds its shared libraries.
-	  _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
-	fi
-      fi
-      ;;
-
-    amigaos*)
-      case $host_cpu in
-      powerpc)
-            # see comment about AmigaOS4 .so support
-            _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-            _LT_TAGVAR(archive_expsym_cmds, $1)=''
-        ;;
-      m68k)
-            _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
-            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-            _LT_TAGVAR(hardcode_minus_L, $1)=yes
-        ;;
-      esac
-      ;;
-
-    bsdi[[45]]*)
-      _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
-      ;;
-
-    cygwin* | mingw* | pw32* | cegcc*)
-      # When not using gcc, we currently assume that we are using
-      # Microsoft Visual C++.
-      # hardcode_libdir_flag_spec is actually meaningless, as there is
-      # no search path for DLLs.
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
-      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-      # Tell ltmain to make .lib files, not .a files.
-      libext=lib
-      # Tell ltmain to make .dll files, not .so files.
-      shrext_cmds=".dll"
-      # FIXME: Setting linknames here is a bad hack.
-      _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
-      # The linker will automatically build a .lib file if we build a DLL.
-      _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
-      # FIXME: Should let the user specify the lib program.
-      _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
-      _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
-      _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
-      ;;
-
-    darwin* | rhapsody*)
-      _LT_DARWIN_LINKER_FEATURES($1)
-      ;;
-
-    dgux*)
-      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    freebsd1*)
-      _LT_TAGVAR(ld_shlibs, $1)=no
-      ;;
-
-    # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
-    # support.  Future versions do this automatically, but an explicit c++rt0.o
-    # does not break anything, and helps significantly (at the cost of a little
-    # extra space).
-    freebsd2.2*)
-      _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    # Unfortunately, older versions of FreeBSD 2 do not have this feature.
-    freebsd2*)
-      _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_minus_L, $1)=yes
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
-    freebsd* | dragonfly*)
-      _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    hpux9*)
-      if test "$GCC" = yes; then
-	_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
-      fi
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-
-      # hardcode_minus_L: Not really in the search PATH,
-      # but as the default location of the library.
-      _LT_TAGVAR(hardcode_minus_L, $1)=yes
-      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-      ;;
-
-    hpux10*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
-      fi
-      if test "$with_gnu_ld" = no; then
-	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
-	_LT_TAGVAR(hardcode_libdir_separator, $1)=:
-	_LT_TAGVAR(hardcode_direct, $1)=yes
-	_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
-	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-	# hardcode_minus_L: Not really in the search PATH,
-	# but as the default location of the library.
-	_LT_TAGVAR(hardcode_minus_L, $1)=yes
-      fi
-      ;;
-
-    hpux11*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
-	case $host_cpu in
-	hppa*64*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	ia64*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	esac
-      else
-	case $host_cpu in
-	hppa*64*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	ia64*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	esac
-      fi
-      if test "$with_gnu_ld" = no; then
-	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	_LT_TAGVAR(hardcode_libdir_separator, $1)=:
-
-	case $host_cpu in
-	hppa*64*|ia64*)
-	  _LT_TAGVAR(hardcode_direct, $1)=no
-	  _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	  ;;
-	*)
-	  _LT_TAGVAR(hardcode_direct, $1)=yes
-	  _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
-	  _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-
-	  # hardcode_minus_L: Not really in the search PATH,
-	  # but as the default location of the library.
-	  _LT_TAGVAR(hardcode_minus_L, $1)=yes
-	  ;;
-	esac
-      fi
-      ;;
-
-    irix5* | irix6* | nonstopux*)
-      if test "$GCC" = yes; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
-	# Try to use the -exported_symbol ld option, if it does not
-	# work, assume that -exports_file does not work either and
-	# implicitly export all symbols.
-        save_LDFLAGS="$LDFLAGS"
-        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
-        AC_LINK_IFELSE(int foo(void) {},
-          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-        )
-        LDFLAGS="$save_LDFLAGS"
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-      fi
-      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-      _LT_TAGVAR(inherit_rpath, $1)=yes
-      _LT_TAGVAR(link_all_deplibs, $1)=yes
-      ;;
-
-    netbsd*)
-      if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
-	_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
-      fi
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    newsos6)
-      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    *nto* | *qnx*)
-      ;;
-
-    openbsd*)
-      if test -f /usr/libexec/ld.so; then
-	_LT_TAGVAR(hardcode_direct, $1)=yes
-	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
-	if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	  _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
-	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	  _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-	else
-	  case $host_os in
-	   openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
-	     _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-	     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-	     ;;
-	   *)
-	     _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	     _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	     ;;
-	  esac
-	fi
-      else
-	_LT_TAGVAR(ld_shlibs, $1)=no
-      fi
-      ;;
-
-    os2*)
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-      _LT_TAGVAR(hardcode_minus_L, $1)=yes
-      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-      _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
-      _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
-      ;;
-
-    osf3*)
-      if test "$GCC" = yes; then
-	_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
-      else
-	_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-      fi
-      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-      ;;
-
-    osf4* | osf5*)	# as osf3* with the addition of -msym flag
-      if test "$GCC" = yes; then
-	_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
-	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-      else
-	_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
-	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
-
-	# Both c and cxx compiler support -rpath directly
-	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
-      fi
-      _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
-      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-      ;;
-
-    solaris*)
-      _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
-      if test "$GCC" = yes; then
-	wlarc='${wl}'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	  $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
-      else
-	case `$CC -V 2>&1` in
-	*"Compilers 5.0"*)
-	  wlarc=''
-	  _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
-	  _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	  $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
-	  ;;
-	*)
-	  wlarc='${wl}'
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
-	  _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	  $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
-	  ;;
-	esac
-      fi
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      case $host_os in
-      solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
-      *)
-	# The compiler driver will combine and reorder linker options,
-	# but understands `-z linker_flag'.  GCC discards it without `$wl',
-	# but is careful enough not to reorder.
-	# Supported since Solaris 2.6 (maybe 2.5.1?)
-	if test "$GCC" = yes; then
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
-	else
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
-	fi
-	;;
-      esac
-      _LT_TAGVAR(link_all_deplibs, $1)=yes
-      ;;
-
-    sunos4*)
-      if test "x$host_vendor" = xsequent; then
-	# Use $CC to link under sequent, because it throws in some extra .o
-	# files that make .init and .fini sections work.
-	_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
-      fi
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-      _LT_TAGVAR(hardcode_direct, $1)=yes
-      _LT_TAGVAR(hardcode_minus_L, $1)=yes
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    sysv4)
-      case $host_vendor in
-	sni)
-	  _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-	  _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
-	;;
-	siemens)
-	  ## LD is ld it makes a PLAMLIB
-	  ## CC just makes a GrossModule.
-	  _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
-	  _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
-	  _LT_TAGVAR(hardcode_direct, $1)=no
-        ;;
-	motorola)
-	  _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-	  _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
-	;;
-      esac
-      runpath_var='LD_RUN_PATH'
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    sysv4.3*)
-      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
-      ;;
-
-    sysv4*MP*)
-      if test -d /usr/nec; then
-	_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	runpath_var=LD_RUN_PATH
-	hardcode_runpath_var=yes
-	_LT_TAGVAR(ld_shlibs, $1)=yes
-      fi
-      ;;
-
-    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
-      _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
-      _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      runpath_var='LD_RUN_PATH'
-
-      if test "$GCC" = yes; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-      fi
-      ;;
-
-    sysv5* | sco3.2v5* | sco5v6*)
-      # Note: We can NOT use -z defs as we might desire, because we do not
-      # link with -lc, and that would cause any symbols used from libc to
-      # always be unresolved, which means just about no library would
-      # ever link correctly.  If we're not using GNU ld we use -z text
-      # though, which does catch some bad symbols but isn't as heavy-handed
-      # as -z defs.
-      _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
-      _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
-      _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
-      _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
-      _LT_TAGVAR(link_all_deplibs, $1)=yes
-      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
-      runpath_var='LD_RUN_PATH'
-
-      if test "$GCC" = yes; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-      else
-	_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-      fi
-      ;;
-
-    uts4*)
-      _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      ;;
-
-    *)
-      _LT_TAGVAR(ld_shlibs, $1)=no
-      ;;
-    esac
-
-    if test x$host_vendor = xsni; then
-      case $host in
-      sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
-	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
-	;;
-      esac
-    fi
-  fi
-])
-AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
-test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
-
-_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
-
-_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
-_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
-_LT_DECL([], [extract_expsyms_cmds], [2],
-    [The commands to extract the exported symbol list from a shared archive])
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
-x|xyes)
-  # Assume -lc should be added
-  _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
-
-  if test "$enable_shared" = yes && test "$GCC" = yes; then
-    case $_LT_TAGVAR(archive_cmds, $1) in
-    *'~'*)
-      # FIXME: we may have to deal with multi-command sequences.
-      ;;
-    '$CC '*)
-      # Test whether the compiler implicitly links with -lc since on some
-      # systems, -lgcc has to come before -lc. If gcc already passes -lc
-      # to ld, don't add -lc before -lgcc.
-      AC_MSG_CHECKING([whether -lc should be explicitly linked in])
-      $RM conftest*
-      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
-      if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
-        soname=conftest
-        lib=conftest
-        libobjs=conftest.$ac_objext
-        deplibs=
-        wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
-	pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
-        compiler_flags=-v
-        linker_flags=-v
-        verstring=
-        output_objdir=.
-        libname=conftest
-        lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
-        _LT_TAGVAR(allow_undefined_flag, $1)=
-        if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
-        then
-	  _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-        else
-	  _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
-        fi
-        _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
-      else
-        cat conftest.err 1>&5
-      fi
-      $RM conftest*
-      AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)])
-      ;;
-    esac
-  fi
-  ;;
-esac
-
-_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
-    [Whether or not to add -lc for building shared libraries])
-_LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
-    [enable_shared_with_static_runtimes], [0],
-    [Whether or not to disallow shared libs when runtime libs are static])
-_LT_TAGDECL([], [export_dynamic_flag_spec], [1],
-    [Compiler flag to allow reflexive dlopens])
-_LT_TAGDECL([], [whole_archive_flag_spec], [1],
-    [Compiler flag to generate shared objects directly from archives])
-_LT_TAGDECL([], [compiler_needs_object], [1],
-    [Whether the compiler copes with passing no objects directly])
-_LT_TAGDECL([], [old_archive_from_new_cmds], [2],
-    [Create an old-style archive from a shared archive])
-_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
-    [Create a temporary old-style archive to link instead of a shared archive])
-_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
-_LT_TAGDECL([], [archive_expsym_cmds], [2])
-_LT_TAGDECL([], [module_cmds], [2],
-    [Commands used to build a loadable module if different from building
-    a shared archive.])
-_LT_TAGDECL([], [module_expsym_cmds], [2])
-_LT_TAGDECL([], [with_gnu_ld], [1],
-    [Whether we are building with GNU ld or not])
-_LT_TAGDECL([], [allow_undefined_flag], [1],
-    [Flag that allows shared libraries with undefined symbols to be built])
-_LT_TAGDECL([], [no_undefined_flag], [1],
-    [Flag that enforces no undefined symbols])
-_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
-    [Flag to hardcode $libdir into a binary during linking.
-    This must work even if $libdir does not exist])
-_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1],
-    [[If ld is used when linking, flag to hardcode $libdir into a binary
-    during linking.  This must work even if $libdir does not exist]])
-_LT_TAGDECL([], [hardcode_libdir_separator], [1],
-    [Whether we need a single "-rpath" flag with a separated argument])
-_LT_TAGDECL([], [hardcode_direct], [0],
-    [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
-    DIR into the resulting binary])
-_LT_TAGDECL([], [hardcode_direct_absolute], [0],
-    [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
-    DIR into the resulting binary and the resulting library dependency is
-    "absolute", i.e impossible to change by setting ${shlibpath_var} if the
-    library is relocated])
-_LT_TAGDECL([], [hardcode_minus_L], [0],
-    [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-    into the resulting binary])
-_LT_TAGDECL([], [hardcode_shlibpath_var], [0],
-    [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-    into the resulting binary])
-_LT_TAGDECL([], [hardcode_automatic], [0],
-    [Set to "yes" if building a shared library automatically hardcodes DIR
-    into the library and all subsequent libraries and executables linked
-    against it])
-_LT_TAGDECL([], [inherit_rpath], [0],
-    [Set to yes if linker adds runtime paths of dependent libraries
-    to runtime path list])
-_LT_TAGDECL([], [link_all_deplibs], [0],
-    [Whether libtool must link a program against all its dependency libraries])
-_LT_TAGDECL([], [fix_srcfile_path], [1],
-    [Fix the shell variable $srcfile for the compiler])
-_LT_TAGDECL([], [always_export_symbols], [0],
-    [Set to "yes" if exported symbols are required])
-_LT_TAGDECL([], [export_symbols_cmds], [2],
-    [The commands to list exported symbols])
-_LT_TAGDECL([], [exclude_expsyms], [1],
-    [Symbols that should not be listed in the preloaded symbols])
-_LT_TAGDECL([], [include_expsyms], [1],
-    [Symbols that must always be exported])
-_LT_TAGDECL([], [prelink_cmds], [2],
-    [Commands necessary for linking programs (against libraries) with templates])
-_LT_TAGDECL([], [file_list_spec], [1],
-    [Specify filename containing input files])
-dnl FIXME: Not yet implemented
-dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
-dnl    [Compiler flag to generate thread safe objects])
-])# _LT_LINKER_SHLIBS
-
-
-# _LT_LANG_C_CONFIG([TAG])
-# ------------------------
-# Ensure that the configuration variables for a C compiler are suitably
-# defined.  These variables are subsequently used by _LT_CONFIG to write
-# the compiler configuration to `libtool'.
-m4_defun([_LT_LANG_C_CONFIG],
-[m4_require([_LT_DECL_EGREP])dnl
-lt_save_CC="$CC"
-AC_LANG_PUSH(C)
-
-# Source file extension for C test sources.
-ac_ext=c
-
-# Object file extension for compiled C test sources.
-objext=o
-_LT_TAGVAR(objext, $1)=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}'
-
-_LT_TAG_COMPILER
-# Save the default compiler, since it gets overwritten when the other
-# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
-compiler_DEFAULT=$CC
-
-# save warnings/boilerplate of simple test code
-_LT_COMPILER_BOILERPLATE
-_LT_LINKER_BOILERPLATE
-
-if test -n "$compiler"; then
-  _LT_COMPILER_NO_RTTI($1)
-  _LT_COMPILER_PIC($1)
-  _LT_COMPILER_C_O($1)
-  _LT_COMPILER_FILE_LOCKS($1)
-  _LT_LINKER_SHLIBS($1)
-  _LT_SYS_DYNAMIC_LINKER($1)
-  _LT_LINKER_HARDCODE_LIBPATH($1)
-  LT_SYS_DLOPEN_SELF
-  _LT_CMD_STRIPLIB
-
-  # Report which library types will actually be built
-  AC_MSG_CHECKING([if libtool supports shared libraries])
-  AC_MSG_RESULT([$can_build_shared])
-
-  AC_MSG_CHECKING([whether to build shared libraries])
-  test "$can_build_shared" = "no" && enable_shared=no
-
-  # On AIX, shared libraries and static libraries use the same namespace, and
-  # are all built from PIC.
-  case $host_os in
-  aix3*)
-    test "$enable_shared" = yes && enable_static=no
-    if test -n "$RANLIB"; then
-      archive_cmds="$archive_cmds~\$RANLIB \$lib"
-      postinstall_cmds='$RANLIB $lib'
-    fi
-    ;;
-
-  aix[[4-9]]*)
-    if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
-      test "$enable_shared" = yes && enable_static=no
-    fi
-    ;;
-  esac
-  AC_MSG_RESULT([$enable_shared])
-
-  AC_MSG_CHECKING([whether to build static libraries])
-  # Make sure either enable_shared or enable_static is yes.
-  test "$enable_shared" = yes || enable_static=yes
-  AC_MSG_RESULT([$enable_static])
-
-  _LT_CONFIG($1)
-fi
-AC_LANG_POP
-CC="$lt_save_CC"
-])# _LT_LANG_C_CONFIG
-
-
-# _LT_PROG_CXX
-# ------------
-# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++
-# compiler, we have our own version here.
-m4_defun([_LT_PROG_CXX],
-[
-pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes])
-AC_PROG_CXX
-if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
-    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
-    (test "X$CXX" != "Xg++"))) ; then
-  AC_PROG_CXXCPP
-else
-  _lt_caught_CXX_error=yes
-fi
-popdef([AC_MSG_ERROR])
-])# _LT_PROG_CXX
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([_LT_PROG_CXX], [])
-
-
-# _LT_LANG_CXX_CONFIG([TAG])
-# --------------------------
-# Ensure that the configuration variables for a C++ compiler are suitably
-# defined.  These variables are subsequently used by _LT_CONFIG to write
-# the compiler configuration to `libtool'.
-m4_defun([_LT_LANG_CXX_CONFIG],
-[AC_REQUIRE([_LT_PROG_CXX])dnl
-m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-m4_require([_LT_DECL_EGREP])dnl
-
-AC_LANG_PUSH(C++)
-_LT_TAGVAR(archive_cmds_need_lc, $1)=no
-_LT_TAGVAR(allow_undefined_flag, $1)=
-_LT_TAGVAR(always_export_symbols, $1)=no
-_LT_TAGVAR(archive_expsym_cmds, $1)=
-_LT_TAGVAR(compiler_needs_object, $1)=no
-_LT_TAGVAR(export_dynamic_flag_spec, $1)=
-_LT_TAGVAR(hardcode_direct, $1)=no
-_LT_TAGVAR(hardcode_direct_absolute, $1)=no
-_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
-_LT_TAGVAR(hardcode_libdir_separator, $1)=
-_LT_TAGVAR(hardcode_minus_L, $1)=no
-_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
-_LT_TAGVAR(hardcode_automatic, $1)=no
-_LT_TAGVAR(inherit_rpath, $1)=no
-_LT_TAGVAR(module_cmds, $1)=
-_LT_TAGVAR(module_expsym_cmds, $1)=
-_LT_TAGVAR(link_all_deplibs, $1)=unknown
-_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-_LT_TAGVAR(no_undefined_flag, $1)=
-_LT_TAGVAR(whole_archive_flag_spec, $1)=
-_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
-
-# Source file extension for C++ test sources.
-ac_ext=cpp
-
-# Object file extension for compiled C++ test sources.
-objext=o
-_LT_TAGVAR(objext, $1)=$objext
-
-# No sense in running all these tests if we already determined that
-# the CXX compiler isn't working.  Some variables (like enable_shared)
-# are currently assumed to apply to all compilers on this platform,
-# and will be corrupted by setting them based on a non-working compiler.
-if test "$_lt_caught_CXX_error" != yes; then
-  # Code to be used in simple compile tests
-  lt_simple_compile_test_code="int some_variable = 0;"
-
-  # Code to be used in simple link tests
-  lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
-
-  # ltmain only uses $CC for tagged configurations so make sure $CC is set.
-  _LT_TAG_COMPILER
-
-  # save warnings/boilerplate of simple test code
-  _LT_COMPILER_BOILERPLATE
-  _LT_LINKER_BOILERPLATE
-
-  # Allow CC to be a program name with arguments.
-  lt_save_CC=$CC
-  lt_save_LD=$LD
-  lt_save_GCC=$GCC
-  GCC=$GXX
-  lt_save_with_gnu_ld=$with_gnu_ld
-  lt_save_path_LD=$lt_cv_path_LD
-  if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
-    lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
-  else
-    $as_unset lt_cv_prog_gnu_ld
-  fi
-  if test -n "${lt_cv_path_LDCXX+set}"; then
-    lt_cv_path_LD=$lt_cv_path_LDCXX
-  else
-    $as_unset lt_cv_path_LD
-  fi
-  test -z "${LDCXX+set}" || LD=$LDCXX
-  CC=${CXX-"c++"}
-  compiler=$CC
-  _LT_TAGVAR(compiler, $1)=$CC
-  _LT_CC_BASENAME([$compiler])
-
-  if test -n "$compiler"; then
-    # We don't want -fno-exception when compiling C++ code, so set the
-    # no_builtin_flag separately
-    if test "$GXX" = yes; then
-      _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
-    else
-      _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
-    fi
-
-    if test "$GXX" = yes; then
-      # Set up default GNU C++ configuration
-
-      LT_PATH_LD
-
-      # Check if GNU C++ uses GNU ld as the underlying linker, since the
-      # archiving commands below assume that GNU ld is being used.
-      if test "$with_gnu_ld" = yes; then
-        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
-        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-
-        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-        _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
-
-        # If archive_cmds runs LD, not CC, wlarc should be empty
-        # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
-        #     investigate it a little bit more. (MM)
-        wlarc='${wl}'
-
-        # ancient GNU ld didn't support --whole-archive et. al.
-        if eval "`$CC -print-prog-name=ld` --help 2>&1" |
-	  $GREP 'no-whole-archive' > /dev/null; then
-          _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
-        else
-          _LT_TAGVAR(whole_archive_flag_spec, $1)=
-        fi
-      else
-        with_gnu_ld=no
-        wlarc=
-
-        # A generic and very simple default shared library creation
-        # command for GNU C++ for the case where it uses the native
-        # linker, instead of GNU ld.  If possible, this setting should
-        # overridden to take advantage of the native linker features on
-        # the platform it is being used on.
-        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
-      fi
-
-      # Commands to make compiler produce verbose output that lists
-      # what "hidden" libraries, object files and flags are used when
-      # linking a shared library.
-      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
-
-    else
-      GXX=no
-      with_gnu_ld=no
-      wlarc=
-    fi
-
-    # PORTME: fill in a description of your system's C++ link characteristics
-    AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
-    _LT_TAGVAR(ld_shlibs, $1)=yes
-    case $host_os in
-      aix3*)
-        # FIXME: insert proper C++ library support
-        _LT_TAGVAR(ld_shlibs, $1)=no
-        ;;
-      aix[[4-9]]*)
-        if test "$host_cpu" = ia64; then
-          # On IA64, the linker does run time linking by default, so we don't
-          # have to do anything special.
-          aix_use_runtimelinking=no
-          exp_sym_flag='-Bexport'
-          no_entry_flag=""
-        else
-          aix_use_runtimelinking=no
-
-          # Test if we are trying to use run time linking or normal
-          # AIX style linking. If -brtl is somewhere in LDFLAGS, we
-          # need to do runtime linking.
-          case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
-	    for ld_flag in $LDFLAGS; do
-	      case $ld_flag in
-	      *-brtl*)
-	        aix_use_runtimelinking=yes
-	        break
-	        ;;
-	      esac
-	    done
-	    ;;
-          esac
-
-          exp_sym_flag='-bexport'
-          no_entry_flag='-bnoentry'
-        fi
-
-        # When large executables or shared objects are built, AIX ld can
-        # have problems creating the table of contents.  If linking a library
-        # or program results in "error TOC overflow" add -mminimal-toc to
-        # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
-        # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
-        _LT_TAGVAR(archive_cmds, $1)=''
-        _LT_TAGVAR(hardcode_direct, $1)=yes
-        _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
-        _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
-        _LT_TAGVAR(link_all_deplibs, $1)=yes
-        _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
-
-        if test "$GXX" = yes; then
-          case $host_os in aix4.[[012]]|aix4.[[012]].*)
-          # We only want to do this on AIX 4.2 and lower, the check
-          # below for broken collect2 doesn't work under 4.3+
-	  collect2name=`${CC} -print-prog-name=collect2`
-	  if test -f "$collect2name" &&
-	     strings "$collect2name" | $GREP resolve_lib_name >/dev/null
-	  then
-	    # We have reworked collect2
-	    :
-	  else
-	    # We have old collect2
-	    _LT_TAGVAR(hardcode_direct, $1)=unsupported
-	    # It fails to find uninstalled libraries when the uninstalled
-	    # path is not listed in the libpath.  Setting hardcode_minus_L
-	    # to unsupported forces relinking
-	    _LT_TAGVAR(hardcode_minus_L, $1)=yes
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-	    _LT_TAGVAR(hardcode_libdir_separator, $1)=
-	  fi
-          esac
-          shared_flag='-shared'
-	  if test "$aix_use_runtimelinking" = yes; then
-	    shared_flag="$shared_flag "'${wl}-G'
-	  fi
-        else
-          # not using gcc
-          if test "$host_cpu" = ia64; then
-	  # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
-	  # chokes on -Wl,-G. The following line is correct:
-	  shared_flag='-G'
-          else
-	    if test "$aix_use_runtimelinking" = yes; then
-	      shared_flag='${wl}-G'
-	    else
-	      shared_flag='${wl}-bM:SRE'
-	    fi
-          fi
-        fi
-
-        _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
-        # It seems that -bexpall does not export symbols beginning with
-        # underscore (_), so it is better to generate a list of symbols to
-	# export.
-        _LT_TAGVAR(always_export_symbols, $1)=yes
-        if test "$aix_use_runtimelinking" = yes; then
-          # Warning - without using the other runtime loading flags (-brtl),
-          # -berok will link without error, but may produce a broken library.
-          _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
-          # Determine the default libpath from the value encoded in an empty
-          # executable.
-          _LT_SYS_MODULE_PATH_AIX
-          _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
-
-          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-        else
-          if test "$host_cpu" = ia64; then
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
-	    _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
-	    _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
-          else
-	    # Determine the default libpath from the value encoded in an
-	    # empty executable.
-	    _LT_SYS_MODULE_PATH_AIX
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
-	    # Warning - without using the other run time loading flags,
-	    # -berok will link without error, but may produce a broken library.
-	    _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
-	    _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	    # Exported symbols can be pulled into shared objects from archives
-	    _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
-	    _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
-	    # This is similar to how AIX traditionally builds its shared
-	    # libraries.
-	    _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
-          fi
-        fi
-        ;;
-
-      beos*)
-	if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	  _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-	  # Joseph Beckenbach <jrb3 at best.com> says some releases of gcc
-	  # support --undefined.  This deserves some investigation.  FIXME
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	else
-	  _LT_TAGVAR(ld_shlibs, $1)=no
-	fi
-	;;
-
-      chorus*)
-        case $cc_basename in
-          *)
-	  # FIXME: insert proper C++ library support
-	  _LT_TAGVAR(ld_shlibs, $1)=no
-	  ;;
-        esac
-        ;;
-
-      cygwin* | mingw* | pw32* | cegcc*)
-        # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
-        # as there is no search path for DLLs.
-        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-        _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-        _LT_TAGVAR(always_export_symbols, $1)=no
-        _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
-
-        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
-          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-          # If the export-symbols file already is a .def file (1st line
-          # is EXPORTS), use it as is; otherwise, prepend...
-          _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
-	    cp $export_symbols $output_objdir/$soname.def;
-          else
-	    echo EXPORTS > $output_objdir/$soname.def;
-	    cat $export_symbols >> $output_objdir/$soname.def;
-          fi~
-          $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-        else
-          _LT_TAGVAR(ld_shlibs, $1)=no
-        fi
-        ;;
-      darwin* | rhapsody*)
-        _LT_DARWIN_LINKER_FEATURES($1)
-	;;
-
-      dgux*)
-        case $cc_basename in
-          ec++*)
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-          ghcx*)
-	    # Green Hills C++ Compiler
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-          *)
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-        esac
-        ;;
-
-      freebsd[[12]]*)
-        # C++ shared libraries reported to be fairly broken before
-	# switch to ELF
-        _LT_TAGVAR(ld_shlibs, $1)=no
-        ;;
-
-      freebsd-elf*)
-        _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-        ;;
-
-      freebsd* | dragonfly*)
-        # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
-        # conventions
-        _LT_TAGVAR(ld_shlibs, $1)=yes
-        ;;
-
-      gnu*)
-        ;;
-
-      hpux9*)
-        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-        _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-        _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-        _LT_TAGVAR(hardcode_direct, $1)=yes
-        _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
-				             # but as the default
-				             # location of the library.
-
-        case $cc_basename in
-          CC*)
-            # FIXME: insert proper C++ library support
-            _LT_TAGVAR(ld_shlibs, $1)=no
-            ;;
-          aCC*)
-            _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
-            # Commands to make compiler produce verbose output that lists
-            # what "hidden" libraries, object files and flags are used when
-            # linking a shared library.
-            #
-            # There doesn't appear to be a way to prevent this compiler from
-            # explicitly linking system object files so we need to strip them
-            # from the output so that they don't get included in the library
-            # dependencies.
-            output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
-            ;;
-          *)
-            if test "$GXX" = yes; then
-              _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
-            else
-              # FIXME: insert proper C++ library support
-              _LT_TAGVAR(ld_shlibs, $1)=no
-            fi
-            ;;
-        esac
-        ;;
-
-      hpux10*|hpux11*)
-        if test $with_gnu_ld = no; then
-	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	  _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-
-          case $host_cpu in
-            hppa*64*|ia64*)
-              ;;
-            *)
-	      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-              ;;
-          esac
-        fi
-        case $host_cpu in
-          hppa*64*|ia64*)
-            _LT_TAGVAR(hardcode_direct, $1)=no
-            _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-            ;;
-          *)
-            _LT_TAGVAR(hardcode_direct, $1)=yes
-            _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
-            _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
-					         # but as the default
-					         # location of the library.
-            ;;
-        esac
-
-        case $cc_basename in
-          CC*)
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-          aCC*)
-	    case $host_cpu in
-	      hppa*64*)
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	        ;;
-	      ia64*)
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	        ;;
-	      *)
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	        ;;
-	    esac
-	    # Commands to make compiler produce verbose output that lists
-	    # what "hidden" libraries, object files and flags are used when
-	    # linking a shared library.
-	    #
-	    # There doesn't appear to be a way to prevent this compiler from
-	    # explicitly linking system object files so we need to strip them
-	    # from the output so that they don't get included in the library
-	    # dependencies.
-	    output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
-	    ;;
-          *)
-	    if test "$GXX" = yes; then
-	      if test $with_gnu_ld = no; then
-	        case $host_cpu in
-	          hppa*64*)
-	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	            ;;
-	          ia64*)
-	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	            ;;
-	          *)
-	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	            ;;
-	        esac
-	      fi
-	    else
-	      # FIXME: insert proper C++ library support
-	      _LT_TAGVAR(ld_shlibs, $1)=no
-	    fi
-	    ;;
-        esac
-        ;;
-
-      interix[[3-9]]*)
-	_LT_TAGVAR(hardcode_direct, $1)=no
-	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-	# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
-	# Instead, shared libraries are loaded at an image base (0x10000000 by
-	# default) and relocated if they conflict, which is a slow very memory
-	# consuming and fragmenting process.  To avoid this, we pick a random,
-	# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
-	# time.  Moving up from 0x10000000 also allows more sbrk(2) space.
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
-	;;
-      irix5* | irix6*)
-        case $cc_basename in
-          CC*)
-	    # SGI C++
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-
-	    # Archives containing C++ object files must be created using
-	    # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
-	    # necessary to make sure instantiated templates are included
-	    # in the archive.
-	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
-	    ;;
-          *)
-	    if test "$GXX" = yes; then
-	      if test "$with_gnu_ld" = no; then
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
-	      else
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib'
-	      fi
-	    fi
-	    _LT_TAGVAR(link_all_deplibs, $1)=yes
-	    ;;
-        esac
-        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-        _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-        _LT_TAGVAR(inherit_rpath, $1)=yes
-        ;;
-
-      linux* | k*bsd*-gnu)
-        case $cc_basename in
-          KCC*)
-	    # Kuck and Associates, Inc. (KAI) C++ Compiler
-
-	    # KCC will only create a shared library if the output file
-	    # ends with ".so" (or ".sl" for HP-UX), so rename the library
-	    # to its proper name (with version) after linking.
-	    _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
-	    # Commands to make compiler produce verbose output that lists
-	    # what "hidden" libraries, object files and flags are used when
-	    # linking a shared library.
-	    #
-	    # There doesn't appear to be a way to prevent this compiler from
-	    # explicitly linking system object files so we need to strip them
-	    # from the output so that they don't get included in the library
-	    # dependencies.
-	    output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
-
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
-
-	    # Archives containing C++ object files must be created using
-	    # "CC -Bstatic", where "CC" is the KAI C++ compiler.
-	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
-	    ;;
-	  icpc* | ecpc* )
-	    # Intel C++
-	    with_gnu_ld=yes
-	    # version 8.0 and above of icpc choke on multiply defined symbols
-	    # if we add $predep_objects and $postdep_objects, however 7.1 and
-	    # earlier do not add the objects themselves.
-	    case `$CC -V 2>&1` in
-	      *"Version 7."*)
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
-		_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-		;;
-	      *)  # Version 8.0 or newer
-	        tmp_idyn=
-	        case $host_cpu in
-		  ia64*) tmp_idyn=' -i_dynamic';;
-		esac
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-		_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-		;;
-	    esac
-	    _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
-	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
-	    ;;
-          pgCC* | pgcpp*)
-            # Portland Group C++ compiler
-	    case `$CC -V` in
-	    *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*)
-	      _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
-		rm -rf $tpldir~
-		$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
-		compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
-	      _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
-		rm -rf $tpldir~
-		$CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
-		$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
-		$RANLIB $oldlib'
-	      _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
-		rm -rf $tpldir~
-		$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
-		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
-	      _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
-		rm -rf $tpldir~
-		$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
-		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
-	      ;;
-	    *) # Version 6 will use weak symbols
-	      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
-	      _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
-	      ;;
-	    esac
-
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
-	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
-	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
-            ;;
-	  cxx*)
-	    # Compaq C++
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname  -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
-
-	    runpath_var=LD_RUN_PATH
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
-	    _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-
-	    # Commands to make compiler produce verbose output that lists
-	    # what "hidden" libraries, object files and flags are used when
-	    # linking a shared library.
-	    #
-	    # There doesn't appear to be a way to prevent this compiler from
-	    # explicitly linking system object files so we need to strip them
-	    # from the output so that they don't get included in the library
-	    # dependencies.
-	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
-	    ;;
-	  xl*)
-	    # IBM XL 8.0 on PPC, with GNU ld
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	    if test "x$supports_anon_versioning" = xyes; then
-	      _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
-		cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
-		echo "local: *; };" >> $output_objdir/$libname.ver~
-		$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
-	    fi
-	    ;;
-	  *)
-	    case `$CC -V 2>&1 | sed 5q` in
-	    *Sun\ C*)
-	      # Sun C++ 5.9
-	      _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
-	      _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	      _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
-	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-	      _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
-	      _LT_TAGVAR(compiler_needs_object, $1)=yes
-
-	      # Not sure whether something based on
-	      # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
-	      # would be better.
-	      output_verbose_link_cmd='echo'
-
-	      # Archives containing C++ object files must be created using
-	      # "CC -xar", where "CC" is the Sun C++ compiler.  This is
-	      # necessary to make sure instantiated templates are included
-	      # in the archive.
-	      _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
-	      ;;
-	    esac
-	    ;;
-	esac
-	;;
-
-      lynxos*)
-        # FIXME: insert proper C++ library support
-	_LT_TAGVAR(ld_shlibs, $1)=no
-	;;
-
-      m88k*)
-        # FIXME: insert proper C++ library support
-        _LT_TAGVAR(ld_shlibs, $1)=no
-	;;
-
-      mvs*)
-        case $cc_basename in
-          cxx*)
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-	  *)
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-	esac
-	;;
-
-      netbsd*)
-        if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
-	  _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
-	  wlarc=
-	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-	  _LT_TAGVAR(hardcode_direct, $1)=yes
-	  _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	fi
-	# Workaround some broken pre-1.5 toolchains
-	output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
-	;;
-
-      *nto* | *qnx*)
-        _LT_TAGVAR(ld_shlibs, $1)=yes
-	;;
-
-      openbsd2*)
-        # C++ shared libraries are fairly broken
-	_LT_TAGVAR(ld_shlibs, $1)=no
-	;;
-
-      openbsd*)
-	if test -f /usr/libexec/ld.so; then
-	  _LT_TAGVAR(hardcode_direct, $1)=yes
-	  _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	  _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
-	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
-	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-	    _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
-	  fi
-	  output_verbose_link_cmd=echo
-	else
-	  _LT_TAGVAR(ld_shlibs, $1)=no
-	fi
-	;;
-
-      osf3* | osf4* | osf5*)
-        case $cc_basename in
-          KCC*)
-	    # Kuck and Associates, Inc. (KAI) C++ Compiler
-
-	    # KCC will only create a shared library if the output file
-	    # ends with ".so" (or ".sl" for HP-UX), so rename the library
-	    # to its proper name (with version) after linking.
-	    _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
-
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	    _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-
-	    # Archives containing C++ object files must be created using
-	    # the KAI C++ compiler.
-	    case $host in
-	      osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
-	      *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
-	    esac
-	    ;;
-          RCC*)
-	    # Rational C++ 2.4.1
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-          cxx*)
-	    case $host in
-	      osf3*)
-	        _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-		;;
-	      *)
-	        _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	        _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
-	          echo "-hidden">> $lib.exp~
-	          $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp  `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~
-	          $RM $lib.exp'
-	        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
-		;;
-	    esac
-
-	    _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-
-	    # Commands to make compiler produce verbose output that lists
-	    # what "hidden" libraries, object files and flags are used when
-	    # linking a shared library.
-	    #
-	    # There doesn't appear to be a way to prevent this compiler from
-	    # explicitly linking system object files so we need to strip them
-	    # from the output so that they don't get included in the library
-	    # dependencies.
-	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
-	    ;;
-	  *)
-	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
-	      _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
-	      case $host in
-	        osf3*)
-	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
-		  ;;
-	        *)
-	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
-		  ;;
-	      esac
-
-	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-	      _LT_TAGVAR(hardcode_libdir_separator, $1)=:
-
-	      # Commands to make compiler produce verbose output that lists
-	      # what "hidden" libraries, object files and flags are used when
-	      # linking a shared library.
-	      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
-
-	    else
-	      # FIXME: insert proper C++ library support
-	      _LT_TAGVAR(ld_shlibs, $1)=no
-	    fi
-	    ;;
-        esac
-        ;;
-
-      psos*)
-        # FIXME: insert proper C++ library support
-        _LT_TAGVAR(ld_shlibs, $1)=no
-        ;;
-
-      sunos4*)
-        case $cc_basename in
-          CC*)
-	    # Sun C++ 4.x
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-          lcc*)
-	    # Lucid
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-          *)
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-        esac
-        ;;
-
-      solaris*)
-        case $cc_basename in
-          CC*)
-	    # Sun C++ 4.2, 5.x and Centerline C++
-            _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
-	    _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	      $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
-
-	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-	    _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	    case $host_os in
-	      solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
-	      *)
-		# The compiler driver will combine and reorder linker options,
-		# but understands `-z linker_flag'.
-	        # Supported since Solaris 2.6 (maybe 2.5.1?)
-		_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
-	        ;;
-	    esac
-	    _LT_TAGVAR(link_all_deplibs, $1)=yes
-
-	    output_verbose_link_cmd='echo'
-
-	    # Archives containing C++ object files must be created using
-	    # "CC -xar", where "CC" is the Sun C++ compiler.  This is
-	    # necessary to make sure instantiated templates are included
-	    # in the archive.
-	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
-	    ;;
-          gcx*)
-	    # Green Hills C++ Compiler
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
-
-	    # The C++ compiler must be used to create the archive.
-	    _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
-	    ;;
-          *)
-	    # GNU C++ compiler with Solaris linker
-	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
-	      _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
-	      if $CC --version | $GREP -v '^2\.7' > /dev/null; then
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
-	        _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-		  $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
-
-	        # Commands to make compiler produce verbose output that lists
-	        # what "hidden" libraries, object files and flags are used when
-	        # linking a shared library.
-	        output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
-	      else
-	        # g++ 2.7 appears to require `-G' NOT `-shared' on this
-	        # platform.
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
-	        _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-		  $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
-
-	        # Commands to make compiler produce verbose output that lists
-	        # what "hidden" libraries, object files and flags are used when
-	        # linking a shared library.
-	        output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
-	      fi
-
-	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
-	      case $host_os in
-		solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
-		*)
-		  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
-		  ;;
-	      esac
-	    fi
-	    ;;
-        esac
-        ;;
-
-    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
-      _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
-      _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-      _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-      runpath_var='LD_RUN_PATH'
-
-      case $cc_basename in
-        CC*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-      esac
-      ;;
-
-      sysv5* | sco3.2v5* | sco5v6*)
-	# Note: We can NOT use -z defs as we might desire, because we do not
-	# link with -lc, and that would cause any symbols used from libc to
-	# always be unresolved, which means just about no library would
-	# ever link correctly.  If we're not using GNU ld we use -z text
-	# though, which does catch some bad symbols but isn't as heavy-handed
-	# as -z defs.
-	_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
-	_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
-	_LT_TAGVAR(archive_cmds_need_lc, $1)=no
-	_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
-	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
-	_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
-	_LT_TAGVAR(link_all_deplibs, $1)=yes
-	_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
-	runpath_var='LD_RUN_PATH'
-
-	case $cc_basename in
-          CC*)
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	    ;;
-	  *)
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
-	    ;;
-	esac
-      ;;
-
-      tandem*)
-        case $cc_basename in
-          NCC*)
-	    # NonStop-UX NCC 3.20
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-          *)
-	    # FIXME: insert proper C++ library support
-	    _LT_TAGVAR(ld_shlibs, $1)=no
-	    ;;
-        esac
-        ;;
-
-      vxworks*)
-        # FIXME: insert proper C++ library support
-        _LT_TAGVAR(ld_shlibs, $1)=no
-        ;;
-
-      *)
-        # FIXME: insert proper C++ library support
-        _LT_TAGVAR(ld_shlibs, $1)=no
-        ;;
-    esac
-
-    AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
-    test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
-
-    _LT_TAGVAR(GCC, $1)="$GXX"
-    _LT_TAGVAR(LD, $1)="$LD"
-
-    ## CAVEAT EMPTOR:
-    ## There is no encapsulation within the following macros, do not change
-    ## the running order or otherwise move them around unless you know exactly
-    ## what you are doing...
-    _LT_SYS_HIDDEN_LIBDEPS($1)
-    _LT_COMPILER_PIC($1)
-    _LT_COMPILER_C_O($1)
-    _LT_COMPILER_FILE_LOCKS($1)
-    _LT_LINKER_SHLIBS($1)
-    _LT_SYS_DYNAMIC_LINKER($1)
-    _LT_LINKER_HARDCODE_LIBPATH($1)
-
-    _LT_CONFIG($1)
-  fi # test -n "$compiler"
-
-  CC=$lt_save_CC
-  LDCXX=$LD
-  LD=$lt_save_LD
-  GCC=$lt_save_GCC
-  with_gnu_ld=$lt_save_with_gnu_ld
-  lt_cv_path_LDCXX=$lt_cv_path_LD
-  lt_cv_path_LD=$lt_save_path_LD
-  lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
-  lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
-fi # test "$_lt_caught_CXX_error" != yes
-
-AC_LANG_POP
-])# _LT_LANG_CXX_CONFIG
-
-
-# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
-# ---------------------------------
-# Figure out "hidden" library dependencies from verbose
-# compiler output when linking a shared library.
-# Parse the compiler output and extract the necessary
-# objects, libraries and library flags.
-m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
-[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
-# Dependencies to place before and after the object being linked:
-_LT_TAGVAR(predep_objects, $1)=
-_LT_TAGVAR(postdep_objects, $1)=
-_LT_TAGVAR(predeps, $1)=
-_LT_TAGVAR(postdeps, $1)=
-_LT_TAGVAR(compiler_lib_search_path, $1)=
-
-dnl we can't use the lt_simple_compile_test_code here,
-dnl because it contains code intended for an executable,
-dnl not a library.  It's possible we should let each
-dnl tag define a new lt_????_link_test_code variable,
-dnl but it's only used here...
-m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
-int a;
-void foo (void) { a = 0; }
-_LT_EOF
-], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
-class Foo
-{
-public:
-  Foo (void) { a = 0; }
-private:
-  int a;
-};
-_LT_EOF
-], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
-      subroutine foo
-      implicit none
-      integer*4 a
-      a=0
-      return
-      end
-_LT_EOF
-], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
-      subroutine foo
-      implicit none
-      integer a
-      a=0
-      return
-      end
-_LT_EOF
-], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
-public class foo {
-  private int a;
-  public void bar (void) {
-    a = 0;
-  }
-};
-_LT_EOF
-])
-dnl Parse the compiler output and extract the necessary
-dnl objects, libraries and library flags.
-if AC_TRY_EVAL(ac_compile); then
-  # Parse the compiler output and extract the necessary
-  # objects, libraries and library flags.
-
-  # Sentinel used to keep track of whether or not we are before
-  # the conftest object file.
-  pre_test_object_deps_done=no
-
-  for p in `eval "$output_verbose_link_cmd"`; do
-    case $p in
-
-    -L* | -R* | -l*)
-       # Some compilers place space between "-{L,R}" and the path.
-       # Remove the space.
-       if test $p = "-L" ||
-          test $p = "-R"; then
-	 prev=$p
-	 continue
-       else
-	 prev=
-       fi
-
-       if test "$pre_test_object_deps_done" = no; then
-	 case $p in
-	 -L* | -R*)
-	   # Internal compiler library paths should come after those
-	   # provided the user.  The postdeps already come after the
-	   # user supplied libs so there is no need to process them.
-	   if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
-	     _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
-	   else
-	     _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
-	   fi
-	   ;;
-	 # The "-l" case would never come before the object being
-	 # linked, so don't bother handling this case.
-	 esac
-       else
-	 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
-	   _LT_TAGVAR(postdeps, $1)="${prev}${p}"
-	 else
-	   _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
-	 fi
-       fi
-       ;;
-
-    *.$objext)
-       # This assumes that the test object file only shows up
-       # once in the compiler output.
-       if test "$p" = "conftest.$objext"; then
-	 pre_test_object_deps_done=yes
-	 continue
-       fi
-
-       if test "$pre_test_object_deps_done" = no; then
-	 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
-	   _LT_TAGVAR(predep_objects, $1)="$p"
-	 else
-	   _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
-	 fi
-       else
-	 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
-	   _LT_TAGVAR(postdep_objects, $1)="$p"
-	 else
-	   _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
-	 fi
-       fi
-       ;;
-
-    *) ;; # Ignore the rest.
-
-    esac
-  done
-
-  # Clean up.
-  rm -f a.out a.exe
-else
-  echo "libtool.m4: error: problem compiling $1 test program"
-fi
-
-$RM -f confest.$objext
-
-# PORTME: override above test on systems where it is broken
-m4_if([$1], [CXX],
-[case $host_os in
-interix[[3-9]]*)
-  # Interix 3.5 installs completely hosed .la files for C++, so rather than
-  # hack all around it, let's just trust "g++" to DTRT.
-  _LT_TAGVAR(predep_objects,$1)=
-  _LT_TAGVAR(postdep_objects,$1)=
-  _LT_TAGVAR(postdeps,$1)=
-  ;;
-
-linux*)
-  case `$CC -V 2>&1 | sed 5q` in
-  *Sun\ C*)
-    # Sun C++ 5.9
-
-    # The more standards-conforming stlport4 library is
-    # incompatible with the Cstd library. Avoid specifying
-    # it if it's in CXXFLAGS. Ignore libCrun as
-    # -library=stlport4 depends on it.
-    case " $CXX $CXXFLAGS " in
-    *" -library=stlport4 "*)
-      solaris_use_stlport4=yes
-      ;;
-    esac
-
-    if test "$solaris_use_stlport4" != yes; then
-      _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
-    fi
-    ;;
-  esac
-  ;;
-
-solaris*)
-  case $cc_basename in
-  CC*)
-    # The more standards-conforming stlport4 library is
-    # incompatible with the Cstd library. Avoid specifying
-    # it if it's in CXXFLAGS. Ignore libCrun as
-    # -library=stlport4 depends on it.
-    case " $CXX $CXXFLAGS " in
-    *" -library=stlport4 "*)
-      solaris_use_stlport4=yes
-      ;;
-    esac
-
-    # Adding this requires a known-good setup of shared libraries for
-    # Sun compiler versions before 5.6, else PIC objects from an old
-    # archive will be linked into the output, leading to subtle bugs.
-    if test "$solaris_use_stlport4" != yes; then
-      _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
-    fi
-    ;;
-  esac
-  ;;
-esac
-])
-
-case " $_LT_TAGVAR(postdeps, $1) " in
-*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
-esac
- _LT_TAGVAR(compiler_lib_search_dirs, $1)=
-if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
- _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
-fi
-_LT_TAGDECL([], [compiler_lib_search_dirs], [1],
-    [The directories searched by this compiler when creating a shared library])
-_LT_TAGDECL([], [predep_objects], [1],
-    [Dependencies to place before and after the objects being linked to
-    create a shared library])
-_LT_TAGDECL([], [postdep_objects], [1])
-_LT_TAGDECL([], [predeps], [1])
-_LT_TAGDECL([], [postdeps], [1])
-_LT_TAGDECL([], [compiler_lib_search_path], [1],
-    [The library search path used internally by the compiler when linking
-    a shared library])
-])# _LT_SYS_HIDDEN_LIBDEPS
-
-
-# _LT_PROG_F77
-# ------------
-# Since AC_PROG_F77 is broken, in that it returns the empty string
-# if there is no fortran compiler, we have our own version here.
-m4_defun([_LT_PROG_F77],
-[
-pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes])
-AC_PROG_F77
-if test -z "$F77" || test "X$F77" = "Xno"; then
-  _lt_disable_F77=yes
-fi
-popdef([AC_MSG_ERROR])
-])# _LT_PROG_F77
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([_LT_PROG_F77], [])
-
-
-# _LT_LANG_F77_CONFIG([TAG])
-# --------------------------
-# Ensure that the configuration variables for a Fortran 77 compiler are
-# suitably defined.  These variables are subsequently used by _LT_CONFIG
-# to write the compiler configuration to `libtool'.
-m4_defun([_LT_LANG_F77_CONFIG],
-[AC_REQUIRE([_LT_PROG_F77])dnl
-AC_LANG_PUSH(Fortran 77)
-
-_LT_TAGVAR(archive_cmds_need_lc, $1)=no
-_LT_TAGVAR(allow_undefined_flag, $1)=
-_LT_TAGVAR(always_export_symbols, $1)=no
-_LT_TAGVAR(archive_expsym_cmds, $1)=
-_LT_TAGVAR(export_dynamic_flag_spec, $1)=
-_LT_TAGVAR(hardcode_direct, $1)=no
-_LT_TAGVAR(hardcode_direct_absolute, $1)=no
-_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
-_LT_TAGVAR(hardcode_libdir_separator, $1)=
-_LT_TAGVAR(hardcode_minus_L, $1)=no
-_LT_TAGVAR(hardcode_automatic, $1)=no
-_LT_TAGVAR(inherit_rpath, $1)=no
-_LT_TAGVAR(module_cmds, $1)=
-_LT_TAGVAR(module_expsym_cmds, $1)=
-_LT_TAGVAR(link_all_deplibs, $1)=unknown
-_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-_LT_TAGVAR(no_undefined_flag, $1)=
-_LT_TAGVAR(whole_archive_flag_spec, $1)=
-_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
-
-# Source file extension for f77 test sources.
-ac_ext=f
-
-# Object file extension for compiled f77 test sources.
-objext=o
-_LT_TAGVAR(objext, $1)=$objext
-
-# No sense in running all these tests if we already determined that
-# the F77 compiler isn't working.  Some variables (like enable_shared)
-# are currently assumed to apply to all compilers on this platform,
-# and will be corrupted by setting them based on a non-working compiler.
-if test "$_lt_disable_F77" != yes; then
-  # Code to be used in simple compile tests
-  lt_simple_compile_test_code="\
-      subroutine t
-      return
-      end
-"
-
-  # Code to be used in simple link tests
-  lt_simple_link_test_code="\
-      program t
-      end
-"
-
-  # ltmain only uses $CC for tagged configurations so make sure $CC is set.
-  _LT_TAG_COMPILER
-
-  # save warnings/boilerplate of simple test code
-  _LT_COMPILER_BOILERPLATE
-  _LT_LINKER_BOILERPLATE
-
-  # Allow CC to be a program name with arguments.
-  lt_save_CC="$CC"
-  lt_save_GCC=$GCC
-  CC=${F77-"f77"}
-  compiler=$CC
-  _LT_TAGVAR(compiler, $1)=$CC
-  _LT_CC_BASENAME([$compiler])
-  GCC=$G77
-  if test -n "$compiler"; then
-    AC_MSG_CHECKING([if libtool supports shared libraries])
-    AC_MSG_RESULT([$can_build_shared])
-
-    AC_MSG_CHECKING([whether to build shared libraries])
-    test "$can_build_shared" = "no" && enable_shared=no
-
-    # On AIX, shared libraries and static libraries use the same namespace, and
-    # are all built from PIC.
-    case $host_os in
-      aix3*)
-        test "$enable_shared" = yes && enable_static=no
-        if test -n "$RANLIB"; then
-          archive_cmds="$archive_cmds~\$RANLIB \$lib"
-          postinstall_cmds='$RANLIB $lib'
-        fi
-        ;;
-      aix[[4-9]]*)
-	if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
-	  test "$enable_shared" = yes && enable_static=no
-	fi
-        ;;
-    esac
-    AC_MSG_RESULT([$enable_shared])
-
-    AC_MSG_CHECKING([whether to build static libraries])
-    # Make sure either enable_shared or enable_static is yes.
-    test "$enable_shared" = yes || enable_static=yes
-    AC_MSG_RESULT([$enable_static])
-
-    _LT_TAGVAR(GCC, $1)="$G77"
-    _LT_TAGVAR(LD, $1)="$LD"
-
-    ## CAVEAT EMPTOR:
-    ## There is no encapsulation within the following macros, do not change
-    ## the running order or otherwise move them around unless you know exactly
-    ## what you are doing...
-    _LT_COMPILER_PIC($1)
-    _LT_COMPILER_C_O($1)
-    _LT_COMPILER_FILE_LOCKS($1)
-    _LT_LINKER_SHLIBS($1)
-    _LT_SYS_DYNAMIC_LINKER($1)
-    _LT_LINKER_HARDCODE_LIBPATH($1)
-
-    _LT_CONFIG($1)
-  fi # test -n "$compiler"
-
-  GCC=$lt_save_GCC
-  CC="$lt_save_CC"
-fi # test "$_lt_disable_F77" != yes
-
-AC_LANG_POP
-])# _LT_LANG_F77_CONFIG
-
-
-# _LT_PROG_FC
-# -----------
-# Since AC_PROG_FC is broken, in that it returns the empty string
-# if there is no fortran compiler, we have our own version here.
-m4_defun([_LT_PROG_FC],
-[
-pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes])
-AC_PROG_FC
-if test -z "$FC" || test "X$FC" = "Xno"; then
-  _lt_disable_FC=yes
-fi
-popdef([AC_MSG_ERROR])
-])# _LT_PROG_FC
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([_LT_PROG_FC], [])
-
-
-# _LT_LANG_FC_CONFIG([TAG])
-# -------------------------
-# Ensure that the configuration variables for a Fortran compiler are
-# suitably defined.  These variables are subsequently used by _LT_CONFIG
-# to write the compiler configuration to `libtool'.
-m4_defun([_LT_LANG_FC_CONFIG],
-[AC_REQUIRE([_LT_PROG_FC])dnl
-AC_LANG_PUSH(Fortran)
-
-_LT_TAGVAR(archive_cmds_need_lc, $1)=no
-_LT_TAGVAR(allow_undefined_flag, $1)=
-_LT_TAGVAR(always_export_symbols, $1)=no
-_LT_TAGVAR(archive_expsym_cmds, $1)=
-_LT_TAGVAR(export_dynamic_flag_spec, $1)=
-_LT_TAGVAR(hardcode_direct, $1)=no
-_LT_TAGVAR(hardcode_direct_absolute, $1)=no
-_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
-_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
-_LT_TAGVAR(hardcode_libdir_separator, $1)=
-_LT_TAGVAR(hardcode_minus_L, $1)=no
-_LT_TAGVAR(hardcode_automatic, $1)=no
-_LT_TAGVAR(inherit_rpath, $1)=no
-_LT_TAGVAR(module_cmds, $1)=
-_LT_TAGVAR(module_expsym_cmds, $1)=
-_LT_TAGVAR(link_all_deplibs, $1)=unknown
-_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-_LT_TAGVAR(no_undefined_flag, $1)=
-_LT_TAGVAR(whole_archive_flag_spec, $1)=
-_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
-
-# Source file extension for fc test sources.
-ac_ext=${ac_fc_srcext-f}
-
-# Object file extension for compiled fc test sources.
-objext=o
-_LT_TAGVAR(objext, $1)=$objext
-
-# No sense in running all these tests if we already determined that
-# the FC compiler isn't working.  Some variables (like enable_shared)
-# are currently assumed to apply to all compilers on this platform,
-# and will be corrupted by setting them based on a non-working compiler.
-if test "$_lt_disable_FC" != yes; then
-  # Code to be used in simple compile tests
-  lt_simple_compile_test_code="\
-      subroutine t
-      return
-      end
-"
-
-  # Code to be used in simple link tests
-  lt_simple_link_test_code="\
-      program t
-      end
-"
-
-  # ltmain only uses $CC for tagged configurations so make sure $CC is set.
-  _LT_TAG_COMPILER
-
-  # save warnings/boilerplate of simple test code
-  _LT_COMPILER_BOILERPLATE
-  _LT_LINKER_BOILERPLATE
-
-  # Allow CC to be a program name with arguments.
-  lt_save_CC="$CC"
-  lt_save_GCC=$GCC
-  CC=${FC-"f95"}
-  compiler=$CC
-  GCC=$ac_cv_fc_compiler_gnu
-
-  _LT_TAGVAR(compiler, $1)=$CC
-  _LT_CC_BASENAME([$compiler])
-
-  if test -n "$compiler"; then
-    AC_MSG_CHECKING([if libtool supports shared libraries])
-    AC_MSG_RESULT([$can_build_shared])
-
-    AC_MSG_CHECKING([whether to build shared libraries])
-    test "$can_build_shared" = "no" && enable_shared=no
-
-    # On AIX, shared libraries and static libraries use the same namespace, and
-    # are all built from PIC.
-    case $host_os in
-      aix3*)
-        test "$enable_shared" = yes && enable_static=no
-        if test -n "$RANLIB"; then
-          archive_cmds="$archive_cmds~\$RANLIB \$lib"
-          postinstall_cmds='$RANLIB $lib'
-        fi
-        ;;
-      aix[[4-9]]*)
-	if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
-	  test "$enable_shared" = yes && enable_static=no
-	fi
-        ;;
-    esac
-    AC_MSG_RESULT([$enable_shared])
-
-    AC_MSG_CHECKING([whether to build static libraries])
-    # Make sure either enable_shared or enable_static is yes.
-    test "$enable_shared" = yes || enable_static=yes
-    AC_MSG_RESULT([$enable_static])
-
-    _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
-    _LT_TAGVAR(LD, $1)="$LD"
-
-    ## CAVEAT EMPTOR:
-    ## There is no encapsulation within the following macros, do not change
-    ## the running order or otherwise move them around unless you know exactly
-    ## what you are doing...
-    _LT_SYS_HIDDEN_LIBDEPS($1)
-    _LT_COMPILER_PIC($1)
-    _LT_COMPILER_C_O($1)
-    _LT_COMPILER_FILE_LOCKS($1)
-    _LT_LINKER_SHLIBS($1)
-    _LT_SYS_DYNAMIC_LINKER($1)
-    _LT_LINKER_HARDCODE_LIBPATH($1)
-
-    _LT_CONFIG($1)
-  fi # test -n "$compiler"
-
-  GCC=$lt_save_GCC
-  CC="$lt_save_CC"
-fi # test "$_lt_disable_FC" != yes
-
-AC_LANG_POP
-])# _LT_LANG_FC_CONFIG
-
-
-# _LT_LANG_GCJ_CONFIG([TAG])
-# --------------------------
-# Ensure that the configuration variables for the GNU Java Compiler compiler
-# are suitably defined.  These variables are subsequently used by _LT_CONFIG
-# to write the compiler configuration to `libtool'.
-m4_defun([_LT_LANG_GCJ_CONFIG],
-[AC_REQUIRE([LT_PROG_GCJ])dnl
-AC_LANG_SAVE
-
-# Source file extension for Java test sources.
-ac_ext=java
-
-# Object file extension for compiled Java test sources.
-objext=o
-_LT_TAGVAR(objext, $1)=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="class foo {}"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
-
-# ltmain only uses $CC for tagged configurations so make sure $CC is set.
-_LT_TAG_COMPILER
-
-# save warnings/boilerplate of simple test code
-_LT_COMPILER_BOILERPLATE
-_LT_LINKER_BOILERPLATE
-
-# Allow CC to be a program name with arguments.
-lt_save_CC="$CC"
-lt_save_GCC=$GCC
-GCC=yes
-CC=${GCJ-"gcj"}
-compiler=$CC
-_LT_TAGVAR(compiler, $1)=$CC
-_LT_TAGVAR(LD, $1)="$LD"
-_LT_CC_BASENAME([$compiler])
-
-# GCJ did not exist at the time GCC didn't implicitly link libc in.
-_LT_TAGVAR(archive_cmds_need_lc, $1)=no
-
-_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-
-if test -n "$compiler"; then
-  _LT_COMPILER_NO_RTTI($1)
-  _LT_COMPILER_PIC($1)
-  _LT_COMPILER_C_O($1)
-  _LT_COMPILER_FILE_LOCKS($1)
-  _LT_LINKER_SHLIBS($1)
-  _LT_LINKER_HARDCODE_LIBPATH($1)
-
-  _LT_CONFIG($1)
-fi
-
-AC_LANG_RESTORE
-
-GCC=$lt_save_GCC
-CC="$lt_save_CC"
-])# _LT_LANG_GCJ_CONFIG
-
-
-# _LT_LANG_RC_CONFIG([TAG])
-# -------------------------
-# Ensure that the configuration variables for the Windows resource compiler
-# are suitably defined.  These variables are subsequently used by _LT_CONFIG
-# to write the compiler configuration to `libtool'.
-m4_defun([_LT_LANG_RC_CONFIG],
-[AC_REQUIRE([LT_PROG_RC])dnl
-AC_LANG_SAVE
-
-# Source file extension for RC test sources.
-ac_ext=rc
-
-# Object file extension for compiled RC test sources.
-objext=o
-_LT_TAGVAR(objext, $1)=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
-
-# Code to be used in simple link tests
-lt_simple_link_test_code="$lt_simple_compile_test_code"
-
-# ltmain only uses $CC for tagged configurations so make sure $CC is set.
-_LT_TAG_COMPILER
-
-# save warnings/boilerplate of simple test code
-_LT_COMPILER_BOILERPLATE
-_LT_LINKER_BOILERPLATE
-
-# Allow CC to be a program name with arguments.
-lt_save_CC="$CC"
-lt_save_GCC=$GCC
-GCC=
-CC=${RC-"windres"}
-compiler=$CC
-_LT_TAGVAR(compiler, $1)=$CC
-_LT_CC_BASENAME([$compiler])
-_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
-
-if test -n "$compiler"; then
-  :
-  _LT_CONFIG($1)
-fi
-
-GCC=$lt_save_GCC
-AC_LANG_RESTORE
-CC="$lt_save_CC"
-])# _LT_LANG_RC_CONFIG
-
-
-# LT_PROG_GCJ
-# -----------
-AC_DEFUN([LT_PROG_GCJ],
-[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
-  [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
-    [AC_CHECK_TOOL(GCJ, gcj,)
-      test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
-      AC_SUBST(GCJFLAGS)])])[]dnl
-])
-
-# Old name:
-AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
-
-
-# LT_PROG_RC
-# ----------
-AC_DEFUN([LT_PROG_RC],
-[AC_CHECK_TOOL(RC, windres,)
-])
-
-# Old name:
-AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([LT_AC_PROG_RC], [])
-
-
-# _LT_DECL_EGREP
-# --------------
-# If we don't have a new enough Autoconf to choose the best grep
-# available, choose the one first in the user's PATH.
-m4_defun([_LT_DECL_EGREP],
-[AC_REQUIRE([AC_PROG_EGREP])dnl
-AC_REQUIRE([AC_PROG_FGREP])dnl
-test -z "$GREP" && GREP=grep
-_LT_DECL([], [GREP], [1], [A grep program that handles long lines])
-_LT_DECL([], [EGREP], [1], [An ERE matcher])
-_LT_DECL([], [FGREP], [1], [A literal string matcher])
-dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
-AC_SUBST([GREP])
-])
-
-
-# _LT_DECL_OBJDUMP
-# --------------
-# If we don't have a new enough Autoconf to choose the best objdump
-# available, choose the one first in the user's PATH.
-m4_defun([_LT_DECL_OBJDUMP],
-[AC_CHECK_TOOL(OBJDUMP, objdump, false)
-test -z "$OBJDUMP" && OBJDUMP=objdump
-_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
-AC_SUBST([OBJDUMP])
-])
-
-
-# _LT_DECL_SED
-# ------------
-# Check for a fully-functional sed program, that truncates
-# as few characters as possible.  Prefer GNU sed if found.
-m4_defun([_LT_DECL_SED],
-[AC_PROG_SED
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-_LT_DECL([], [SED], [1], [A sed program that does not truncate output])
-_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
-    [Sed that helps us avoid accidentally triggering echo(1) options like -n])
-])# _LT_DECL_SED
-
-m4_ifndef([AC_PROG_SED], [
-# NOTE: This macro has been submitted for inclusion into   #
-#  GNU Autoconf as AC_PROG_SED.  When it is available in   #
-#  a released version of Autoconf we should remove this    #
-#  macro and use it instead.                               #
-
-m4_defun([AC_PROG_SED],
-[AC_MSG_CHECKING([for a sed that does not truncate output])
-AC_CACHE_VAL(lt_cv_path_SED,
-[# Loop through the user's path and test for sed and gsed.
-# Then use that list of sed's as ones to test for truncation.
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for lt_ac_prog in sed gsed; do
-    for ac_exec_ext in '' $ac_executable_extensions; do
-      if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
-        lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
-      fi
-    done
-  done
-done
-IFS=$as_save_IFS
-lt_ac_max=0
-lt_ac_count=0
-# Add /usr/xpg4/bin/sed as it is typically found on Solaris
-# along with /bin/sed that truncates output.
-for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
-  test ! -f $lt_ac_sed && continue
-  cat /dev/null > conftest.in
-  lt_ac_count=0
-  echo $ECHO_N "0123456789$ECHO_C" >conftest.in
-  # Check for GNU sed and select it if it is found.
-  if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
-    lt_cv_path_SED=$lt_ac_sed
-    break
-  fi
-  while true; do
-    cat conftest.in conftest.in >conftest.tmp
-    mv conftest.tmp conftest.in
-    cp conftest.in conftest.nl
-    echo >>conftest.nl
-    $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
-    cmp -s conftest.out conftest.nl || break
-    # 10000 chars as input seems more than enough
-    test $lt_ac_count -gt 10 && break
-    lt_ac_count=`expr $lt_ac_count + 1`
-    if test $lt_ac_count -gt $lt_ac_max; then
-      lt_ac_max=$lt_ac_count
-      lt_cv_path_SED=$lt_ac_sed
-    fi
-  done
-done
-])
-SED=$lt_cv_path_SED
-AC_SUBST([SED])
-AC_MSG_RESULT([$SED])
-])#AC_PROG_SED
-])#m4_ifndef
-
-# Old name:
-AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([LT_AC_PROG_SED], [])
-
-
-# _LT_CHECK_SHELL_FEATURES
-# ------------------------
-# Find out whether the shell is Bourne or XSI compatible,
-# or has some other useful features.
-m4_defun([_LT_CHECK_SHELL_FEATURES],
-[AC_MSG_CHECKING([whether the shell understands some XSI constructs])
-# Try some XSI features
-xsi_shell=no
-( _lt_dummy="a/b/c"
-  test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
-      = c,a/b,, \
-    && eval 'test $(( 1 + 1 )) -eq 2 \
-    && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
-  && xsi_shell=yes
-AC_MSG_RESULT([$xsi_shell])
-_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
-
-AC_MSG_CHECKING([whether the shell understands "+="])
-lt_shell_append=no
-( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
-    >/dev/null 2>&1 \
-  && lt_shell_append=yes
-AC_MSG_RESULT([$lt_shell_append])
-_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
-
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-  lt_unset=unset
-else
-  lt_unset=false
-fi
-_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
-
-# test EBCDIC or ASCII
-case `echo X|tr X '\101'` in
- A) # ASCII based system
-    # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
-  lt_SP2NL='tr \040 \012'
-  lt_NL2SP='tr \015\012 \040\040'
-  ;;
- *) # EBCDIC based system
-  lt_SP2NL='tr \100 \n'
-  lt_NL2SP='tr \r\n \100\100'
-  ;;
-esac
-_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
-_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
-])# _LT_CHECK_SHELL_FEATURES
-
-
-# _LT_PROG_XSI_SHELLFNS
-# ---------------------
-# Bourne and XSI compatible variants of some useful shell functions.
-m4_defun([_LT_PROG_XSI_SHELLFNS],
-[case $xsi_shell in
-  yes)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
-  case ${1} in
-    */*) func_dirname_result="${1%/*}${2}" ;;
-    *  ) func_dirname_result="${3}" ;;
-  esac
-}
-
-# func_basename file
-func_basename ()
-{
-  func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-#   dirname:  Compute the dirname of FILE.  If nonempty,
-#             add APPEND to the result, otherwise set result
-#             to NONDIR_REPLACEMENT.
-#             value returned in "$func_dirname_result"
-#   basename: Compute filename of FILE.
-#             value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
-  case ${1} in
-    */*) func_dirname_result="${1%/*}${2}" ;;
-    *  ) func_dirname_result="${3}" ;;
-  esac
-  func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
-  # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
-  # positional parameters, so assign one to ordinary parameter first.
-  func_stripname_result=${3}
-  func_stripname_result=${func_stripname_result#"${1}"}
-  func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
-  func_opt_split_opt=${1%%=*}
-  func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
-  case ${1} in
-    *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
-    *)    func_lo2o_result=${1} ;;
-  esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
-  func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
-  func_arith_result=$(( $[*] ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
-  func_len_result=${#1}
-}
-
-_LT_EOF
-    ;;
-  *) # Bourne compatible functions.
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
-  # Extract subdirectory from the argument.
-  func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
-  if test "X$func_dirname_result" = "X${1}"; then
-    func_dirname_result="${3}"
-  else
-    func_dirname_result="$func_dirname_result${2}"
-  fi
-}
-
-# func_basename file
-func_basename ()
-{
-  func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
-}
-
-dnl func_dirname_and_basename
-dnl A portable version of this function is already defined in general.m4sh
-dnl so there is no need for it here.
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
-  case ${2} in
-    .*) func_stripname_result=`$ECHO "X${3}" \
-           | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
-    *)  func_stripname_result=`$ECHO "X${3}" \
-           | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
-  esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[[^=]]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
-  func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
-  func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
-  func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
-  func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
-  func_arith_result=`expr "$[@]"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
-  func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
-  yes)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
-  eval "$[1]+=\$[2]"
-}
-_LT_EOF
-    ;;
-  *)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
-  eval "$[1]=\$$[1]\$[2]"
-}
-
-_LT_EOF
-    ;;
-  esac
-])
-
-# Helper functions for option handling.                    -*- Autoconf -*-
-#
-#   Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
-#   Written by Gary V. Vaughan, 2004
-#
-# This file is free software; the Free Software Foundation gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-
-# serial 6 ltoptions.m4
-
-# This is to help aclocal find these macros, as it can't see m4_define.
-AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
-
-
-# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
-# ------------------------------------------
-m4_define([_LT_MANGLE_OPTION],
-[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
-
-
-# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
-# ---------------------------------------
-# Set option OPTION-NAME for macro MACRO-NAME, and if there is a
-# matching handler defined, dispatch to it.  Other OPTION-NAMEs are
-# saved as a flag.
-m4_define([_LT_SET_OPTION],
-[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
-m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
-        _LT_MANGLE_DEFUN([$1], [$2]),
-    [m4_warning([Unknown $1 option `$2'])])[]dnl
-])
-
-
-# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
-# ------------------------------------------------------------
-# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
-m4_define([_LT_IF_OPTION],
-[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
-
-
-# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
-# -------------------------------------------------------
-# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
-# are set.
-m4_define([_LT_UNLESS_OPTIONS],
-[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
-	    [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
-		      [m4_define([$0_found])])])[]dnl
-m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
-])[]dnl
-])
-
-
-# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
-# ----------------------------------------
-# OPTION-LIST is a space-separated list of Libtool options associated
-# with MACRO-NAME.  If any OPTION has a matching handler declared with
-# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
-# the unknown option and exit.
-m4_defun([_LT_SET_OPTIONS],
-[# Set options
-m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
-    [_LT_SET_OPTION([$1], _LT_Option)])
-
-m4_if([$1],[LT_INIT],[
-  dnl
-  dnl Simply set some default values (i.e off) if boolean options were not
-  dnl specified:
-  _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
-  ])
-  _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
-  ])
-  dnl
-  dnl If no reference was made to various pairs of opposing options, then
-  dnl we run the default mode handler for the pair.  For example, if neither
-  dnl `shared' nor `disable-shared' was passed, we enable building of shared
-  dnl archives by default:
-  _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
-  _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
-  _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
-  _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
-  		   [_LT_ENABLE_FAST_INSTALL])
-  ])
-])# _LT_SET_OPTIONS
-
-
-
-# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
-# -----------------------------------------
-m4_define([_LT_MANGLE_DEFUN],
-[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
-
-
-# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
-# -----------------------------------------------
-m4_define([LT_OPTION_DEFINE],
-[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
-])# LT_OPTION_DEFINE
-
-
-# dlopen
-# ------
-LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
-])
-
-AU_DEFUN([AC_LIBTOOL_DLOPEN],
-[_LT_SET_OPTION([LT_INIT], [dlopen])
-AC_DIAGNOSE([obsolete],
-[$0: Remove this warning and the call to _LT_SET_OPTION when you
-put the `dlopen' option into LT_INIT's first parameter.])
-])
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
-
-
-# win32-dll
-# ---------
-# Declare package support for building win32 dll's.
-LT_OPTION_DEFINE([LT_INIT], [win32-dll],
-[enable_win32_dll=yes
-
-case $host in
-*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*)
-  AC_CHECK_TOOL(AS, as, false)
-  AC_CHECK_TOOL(DLLTOOL, dlltool, false)
-  AC_CHECK_TOOL(OBJDUMP, objdump, false)
-  ;;
-esac
-
-test -z "$AS" && AS=as
-_LT_DECL([], [AS],      [0], [Assembler program])dnl
-
-test -z "$DLLTOOL" && DLLTOOL=dlltool
-_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl
-
-test -z "$OBJDUMP" && OBJDUMP=objdump
-_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl
-])# win32-dll
-
-AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
-[AC_REQUIRE([AC_CANONICAL_HOST])dnl
-_LT_SET_OPTION([LT_INIT], [win32-dll])
-AC_DIAGNOSE([obsolete],
-[$0: Remove this warning and the call to _LT_SET_OPTION when you
-put the `win32-dll' option into LT_INIT's first parameter.])
-])
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
-
-
-# _LT_ENABLE_SHARED([DEFAULT])
-# ----------------------------
-# implement the --enable-shared flag, and supports the `shared' and
-# `disable-shared' LT_INIT options.
-# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
-m4_define([_LT_ENABLE_SHARED],
-[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
-AC_ARG_ENABLE([shared],
-    [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
-	[build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
-    [p=${PACKAGE-default}
-    case $enableval in
-    yes) enable_shared=yes ;;
-    no) enable_shared=no ;;
-    *)
-      enable_shared=no
-      # Look at the argument we got.  We use all the common list separators.
-      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
-      for pkg in $enableval; do
-	IFS="$lt_save_ifs"
-	if test "X$pkg" = "X$p"; then
-	  enable_shared=yes
-	fi
-      done
-      IFS="$lt_save_ifs"
-      ;;
-    esac],
-    [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
-
-    _LT_DECL([build_libtool_libs], [enable_shared], [0],
-	[Whether or not to build shared libraries])
-])# _LT_ENABLE_SHARED
-
-LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
-LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
-
-# Old names:
-AC_DEFUN([AC_ENABLE_SHARED],
-[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
-])
-
-AC_DEFUN([AC_DISABLE_SHARED],
-[_LT_SET_OPTION([LT_INIT], [disable-shared])
-])
-
-AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
-AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AM_ENABLE_SHARED], [])
-dnl AC_DEFUN([AM_DISABLE_SHARED], [])
-
-
-
-# _LT_ENABLE_STATIC([DEFAULT])
-# ----------------------------
-# implement the --enable-static flag, and support the `static' and
-# `disable-static' LT_INIT options.
-# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
-m4_define([_LT_ENABLE_STATIC],
-[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
-AC_ARG_ENABLE([static],
-    [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
-	[build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
-    [p=${PACKAGE-default}
-    case $enableval in
-    yes) enable_static=yes ;;
-    no) enable_static=no ;;
-    *)
-     enable_static=no
-      # Look at the argument we got.  We use all the common list separators.
-      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
-      for pkg in $enableval; do
-	IFS="$lt_save_ifs"
-	if test "X$pkg" = "X$p"; then
-	  enable_static=yes
-	fi
-      done
-      IFS="$lt_save_ifs"
-      ;;
-    esac],
-    [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
-
-    _LT_DECL([build_old_libs], [enable_static], [0],
-	[Whether or not to build static libraries])
-])# _LT_ENABLE_STATIC
-
-LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
-LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
-
-# Old names:
-AC_DEFUN([AC_ENABLE_STATIC],
-[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
-])
-
-AC_DEFUN([AC_DISABLE_STATIC],
-[_LT_SET_OPTION([LT_INIT], [disable-static])
-])
-
-AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
-AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AM_ENABLE_STATIC], [])
-dnl AC_DEFUN([AM_DISABLE_STATIC], [])
-
-
-
-# _LT_ENABLE_FAST_INSTALL([DEFAULT])
-# ----------------------------------
-# implement the --enable-fast-install flag, and support the `fast-install'
-# and `disable-fast-install' LT_INIT options.
-# DEFAULT is either `yes' or `no'.  If omitted, it defaults to `yes'.
-m4_define([_LT_ENABLE_FAST_INSTALL],
-[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
-AC_ARG_ENABLE([fast-install],
-    [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
-    [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
-    [p=${PACKAGE-default}
-    case $enableval in
-    yes) enable_fast_install=yes ;;
-    no) enable_fast_install=no ;;
-    *)
-      enable_fast_install=no
-      # Look at the argument we got.  We use all the common list separators.
-      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
-      for pkg in $enableval; do
-	IFS="$lt_save_ifs"
-	if test "X$pkg" = "X$p"; then
-	  enable_fast_install=yes
-	fi
-      done
-      IFS="$lt_save_ifs"
-      ;;
-    esac],
-    [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
-
-_LT_DECL([fast_install], [enable_fast_install], [0],
-	 [Whether or not to optimize for fast installation])dnl
-])# _LT_ENABLE_FAST_INSTALL
-
-LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
-LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
-
-# Old names:
-AU_DEFUN([AC_ENABLE_FAST_INSTALL],
-[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
-AC_DIAGNOSE([obsolete],
-[$0: Remove this warning and the call to _LT_SET_OPTION when you put
-the `fast-install' option into LT_INIT's first parameter.])
-])
-
-AU_DEFUN([AC_DISABLE_FAST_INSTALL],
-[_LT_SET_OPTION([LT_INIT], [disable-fast-install])
-AC_DIAGNOSE([obsolete],
-[$0: Remove this warning and the call to _LT_SET_OPTION when you put
-the `disable-fast-install' option into LT_INIT's first parameter.])
-])
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
-dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
-
-
-# _LT_WITH_PIC([MODE])
-# --------------------
-# implement the --with-pic flag, and support the `pic-only' and `no-pic'
-# LT_INIT options.
-# MODE is either `yes' or `no'.  If omitted, it defaults to `both'.
-m4_define([_LT_WITH_PIC],
-[AC_ARG_WITH([pic],
-    [AS_HELP_STRING([--with-pic],
-	[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
-    [pic_mode="$withval"],
-    [pic_mode=default])
-
-test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
-
-_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
-])# _LT_WITH_PIC
-
-LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
-LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
-
-# Old name:
-AU_DEFUN([AC_LIBTOOL_PICMODE],
-[_LT_SET_OPTION([LT_INIT], [pic-only])
-AC_DIAGNOSE([obsolete],
-[$0: Remove this warning and the call to _LT_SET_OPTION when you
-put the `pic-only' option into LT_INIT's first parameter.])
-])
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
-
-
-m4_define([_LTDL_MODE], [])
-LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
-		 [m4_define([_LTDL_MODE], [nonrecursive])])
-LT_OPTION_DEFINE([LTDL_INIT], [recursive],
-		 [m4_define([_LTDL_MODE], [recursive])])
-LT_OPTION_DEFINE([LTDL_INIT], [subproject],
-		 [m4_define([_LTDL_MODE], [subproject])])
-
-m4_define([_LTDL_TYPE], [])
-LT_OPTION_DEFINE([LTDL_INIT], [installable],
-		 [m4_define([_LTDL_TYPE], [installable])])
-LT_OPTION_DEFINE([LTDL_INIT], [convenience],
-		 [m4_define([_LTDL_TYPE], [convenience])])
-
-# ltsugar.m4 -- libtool m4 base layer.                         -*-Autoconf-*-
-#
-# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
-# Written by Gary V. Vaughan, 2004
-#
-# This file is free software; the Free Software Foundation gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-
-# serial 6 ltsugar.m4
-
-# This is to help aclocal find these macros, as it can't see m4_define.
-AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
-
-
-# lt_join(SEP, ARG1, [ARG2...])
-# -----------------------------
-# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
-# associated separator.
-# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
-# versions in m4sugar had bugs.
-m4_define([lt_join],
-[m4_if([$#], [1], [],
-       [$#], [2], [[$2]],
-       [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
-m4_define([_lt_join],
-[m4_if([$#$2], [2], [],
-       [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
-
-
-# lt_car(LIST)
-# lt_cdr(LIST)
-# ------------
-# Manipulate m4 lists.
-# These macros are necessary as long as will still need to support
-# Autoconf-2.59 which quotes differently.
-m4_define([lt_car], [[$1]])
-m4_define([lt_cdr],
-[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
-       [$#], 1, [],
-       [m4_dquote(m4_shift($@))])])
-m4_define([lt_unquote], $1)
-
-
-# lt_append(MACRO-NAME, STRING, [SEPARATOR])
-# ------------------------------------------
-# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
-# Note that neither SEPARATOR nor STRING are expanded; they are appended
-# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
-# No SEPARATOR is output if MACRO-NAME was previously undefined (different
-# than defined and empty).
-#
-# This macro is needed until we can rely on Autoconf 2.62, since earlier
-# versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
-m4_define([lt_append],
-[m4_define([$1],
-	   m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
-
-
-
-# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
-# ----------------------------------------------------------
-# Produce a SEP delimited list of all paired combinations of elements of
-# PREFIX-LIST with SUFFIX1 through SUFFIXn.  Each element of the list
-# has the form PREFIXmINFIXSUFFIXn.
-# Needed until we can rely on m4_combine added in Autoconf 2.62.
-m4_define([lt_combine],
-[m4_if(m4_eval([$# > 3]), [1],
-       [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
-[[m4_foreach([_Lt_prefix], [$2],
-	     [m4_foreach([_Lt_suffix],
-		]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
-	[_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
-
-
-# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
-# -----------------------------------------------------------------------
-# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
-# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
-m4_define([lt_if_append_uniq],
-[m4_ifdef([$1],
-	  [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
-		 [lt_append([$1], [$2], [$3])$4],
-		 [$5])],
-	  [lt_append([$1], [$2], [$3])$4])])
-
-
-# lt_dict_add(DICT, KEY, VALUE)
-# -----------------------------
-m4_define([lt_dict_add],
-[m4_define([$1($2)], [$3])])
-
-
-# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
-# --------------------------------------------
-m4_define([lt_dict_add_subkey],
-[m4_define([$1($2:$3)], [$4])])
-
-
-# lt_dict_fetch(DICT, KEY, [SUBKEY])
-# ----------------------------------
-m4_define([lt_dict_fetch],
-[m4_ifval([$3],
-	m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
-    m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
-
-
-# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
-# -----------------------------------------------------------------
-m4_define([lt_if_dict_fetch],
-[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
-	[$5],
-    [$6])])
-
-
-# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
-# --------------------------------------------------------------
-m4_define([lt_dict_filter],
-[m4_if([$5], [], [],
-  [lt_join(m4_quote(m4_default([$4], [[, ]])),
-           lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
-		      [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
-])
-
-# ltversion.m4 -- version numbers			-*- Autoconf -*-
-#
-#   Copyright (C) 2004 Free Software Foundation, Inc.
-#   Written by Scott James Remnant, 2004
-#
-# This file is free software; the Free Software Foundation gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-
-# Generated from ltversion.in.
-
-# serial 3017 ltversion.m4
-# This file is part of GNU Libtool
-
-m4_define([LT_PACKAGE_VERSION], [2.2.6b])
-m4_define([LT_PACKAGE_REVISION], [1.3017])
-
-AC_DEFUN([LTVERSION_VERSION],
-[macro_version='2.2.6b'
-macro_revision='1.3017'
-_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
-_LT_DECL(, macro_revision, 0)
-])
-
-# lt~obsolete.m4 -- aclocal satisfying obsolete definitions.    -*-Autoconf-*-
-#
-#   Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
-#   Written by Scott James Remnant, 2004.
-#
-# This file is free software; the Free Software Foundation gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-
-# serial 4 lt~obsolete.m4
-
-# These exist entirely to fool aclocal when bootstrapping libtool.
-#
-# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
-# which have later been changed to m4_define as they aren't part of the
-# exported API, or moved to Autoconf or Automake where they belong.
-#
-# The trouble is, aclocal is a bit thick.  It'll see the old AC_DEFUN
-# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
-# using a macro with the same name in our local m4/libtool.m4 it'll
-# pull the old libtool.m4 in (it doesn't see our shiny new m4_define
-# and doesn't know about Autoconf macros at all.)
-#
-# So we provide this file, which has a silly filename so it's always
-# included after everything else.  This provides aclocal with the
-# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
-# because those macros already exist, or will be overwritten later.
-# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 
-#
-# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
-# Yes, that means every name once taken will need to remain here until
-# we give up compatibility with versions before 1.7, at which point
-# we need to keep only those names which we still refer to.
-
-# This is to help aclocal find these macros, as it can't see m4_define.
-AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
-
-m4_ifndef([AC_LIBTOOL_LINKER_OPTION],	[AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
-m4_ifndef([AC_PROG_EGREP],		[AC_DEFUN([AC_PROG_EGREP])])
-m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH],	[AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
-m4_ifndef([_LT_AC_SHELL_INIT],		[AC_DEFUN([_LT_AC_SHELL_INIT])])
-m4_ifndef([_LT_AC_SYS_LIBPATH_AIX],	[AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
-m4_ifndef([_LT_PROG_LTMAIN],		[AC_DEFUN([_LT_PROG_LTMAIN])])
-m4_ifndef([_LT_AC_TAGVAR],		[AC_DEFUN([_LT_AC_TAGVAR])])
-m4_ifndef([AC_LTDL_ENABLE_INSTALL],	[AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
-m4_ifndef([AC_LTDL_PREOPEN],		[AC_DEFUN([AC_LTDL_PREOPEN])])
-m4_ifndef([_LT_AC_SYS_COMPILER],	[AC_DEFUN([_LT_AC_SYS_COMPILER])])
-m4_ifndef([_LT_AC_LOCK],		[AC_DEFUN([_LT_AC_LOCK])])
-m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE],	[AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
-m4_ifndef([_LT_AC_TRY_DLOPEN_SELF],	[AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
-m4_ifndef([AC_LIBTOOL_PROG_CC_C_O],	[AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
-m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
-m4_ifndef([AC_LIBTOOL_OBJDIR],		[AC_DEFUN([AC_LIBTOOL_OBJDIR])])
-m4_ifndef([AC_LTDL_OBJDIR],		[AC_DEFUN([AC_LTDL_OBJDIR])])
-m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
-m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP],	[AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
-m4_ifndef([AC_PATH_MAGIC],		[AC_DEFUN([AC_PATH_MAGIC])])
-m4_ifndef([AC_PROG_LD_GNU],		[AC_DEFUN([AC_PROG_LD_GNU])])
-m4_ifndef([AC_PROG_LD_RELOAD_FLAG],	[AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
-m4_ifndef([AC_DEPLIBS_CHECK_METHOD],	[AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
-m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
-m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
-m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
-m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS],	[AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
-m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP],	[AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
-m4_ifndef([LT_AC_PROG_EGREP],		[AC_DEFUN([LT_AC_PROG_EGREP])])
-m4_ifndef([LT_AC_PROG_SED],		[AC_DEFUN([LT_AC_PROG_SED])])
-m4_ifndef([_LT_CC_BASENAME],		[AC_DEFUN([_LT_CC_BASENAME])])
-m4_ifndef([_LT_COMPILER_BOILERPLATE],	[AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
-m4_ifndef([_LT_LINKER_BOILERPLATE],	[AC_DEFUN([_LT_LINKER_BOILERPLATE])])
-m4_ifndef([_AC_PROG_LIBTOOL],		[AC_DEFUN([_AC_PROG_LIBTOOL])])
-m4_ifndef([AC_LIBTOOL_SETUP],		[AC_DEFUN([AC_LIBTOOL_SETUP])])
-m4_ifndef([_LT_AC_CHECK_DLFCN],		[AC_DEFUN([_LT_AC_CHECK_DLFCN])])
-m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER],	[AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
-m4_ifndef([_LT_AC_TAGCONFIG],		[AC_DEFUN([_LT_AC_TAGCONFIG])])
-m4_ifndef([AC_DISABLE_FAST_INSTALL],	[AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
-m4_ifndef([_LT_AC_LANG_CXX],		[AC_DEFUN([_LT_AC_LANG_CXX])])
-m4_ifndef([_LT_AC_LANG_F77],		[AC_DEFUN([_LT_AC_LANG_F77])])
-m4_ifndef([_LT_AC_LANG_GCJ],		[AC_DEFUN([_LT_AC_LANG_GCJ])])
-m4_ifndef([AC_LIBTOOL_RC],		[AC_DEFUN([AC_LIBTOOL_RC])])
-m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
-m4_ifndef([_LT_AC_LANG_C_CONFIG],	[AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
-m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
-m4_ifndef([_LT_AC_LANG_CXX_CONFIG],	[AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
-m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
-m4_ifndef([_LT_AC_LANG_F77_CONFIG],	[AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
-m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
-m4_ifndef([_LT_AC_LANG_GCJ_CONFIG],	[AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
-m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
-m4_ifndef([_LT_AC_LANG_RC_CONFIG],	[AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
-m4_ifndef([AC_LIBTOOL_CONFIG],		[AC_DEFUN([AC_LIBTOOL_CONFIG])])
-m4_ifndef([_LT_AC_FILE_LTDLL_C],	[AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
-
-# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# AM_AUTOMAKE_VERSION(VERSION)
-# ----------------------------
-# Automake X.Y traces this macro to ensure aclocal.m4 has been
-# generated from the m4 files accompanying Automake X.Y.
-# (This private macro should not be called outside this file.)
-AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.11'
-dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
-dnl require some minimum version.  Point them to the right macro.
-m4_if([$1], [1.11.1], [],
-      [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
-])
-
-# _AM_AUTOCONF_VERSION(VERSION)
-# -----------------------------
-# aclocal traces this macro to find the Autoconf version.
-# This is a private macro too.  Using m4_define simplifies
-# the logic in aclocal, which can simply ignore this definition.
-m4_define([_AM_AUTOCONF_VERSION], [])
-
-# AM_SET_CURRENT_AUTOMAKE_VERSION
-# -------------------------------
-# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
-# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
-AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.11.1])dnl
-m4_ifndef([AC_AUTOCONF_VERSION],
-  [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
-
-# AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
-
-# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
-# $ac_aux_dir to `$srcdir/foo'.  In other projects, it is set to
-# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
-#
-# Of course, Automake must honor this variable whenever it calls a
-# tool from the auxiliary directory.  The problem is that $srcdir (and
-# therefore $ac_aux_dir as well) can be either absolute or relative,
-# depending on how configure is run.  This is pretty annoying, since
-# it makes $ac_aux_dir quite unusable in subdirectories: in the top
-# source directory, any form will work fine, but in subdirectories a
-# relative path needs to be adjusted first.
-#
-# $ac_aux_dir/missing
-#    fails when called from a subdirectory if $ac_aux_dir is relative
-# $top_srcdir/$ac_aux_dir/missing
-#    fails if $ac_aux_dir is absolute,
-#    fails when called from a subdirectory in a VPATH build with
-#          a relative $ac_aux_dir
-#
-# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
-# are both prefixed by $srcdir.  In an in-source build this is usually
-# harmless because $srcdir is `.', but things will broke when you
-# start a VPATH build or use an absolute $srcdir.
-#
-# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
-# iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
-#   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
-# and then we would define $MISSING as
-#   MISSING="\${SHELL} $am_aux_dir/missing"
-# This will work as long as MISSING is not called from configure, because
-# unfortunately $(top_srcdir) has no meaning in configure.
-# However there are other variables, like CC, which are often used in
-# configure, and could therefore not use this "fixed" $ac_aux_dir.
-#
-# Another solution, used here, is to always expand $ac_aux_dir to an
-# absolute PATH.  The drawback is that using absolute paths prevent a
-# configured tree to be moved without reconfiguration.
-
-AC_DEFUN([AM_AUX_DIR_EXPAND],
-[dnl Rely on autoconf to set up CDPATH properly.
-AC_PREREQ([2.50])dnl
-# expand $ac_aux_dir to an absolute path
-am_aux_dir=`cd $ac_aux_dir && pwd`
-])
-
-# AM_CONDITIONAL                                            -*- Autoconf -*-
-
-# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 9
-
-# AM_CONDITIONAL(NAME, SHELL-CONDITION)
-# -------------------------------------
-# Define a conditional.
-AC_DEFUN([AM_CONDITIONAL],
-[AC_PREREQ(2.52)dnl
- ifelse([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
-	[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
-AC_SUBST([$1_TRUE])dnl
-AC_SUBST([$1_FALSE])dnl
-_AM_SUBST_NOTMAKE([$1_TRUE])dnl
-_AM_SUBST_NOTMAKE([$1_FALSE])dnl
-m4_define([_AM_COND_VALUE_$1], [$2])dnl
-if $2; then
-  $1_TRUE=
-  $1_FALSE='#'
-else
-  $1_TRUE='#'
-  $1_FALSE=
-fi
-AC_CONFIG_COMMANDS_PRE(
-[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
-  AC_MSG_ERROR([[conditional "$1" was never defined.
-Usually this means the macro was only invoked conditionally.]])
-fi])])
-
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 10
-
-# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
-# written in clear, in which case automake, when reading aclocal.m4,
-# will think it sees a *use*, and therefore will trigger all it's
-# C support machinery.  Also note that it means that autoscan, seeing
-# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
-
-
-# _AM_DEPENDENCIES(NAME)
-# ----------------------
-# See how the compiler implements dependency checking.
-# NAME is "CC", "CXX", "GCJ", or "OBJC".
-# We try a few techniques and use that to set a single cache variable.
-#
-# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
-# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
-# dependency, and given that the user is not expected to run this macro,
-# just rely on AC_PROG_CC.
-AC_DEFUN([_AM_DEPENDENCIES],
-[AC_REQUIRE([AM_SET_DEPDIR])dnl
-AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
-AC_REQUIRE([AM_MAKE_INCLUDE])dnl
-AC_REQUIRE([AM_DEP_TRACK])dnl
-
-ifelse([$1], CC,   [depcc="$CC"   am_compiler_list=],
-       [$1], CXX,  [depcc="$CXX"  am_compiler_list=],
-       [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
-       [$1], UPC,  [depcc="$UPC"  am_compiler_list=],
-       [$1], GCJ,  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
-                   [depcc="$$1"   am_compiler_list=])
-
-AC_CACHE_CHECK([dependency style of $depcc],
-               [am_cv_$1_dependencies_compiler_type],
-[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
-  # We make a subdir and do the tests there.  Otherwise we can end up
-  # making bogus files that we don't know about and never remove.  For
-  # instance it was reported that on HP-UX the gcc test will end up
-  # making a dummy file named `D' -- because `-MD' means `put the output
-  # in D'.
-  mkdir conftest.dir
-  # Copy depcomp to subdir because otherwise we won't find it if we're
-  # using a relative directory.
-  cp "$am_depcomp" conftest.dir
-  cd conftest.dir
-  # We will build objects and dependencies in a subdirectory because
-  # it helps to detect inapplicable dependency modes.  For instance
-  # both Tru64's cc and ICC support -MD to output dependencies as a
-  # side effect of compilation, but ICC will put the dependencies in
-  # the current directory while Tru64 will put them in the object
-  # directory.
-  mkdir sub
-
-  am_cv_$1_dependencies_compiler_type=none
-  if test "$am_compiler_list" = ""; then
-     am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
-  fi
-  am__universal=false
-  m4_case([$1], [CC],
-    [case " $depcc " in #(
-     *\ -arch\ *\ -arch\ *) am__universal=true ;;
-     esac],
-    [CXX],
-    [case " $depcc " in #(
-     *\ -arch\ *\ -arch\ *) am__universal=true ;;
-     esac])
-
-  for depmode in $am_compiler_list; do
-    # Setup a source with many dependencies, because some compilers
-    # like to wrap large dependency lists on column 80 (with \), and
-    # we should not choose a depcomp mode which is confused by this.
-    #
-    # We need to recreate these files for each test, as the compiler may
-    # overwrite some of them when testing with obscure command lines.
-    # This happens at least with the AIX C compiler.
-    : > sub/conftest.c
-    for i in 1 2 3 4 5 6; do
-      echo '#include "conftst'$i'.h"' >> sub/conftest.c
-      # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
-      # Solaris 8's {/usr,}/bin/sh.
-      touch sub/conftst$i.h
-    done
-    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
-    # We check with `-c' and `-o' for the sake of the "dashmstdout"
-    # mode.  It turns out that the SunPro C++ compiler does not properly
-    # handle `-M -o', and we need to detect this.  Also, some Intel
-    # versions had trouble with output in subdirs
-    am__obj=sub/conftest.${OBJEXT-o}
-    am__minus_obj="-o $am__obj"
-    case $depmode in
-    gcc)
-      # This depmode causes a compiler race in universal mode.
-      test "$am__universal" = false || continue
-      ;;
-    nosideeffect)
-      # after this tag, mechanisms are not by side-effect, so they'll
-      # only be used when explicitly requested
-      if test "x$enable_dependency_tracking" = xyes; then
-	continue
-      else
-	break
-      fi
-      ;;
-    msvisualcpp | msvcmsys)
-      # This compiler won't grok `-c -o', but also, the minuso test has
-      # not run yet.  These depmodes are late enough in the game, and
-      # so weak that their functioning should not be impacted.
-      am__obj=conftest.${OBJEXT-o}
-      am__minus_obj=
-      ;;
-    none) break ;;
-    esac
-    if depmode=$depmode \
-       source=sub/conftest.c object=$am__obj \
-       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
-       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
-         >/dev/null 2>conftest.err &&
-       grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
-       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
-       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
-       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
-      # icc doesn't choke on unknown options, it will just issue warnings
-      # or remarks (even with -Werror).  So we grep stderr for any message
-      # that says an option was ignored or not supported.
-      # When given -MP, icc 7.0 and 7.1 complain thusly:
-      #   icc: Command line warning: ignoring option '-M'; no argument required
-      # The diagnosis changed in icc 8.0:
-      #   icc: Command line remark: option '-MP' not supported
-      if (grep 'ignoring option' conftest.err ||
-          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
-        am_cv_$1_dependencies_compiler_type=$depmode
-        break
-      fi
-    fi
-  done
-
-  cd ..
-  rm -rf conftest.dir
-else
-  am_cv_$1_dependencies_compiler_type=none
-fi
-])
-AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
-AM_CONDITIONAL([am__fastdep$1], [
-  test "x$enable_dependency_tracking" != xno \
-  && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
-])
-
-
-# AM_SET_DEPDIR
-# -------------
-# Choose a directory name for dependency files.
-# This macro is AC_REQUIREd in _AM_DEPENDENCIES
-AC_DEFUN([AM_SET_DEPDIR],
-[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
-AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
-])
-
-
-# AM_DEP_TRACK
-# ------------
-AC_DEFUN([AM_DEP_TRACK],
-[AC_ARG_ENABLE(dependency-tracking,
-[  --disable-dependency-tracking  speeds up one-time build
-  --enable-dependency-tracking   do not reject slow dependency extractors])
-if test "x$enable_dependency_tracking" != xno; then
-  am_depcomp="$ac_aux_dir/depcomp"
-  AMDEPBACKSLASH='\'
-fi
-AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
-AC_SUBST([AMDEPBACKSLASH])dnl
-_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
-])
-
-# Generate code to set up dependency tracking.              -*- Autoconf -*-
-
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-#serial 5
-
-# _AM_OUTPUT_DEPENDENCY_COMMANDS
-# ------------------------------
-AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
-[{
-  # Autoconf 2.62 quotes --file arguments for eval, but not when files
-  # are listed without --file.  Let's play safe and only enable the eval
-  # if we detect the quoting.
-  case $CONFIG_FILES in
-  *\'*) eval set x "$CONFIG_FILES" ;;
-  *)   set x $CONFIG_FILES ;;
-  esac
-  shift
-  for mf
-  do
-    # Strip MF so we end up with the name of the file.
-    mf=`echo "$mf" | sed -e 's/:.*$//'`
-    # Check whether this is an Automake generated Makefile or not.
-    # We used to match only the files named `Makefile.in', but
-    # some people rename them; so instead we look at the file content.
-    # Grep'ing the first line is not enough: some people post-process
-    # each Makefile.in and add a new line on top of each file to say so.
-    # Grep'ing the whole file is not good either: AIX grep has a line
-    # limit of 2048, but all sed's we know have understand at least 4000.
-    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
-      dirpart=`AS_DIRNAME("$mf")`
-    else
-      continue
-    fi
-    # Extract the definition of DEPDIR, am__include, and am__quote
-    # from the Makefile without running `make'.
-    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
-    test -z "$DEPDIR" && continue
-    am__include=`sed -n 's/^am__include = //p' < "$mf"`
-    test -z "am__include" && continue
-    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
-    # When using ansi2knr, U may be empty or an underscore; expand it
-    U=`sed -n 's/^U = //p' < "$mf"`
-    # Find all dependency output files, they are included files with
-    # $(DEPDIR) in their names.  We invoke sed twice because it is the
-    # simplest approach to changing $(DEPDIR) to its actual value in the
-    # expansion.
-    for file in `sed -n "
-      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
-	 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
-      # Make sure the directory exists.
-      test -f "$dirpart/$file" && continue
-      fdir=`AS_DIRNAME(["$file"])`
-      AS_MKDIR_P([$dirpart/$fdir])
-      # echo "creating $dirpart/$file"
-      echo '# dummy' > "$dirpart/$file"
-    done
-  done
-}
-])# _AM_OUTPUT_DEPENDENCY_COMMANDS
-
-
-# AM_OUTPUT_DEPENDENCY_COMMANDS
-# -----------------------------
-# This macro should only be invoked once -- use via AC_REQUIRE.
-#
-# This code is only required when automatic dependency tracking
-# is enabled.  FIXME.  This creates each `.P' file that we will
-# need in order to bootstrap the dependency handling code.
-AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
-[AC_CONFIG_COMMANDS([depfiles],
-     [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
-     [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
-])
-
-# Do all the work for Automake.                             -*- Autoconf -*-
-
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 16
-
-# This macro actually does too much.  Some checks are only needed if
-# your package does certain things.  But this isn't really a big deal.
-
-# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
-# AM_INIT_AUTOMAKE([OPTIONS])
-# -----------------------------------------------
-# The call with PACKAGE and VERSION arguments is the old style
-# call (pre autoconf-2.50), which is being phased out.  PACKAGE
-# and VERSION should now be passed to AC_INIT and removed from
-# the call to AM_INIT_AUTOMAKE.
-# We support both call styles for the transition.  After
-# the next Automake release, Autoconf can make the AC_INIT
-# arguments mandatory, and then we can depend on a new Autoconf
-# release and drop the old call support.
-AC_DEFUN([AM_INIT_AUTOMAKE],
-[AC_PREREQ([2.62])dnl
-dnl Autoconf wants to disallow AM_ names.  We explicitly allow
-dnl the ones we care about.
-m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
-AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
-AC_REQUIRE([AC_PROG_INSTALL])dnl
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
-  # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
-  # is not polluted with repeated "-I."
-  AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
-  # test to see if srcdir already configured
-  if test -f $srcdir/config.status; then
-    AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
-  fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
-  if (cygpath --version) >/dev/null 2>/dev/null; then
-    CYGPATH_W='cygpath -w'
-  else
-    CYGPATH_W=echo
-  fi
-fi
-AC_SUBST([CYGPATH_W])
-
-# Define the identity of the package.
-dnl Distinguish between old-style and new-style calls.
-m4_ifval([$2],
-[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
- AC_SUBST([PACKAGE], [$1])dnl
- AC_SUBST([VERSION], [$2])],
-[_AM_SET_OPTIONS([$1])dnl
-dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
-m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
-  [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
- AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
- AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
-
-_AM_IF_OPTION([no-define],,
-[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
- AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
-
-# Some tools Automake needs.
-AC_REQUIRE([AM_SANITY_CHECK])dnl
-AC_REQUIRE([AC_ARG_PROGRAM])dnl
-AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
-AM_MISSING_PROG(AUTOCONF, autoconf)
-AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
-AM_MISSING_PROG(AUTOHEADER, autoheader)
-AM_MISSING_PROG(MAKEINFO, makeinfo)
-AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
-AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
-AC_REQUIRE([AM_PROG_MKDIR_P])dnl
-# We need awk for the "check" target.  The system "awk" is bad on
-# some platforms.
-AC_REQUIRE([AC_PROG_AWK])dnl
-AC_REQUIRE([AC_PROG_MAKE_SET])dnl
-AC_REQUIRE([AM_SET_LEADING_DOT])dnl
-_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
-	      [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
-			     [_AM_PROG_TAR([v7])])])
-_AM_IF_OPTION([no-dependencies],,
-[AC_PROVIDE_IFELSE([AC_PROG_CC],
-		  [_AM_DEPENDENCIES(CC)],
-		  [define([AC_PROG_CC],
-			  defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
-AC_PROVIDE_IFELSE([AC_PROG_CXX],
-		  [_AM_DEPENDENCIES(CXX)],
-		  [define([AC_PROG_CXX],
-			  defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
-AC_PROVIDE_IFELSE([AC_PROG_OBJC],
-		  [_AM_DEPENDENCIES(OBJC)],
-		  [define([AC_PROG_OBJC],
-			  defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
-])
-_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
-dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
-dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This macro
-dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
-AC_CONFIG_COMMANDS_PRE(dnl
-[m4_provide_if([_AM_COMPILER_EXEEXT],
-  [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
-])
-
-dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
-dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
-dnl mangled by Autoconf and run in a shell conditional statement.
-m4_define([_AC_COMPILER_EXEEXT],
-m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
-
-
-# When config.status generates a header, we must update the stamp-h file.
-# This file resides in the same directory as the config header
-# that is generated.  The stamp files are numbered to have different names.
-
-# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
-# loop where config.status creates the headers, so we can generate
-# our stamp files there.
-AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
-[# Compute $1's index in $config_headers.
-_am_arg=$1
-_am_stamp_count=1
-for _am_header in $config_headers :; do
-  case $_am_header in
-    $_am_arg | $_am_arg:* )
-      break ;;
-    * )
-      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
-  esac
-done
-echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
-
-# Copyright (C) 2001, 2003, 2005, 2008  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# AM_PROG_INSTALL_SH
-# ------------------
-# Define $install_sh.
-AC_DEFUN([AM_PROG_INSTALL_SH],
-[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
-if test x"${install_sh}" != xset; then
-  case $am_aux_dir in
-  *\ * | *\	*)
-    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
-  *)
-    install_sh="\${SHELL} $am_aux_dir/install-sh"
-  esac
-fi
-AC_SUBST(install_sh)])
-
-# Copyright (C) 2003, 2005  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 2
-
-# Check whether the underlying file-system supports filenames
-# with a leading dot.  For instance MS-DOS doesn't.
-AC_DEFUN([AM_SET_LEADING_DOT],
-[rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
-  am__leading_dot=.
-else
-  am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-AC_SUBST([am__leading_dot])])
-
-# Add --enable-maintainer-mode option to configure.         -*- Autoconf -*-
-# From Jim Meyering
-
-# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 5
-
-# AM_MAINTAINER_MODE([DEFAULT-MODE])
-# ----------------------------------
-# Control maintainer-specific portions of Makefiles.
-# Default is to disable them, unless `enable' is passed literally.
-# For symmetry, `disable' may be passed as well.  Anyway, the user
-# can override the default with the --enable/--disable switch.
-AC_DEFUN([AM_MAINTAINER_MODE],
-[m4_case(m4_default([$1], [disable]),
-       [enable], [m4_define([am_maintainer_other], [disable])],
-       [disable], [m4_define([am_maintainer_other], [enable])],
-       [m4_define([am_maintainer_other], [enable])
-        m4_warn([syntax], [unexpected argument to AM@&t at _MAINTAINER_MODE: $1])])
-AC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles])
-  dnl maintainer-mode's default is 'disable' unless 'enable' is passed
-  AC_ARG_ENABLE([maintainer-mode],
-[  --][am_maintainer_other][-maintainer-mode  am_maintainer_other make rules and dependencies not useful
-			  (and sometimes confusing) to the casual installer],
-      [USE_MAINTAINER_MODE=$enableval],
-      [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
-  AC_MSG_RESULT([$USE_MAINTAINER_MODE])
-  AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
-  MAINT=$MAINTAINER_MODE_TRUE
-  AC_SUBST([MAINT])dnl
-]
-)
-
-AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
-
-# Check to see how 'make' treats includes.	            -*- Autoconf -*-
-
-# Copyright (C) 2001, 2002, 2003, 2005, 2009  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 4
-
-# AM_MAKE_INCLUDE()
-# -----------------
-# Check to see how make treats includes.
-AC_DEFUN([AM_MAKE_INCLUDE],
-[am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
-	@echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-AC_MSG_CHECKING([for style of include used by $am_make])
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from `make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
-  am__include=include
-  am__quote=
-  _am_result=GNU
-  ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
-   echo '.include "confinc"' > confmf
-   case `$am_make -s -f confmf 2> /dev/null` in #(
-   *the\ am__doit\ target*)
-     am__include=.include
-     am__quote="\""
-     _am_result=BSD
-     ;;
-   esac
-fi
-AC_SUBST([am__include])
-AC_SUBST([am__quote])
-AC_MSG_RESULT([$_am_result])
-rm -f confinc confmf
-])
-
-# Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
-
-# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 6
-
-# AM_MISSING_PROG(NAME, PROGRAM)
-# ------------------------------
-AC_DEFUN([AM_MISSING_PROG],
-[AC_REQUIRE([AM_MISSING_HAS_RUN])
-$1=${$1-"${am_missing_run}$2"}
-AC_SUBST($1)])
-
-
-# AM_MISSING_HAS_RUN
-# ------------------
-# Define MISSING if not defined so far and test if it supports --run.
-# If it does, set am_missing_run to use it, otherwise, to nothing.
-AC_DEFUN([AM_MISSING_HAS_RUN],
-[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
-AC_REQUIRE_AUX_FILE([missing])dnl
-if test x"${MISSING+set}" != xset; then
-  case $am_aux_dir in
-  *\ * | *\	*)
-    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
-  *)
-    MISSING="\${SHELL} $am_aux_dir/missing" ;;
-  esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --run true"; then
-  am_missing_run="$MISSING --run "
-else
-  am_missing_run=
-  AC_MSG_WARN([`missing' script is too old or missing])
-fi
-])
-
-# Copyright (C) 2003, 2004, 2005, 2006  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# AM_PROG_MKDIR_P
-# ---------------
-# Check for `mkdir -p'.
-AC_DEFUN([AM_PROG_MKDIR_P],
-[AC_PREREQ([2.60])dnl
-AC_REQUIRE([AC_PROG_MKDIR_P])dnl
-dnl Automake 1.8 to 1.9.6 used to define mkdir_p.  We now use MKDIR_P,
-dnl while keeping a definition of mkdir_p for backward compatibility.
-dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
-dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
-dnl Makefile.ins that do not define MKDIR_P, so we do our own
-dnl adjustment using top_builddir (which is defined more often than
-dnl MKDIR_P).
-AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
-case $mkdir_p in
-  [[\\/$]]* | ?:[[\\/]]*) ;;
-  */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
-esac
-])
-
-# Helper functions for option handling.                     -*- Autoconf -*-
-
-# Copyright (C) 2001, 2002, 2003, 2005, 2008  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 4
-
-# _AM_MANGLE_OPTION(NAME)
-# -----------------------
-AC_DEFUN([_AM_MANGLE_OPTION],
-[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
-
-# _AM_SET_OPTION(NAME)
-# ------------------------------
-# Set option NAME.  Presently that only means defining a flag for this option.
-AC_DEFUN([_AM_SET_OPTION],
-[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
-
-# _AM_SET_OPTIONS(OPTIONS)
-# ----------------------------------
-# OPTIONS is a space-separated list of Automake options.
-AC_DEFUN([_AM_SET_OPTIONS],
-[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
-
-# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
-# -------------------------------------------
-# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
-AC_DEFUN([_AM_IF_OPTION],
-[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
-
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008, 2009
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# AM_PATH_PYTHON([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
-# ---------------------------------------------------------------------------
-# Adds support for distributing Python modules and packages.  To
-# install modules, copy them to $(pythondir), using the python_PYTHON
-# automake variable.  To install a package with the same name as the
-# automake package, install to $(pkgpythondir), or use the
-# pkgpython_PYTHON automake variable.
-#
-# The variables $(pyexecdir) and $(pkgpyexecdir) are provided as
-# locations to install python extension modules (shared libraries).
-# Another macro is required to find the appropriate flags to compile
-# extension modules.
-#
-# If your package is configured with a different prefix to python,
-# users will have to add the install directory to the PYTHONPATH
-# environment variable, or create a .pth file (see the python
-# documentation for details).
-#
-# If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will
-# cause an error if the version of python installed on the system
-# doesn't meet the requirement.  MINIMUM-VERSION should consist of
-# numbers and dots only.
-AC_DEFUN([AM_PATH_PYTHON],
- [
-  dnl Find a Python interpreter.  Python versions prior to 2.0 are not
-  dnl supported. (2.0 was released on October 16, 2000).
-  m4_define_default([_AM_PYTHON_INTERPRETER_LIST],
-                    [python python2 python3 python3.0 python2.5 python2.4 python2.3 python2.2 dnl
-python2.1 python2.0])
-
-  m4_if([$1],[],[
-    dnl No version check is needed.
-    # Find any Python interpreter.
-    if test -z "$PYTHON"; then
-      AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :)
-    fi
-    am_display_PYTHON=python
-  ], [
-    dnl A version check is needed.
-    if test -n "$PYTHON"; then
-      # If the user set $PYTHON, use it and don't search something else.
-      AC_MSG_CHECKING([whether $PYTHON version >= $1])
-      AM_PYTHON_CHECK_VERSION([$PYTHON], [$1],
-			      [AC_MSG_RESULT(yes)],
-			      [AC_MSG_ERROR(too old)])
-      am_display_PYTHON=$PYTHON
-    else
-      # Otherwise, try each interpreter until we find one that satisfies
-      # VERSION.
-      AC_CACHE_CHECK([for a Python interpreter with version >= $1],
-	[am_cv_pathless_PYTHON],[
-	for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do
-	  test "$am_cv_pathless_PYTHON" = none && break
-	  AM_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [break])
-	done])
-      # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
-      if test "$am_cv_pathless_PYTHON" = none; then
-	PYTHON=:
-      else
-        AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON])
-      fi
-      am_display_PYTHON=$am_cv_pathless_PYTHON
-    fi
-  ])
-
-  if test "$PYTHON" = :; then
-  dnl Run any user-specified action, or abort.
-    m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])])
-  else
-
-  dnl Query Python for its version number.  Getting [:3] seems to be
-  dnl the best way to do this; it's what "site.py" does in the standard
-  dnl library.
-
-  AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version],
-    [am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[[:3]])"`])
-  AC_SUBST([PYTHON_VERSION], [$am_cv_python_version])
-
-  dnl Use the values of $prefix and $exec_prefix for the corresponding
-  dnl values of PYTHON_PREFIX and PYTHON_EXEC_PREFIX.  These are made
-  dnl distinct variables so they can be overridden if need be.  However,
-  dnl general consensus is that you shouldn't need this ability.
-
-  AC_SUBST([PYTHON_PREFIX], ['${prefix}'])
-  AC_SUBST([PYTHON_EXEC_PREFIX], ['${exec_prefix}'])
-
-  dnl At times (like when building shared libraries) you may want
-  dnl to know which OS platform Python thinks this is.
-
-  AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform],
-    [am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`])
-  AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform])
-
-
-  dnl Set up 4 directories:
-
-  dnl pythondir -- where to install python scripts.  This is the
-  dnl   site-packages directory, not the python standard library
-  dnl   directory like in previous automake betas.  This behavior
-  dnl   is more consistent with lispdir.m4 for example.
-  dnl Query distutils for this directory.  distutils does not exist in
-  dnl Python 1.5, so we fall back to the hardcoded directory if it
-  dnl doesn't work.
-  AC_CACHE_CHECK([for $am_display_PYTHON script directory],
-    [am_cv_python_pythondir],
-    [if test "x$prefix" = xNONE
-     then
-       am_py_prefix=$ac_default_prefix
-     else
-       am_py_prefix=$prefix
-     fi
-     am_cv_python_pythondir=`$PYTHON -c "import sys; from distutils import sysconfig; sys.stdout.write(sysconfig.get_python_lib(0,0,prefix='$am_py_prefix'))" 2>/dev/null ||
-     echo "$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages"`
-     case $am_cv_python_pythondir in
-     $am_py_prefix*)
-       am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
-       am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,$PYTHON_PREFIX,"`
-       ;;
-     *)
-       case $am_py_prefix in
-         /usr|/System*) ;;
-         *)
-	  am_cv_python_pythondir=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
-	  ;;
-       esac
-       ;;
-     esac
-    ])
-  AC_SUBST([pythondir], [$am_cv_python_pythondir])
-
-  dnl pkgpythondir -- $PACKAGE directory under pythondir.  Was
-  dnl   PYTHON_SITE_PACKAGE in previous betas, but this naming is
-  dnl   more consistent with the rest of automake.
-
-  AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE])
-
-  dnl pyexecdir -- directory for installing python extension modules
-  dnl   (shared libraries)
-  dnl Query distutils for this directory.  distutils does not exist in
-  dnl Python 1.5, so we fall back to the hardcoded directory if it
-  dnl doesn't work.
-  AC_CACHE_CHECK([for $am_display_PYTHON extension module directory],
-    [am_cv_python_pyexecdir],
-    [if test "x$exec_prefix" = xNONE
-     then
-       am_py_exec_prefix=$am_py_prefix
-     else
-       am_py_exec_prefix=$exec_prefix
-     fi
-     am_cv_python_pyexecdir=`$PYTHON -c "import sys; from distutils import sysconfig; sys.stdout.write(sysconfig.get_python_lib(1,0,prefix='$am_py_exec_prefix'))" 2>/dev/null ||
-     echo "$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages"`
-     case $am_cv_python_pyexecdir in
-     $am_py_exec_prefix*)
-       am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
-       am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,$PYTHON_EXEC_PREFIX,"`
-       ;;
-     *)
-       case $am_py_exec_prefix in
-         /usr|/System*) ;;
-         *)
-	   am_cv_python_pyexecdir=$PYTHON_EXEC_PREFIX/lib/python$PYTHON_VERSION/site-packages
-	   ;;
-       esac
-       ;;
-     esac
-    ])
-  AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir])
-
-  dnl pkgpyexecdir -- $(pyexecdir)/$(PACKAGE)
-
-  AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE])
-
-  dnl Run any user-specified action.
-  $2
-  fi
-
-])
-
-
-# AM_PYTHON_CHECK_VERSION(PROG, VERSION, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
-# ---------------------------------------------------------------------------
-# Run ACTION-IF-TRUE if the Python interpreter PROG has version >= VERSION.
-# Run ACTION-IF-FALSE otherwise.
-# This test uses sys.hexversion instead of the string equivalent (first
-# word of sys.version), in order to cope with versions such as 2.2c1.
-# This supports Python 2.0 or higher. (2.0 was released on October 16, 2000).
-AC_DEFUN([AM_PYTHON_CHECK_VERSION],
- [prog="import sys
-# split strings by '.' and convert to numeric.  Append some zeros
-# because we need at least 4 digits for the hex conversion.
-# map returns an iterator in Python 3.0 and a list in 2.x
-minver = list(map(int, '$2'.split('.'))) + [[0, 0, 0]]
-minverhex = 0
-# xrange is not present in Python 3.0 and range returns an iterator
-for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[[i]]
-sys.exit(sys.hexversion < minverhex)"
-  AS_IF([AM_RUN_LOG([$1 -c "$prog"])], [$3], [$4])])
-
-# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# AM_RUN_LOG(COMMAND)
-# -------------------
-# Run COMMAND, save the exit status in ac_status, and log it.
-# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
-AC_DEFUN([AM_RUN_LOG],
-[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
-   ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
-   ac_status=$?
-   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
-   (exit $ac_status); }])
-
-# Check to make sure that the build environment is sane.    -*- Autoconf -*-
-
-# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 5
-
-# AM_SANITY_CHECK
-# ---------------
-AC_DEFUN([AM_SANITY_CHECK],
-[AC_MSG_CHECKING([whether build environment is sane])
-# Just in case
-sleep 1
-echo timestamp > conftest.file
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name.  Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
-  *[[\\\"\#\$\&\'\`$am_lf]]*)
-    AC_MSG_ERROR([unsafe absolute working directory name]);;
-esac
-case $srcdir in
-  *[[\\\"\#\$\&\'\`$am_lf\ \	]]*)
-    AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
-esac
-
-# Do `set' in a subshell so we don't clobber the current shell's
-# arguments.  Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
-   set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
-   if test "$[*]" = "X"; then
-      # -L didn't work.
-      set X `ls -t "$srcdir/configure" conftest.file`
-   fi
-   rm -f conftest.file
-   if test "$[*]" != "X $srcdir/configure conftest.file" \
-      && test "$[*]" != "X conftest.file $srcdir/configure"; then
-
-      # If neither matched, then we have a broken ls.  This can happen
-      # if, for instance, CONFIG_SHELL is bash and it inherits a
-      # broken ls alias from the environment.  This has actually
-      # happened.  Such a system could not be considered "sane".
-      AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
-alias in your environment])
-   fi
-
-   test "$[2]" = conftest.file
-   )
-then
-   # Ok.
-   :
-else
-   AC_MSG_ERROR([newly created file is older than distributed files!
-Check your system clock])
-fi
-AC_MSG_RESULT(yes)])
-
-# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# AM_PROG_INSTALL_STRIP
-# ---------------------
-# One issue with vendor `install' (even GNU) is that you can't
-# specify the program used to strip binaries.  This is especially
-# annoying in cross-compiling environments, where the build's strip
-# is unlikely to handle the host's binaries.
-# Fortunately install-sh will honor a STRIPPROG variable, so we
-# always use install-sh in `make install-strip', and initialize
-# STRIPPROG with the value of the STRIP variable (set by the user).
-AC_DEFUN([AM_PROG_INSTALL_STRIP],
-[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
-# Installed binaries are usually stripped using `strip' when the user
-# run `make install-strip'.  However `strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the `STRIP' environment variable to overrule this program.
-dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
-if test "$cross_compiling" != no; then
-  AC_CHECK_TOOL([STRIP], [strip], :)
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-AC_SUBST([INSTALL_STRIP_PROGRAM])])
-
-# Copyright (C) 2006, 2008  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 2
-
-# _AM_SUBST_NOTMAKE(VARIABLE)
-# ---------------------------
-# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
-# This macro is traced by Automake.
-AC_DEFUN([_AM_SUBST_NOTMAKE])
-
-# AM_SUBST_NOTMAKE(VARIABLE)
-# ---------------------------
-# Public sister of _AM_SUBST_NOTMAKE.
-AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
-
-# Check how to create a tarball.                            -*- Autoconf -*-
-
-# Copyright (C) 2004, 2005  Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 2
-
-# _AM_PROG_TAR(FORMAT)
-# --------------------
-# Check how to create a tarball in format FORMAT.
-# FORMAT should be one of `v7', `ustar', or `pax'.
-#
-# Substitute a variable $(am__tar) that is a command
-# writing to stdout a FORMAT-tarball containing the directory
-# $tardir.
-#     tardir=directory && $(am__tar) > result.tar
-#
-# Substitute a variable $(am__untar) that extract such
-# a tarball read from stdin.
-#     $(am__untar) < result.tar
-AC_DEFUN([_AM_PROG_TAR],
-[# Always define AMTAR for backward compatibility.
-AM_MISSING_PROG([AMTAR], [tar])
-m4_if([$1], [v7],
-     [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
-     [m4_case([$1], [ustar],, [pax],,
-              [m4_fatal([Unknown tar format])])
-AC_MSG_CHECKING([how to create a $1 tar archive])
-# Loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
-_am_tools=${am_cv_prog_tar_$1-$_am_tools}
-# Do not fold the above two line into one, because Tru64 sh and
-# Solaris sh will not grok spaces in the rhs of `-'.
-for _am_tool in $_am_tools
-do
-  case $_am_tool in
-  gnutar)
-    for _am_tar in tar gnutar gtar;
-    do
-      AM_RUN_LOG([$_am_tar --version]) && break
-    done
-    am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
-    am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
-    am__untar="$_am_tar -xf -"
-    ;;
-  plaintar)
-    # Must skip GNU tar: if it does not support --format= it doesn't create
-    # ustar tarball either.
-    (tar --version) >/dev/null 2>&1 && continue
-    am__tar='tar chf - "$$tardir"'
-    am__tar_='tar chf - "$tardir"'
-    am__untar='tar xf -'
-    ;;
-  pax)
-    am__tar='pax -L -x $1 -w "$$tardir"'
-    am__tar_='pax -L -x $1 -w "$tardir"'
-    am__untar='pax -r'
-    ;;
-  cpio)
-    am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
-    am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
-    am__untar='cpio -i -H $1 -d'
-    ;;
-  none)
-    am__tar=false
-    am__tar_=false
-    am__untar=false
-    ;;
-  esac
-
-  # If the value was cached, stop now.  We just wanted to have am__tar
-  # and am__untar set.
-  test -n "${am_cv_prog_tar_$1}" && break
-
-  # tar/untar a dummy directory, and stop if the command works
-  rm -rf conftest.dir
-  mkdir conftest.dir
-  echo GrepMe > conftest.dir/file
-  AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
-  rm -rf conftest.dir
-  if test -s conftest.tar; then
-    AM_RUN_LOG([$am__untar <conftest.tar])
-    grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
-  fi
-done
-rm -rf conftest.dir
-
-AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
-AC_MSG_RESULT([$am_cv_prog_tar_$1])])
-AC_SUBST([am__tar])
-AC_SUBST([am__untar])
-]) # _AM_PROG_TAR
-
-m4_include([config/cs_bft.m4])
-m4_include([config/cs_blas.m4])
-m4_include([config/cs_config_info.m4])
-m4_include([config/cs_fortran.m4])
-m4_include([config/cs_fvm.m4])
-m4_include([config/cs_libxml2.m4])
-m4_include([config/cs_mei.m4])
-m4_include([config/cs_mpi.m4])
-m4_include([config/cs_syrthes.m4])
-m4_include([config/gettext.m4])
-m4_include([config/iconv.m4])
-m4_include([config/lib-ld.m4])
-m4_include([config/lib-link.m4])
-m4_include([config/lib-prefix.m4])
-m4_include([config/nls.m4])
-m4_include([config/po.m4])
-m4_include([config/progtest.m4])
diff --git a/bin/cs_case.py b/bin/cs_case.py
index 0dc0a2d..10c46cb 100644
--- a/bin/cs_case.py
+++ b/bin/cs_case.py
@@ -530,17 +530,12 @@ class case:
 
     #---------------------------------------------------------------------------
 
-    def copy_result(self, name):
+    def copy_result(self, src):
         """
         Retrieve result from the execution directory
         """
 
-        if os.path.isabs(name):
-            src = name
-        else:
-            src = os.path.join(self.exec_dir, name)
-
-        dest = os.path.join(self.result_dir, os.path.basename(name))
+        dest = os.path.join(self.result_dir, os.path.basename(src))
 
         if (self.results_suffix != None):
             dest += '.' + self.results_suffix
@@ -574,7 +569,7 @@ class case:
                 s_args = d.solver_args(app_id=app_id)
                 if len(cmd) > 0:
                     cmd += ' : '
-                cmd += '-n ' + str(d.n_procs) + ' -cwd ' + s_args[0] \
+                cmd += '-n ' + str(d.n_procs) + ' -wdir ' + s_args[0] \
                     + ' ' + s_args[1] + s_args[2]
                 app_id += 1
 
@@ -582,7 +577,7 @@ class case:
             s_args = d.solver_args(app_id=app_id)
             if len(cmd) > 0:
                 cmd += ' : '
-            cmd += '-n ' + str(d.n_procs) + ' -cwd ' + s_args[0] \
+            cmd += '-n ' + str(d.n_procs) + ' -wdir ' + s_args[0] \
                 + ' ' + s_args[1] + s_args[2]
             app_id += 1
 
@@ -605,14 +600,14 @@ class case:
         for d in self.syr_domains:
             if d.coupling_mode == 'MPI':
                 s_args = d.solver_args(app_id=app_id)
-                cmd = '-n ' + str(d.n_procs) + ' -cwd ' + s_args[0] \
+                cmd = '-n ' + str(d.n_procs) + ' -wdir ' + s_args[0] \
                     + ' ' + s_args[1] + s_args[2] + '\n'
                 e.write(cmd)
                 app_id += 1
 
         for d in self.domains:
             s_args = d.solver_args(app_id=app_id)
-            cmd = '-n ' + str(d.n_procs) + ' -cwd ' + s_args[0] \
+            cmd = '-n ' + str(d.n_procs) + ' -wdir ' + s_args[0] \
                 + ' ' + s_args[1] + s_args[2] + '\n'
             e.write(cmd)
             app_id += 1
@@ -837,6 +832,19 @@ class case:
 
         s.write('#!/bin/sh\n\n')
 
+        # Add detection and handling of SALOME YACS module if run from
+        # this environment.
+
+        yacs_test = \
+"""
+# Detect and handle running under SALOME YACS module.
+YACS_ARG=
+if test "$SALOME_CONTAINERNAME" != "" -a "$CFDRUN_ROOT_DIR" != "" ; then
+  YACS_ARG="--yacs-module=${CFDRUN_ROOT_DIR}"/lib/salome/libCFD_RunExelib.so
+fi
+"""
+        s.write(yacs_test + '\n')
+
         # Add MPI directories to PATH if in nonstandard path
 
         s.write('# Export paths here if necessary or recommended.\n')
@@ -851,11 +859,11 @@ class case:
 
         if mpi_env.gen_hostsfile != None:
             s.write('# Generate hostsfile.\n')
-            s.write(mpi_env.gen_hostsfile + '|| exit $?\n\n')
+            s.write(mpi_env.gen_hostsfile + ' || exit $?\n\n')
 
         if n_procs > 1 and mpi_env.mpiboot != None:
             s.write('# Boot MPI daemons.\n')
-            s.write(mpi_env.mpiboot + '|| exit $?\n\n')
+            s.write(mpi_env.mpiboot + ' || exit $?\n\n')
 
         # Start assembling command
 
@@ -882,11 +890,11 @@ class case:
             if len(self.syr_domains) == 0:
 
                 s_args = self.domains[0].solver_args()
-                s.write('cd ' + s_args[0] + '\n\n')
 
+                s.write('cd ' + s_args[0] + '\n\n')
                 s.write('# Run solver.\n')
-
-                s.write(mpi_cmd + s_args[1] + mpi_cmd_args + s_args[2] + ' $@\n')
+                s.write(mpi_cmd + s_args[1] + mpi_cmd_args + s_args[2]
+                        + ' $YACS_ARGS' + ' $@\n')
 
             else: # coupling through sockets
 
@@ -948,7 +956,7 @@ class case:
 
         if n_procs > 1 and mpi_env.mpihalt != None:
             s.write('\n# Halt MPI daemons.\n')
-            s.write(mpi_env.mpihalt + '\n')
+            s.write(mpi_env.mpihalt + '\n\n')
 
         if mpi_env.del_hostsfile != None:
             s.write('# Remove hostsfile.\n')
@@ -1206,6 +1214,9 @@ class case:
         Run solver proper.
         """
 
+        if not self.exec_solver:
+            return 0
+
         if suffix != None:
             self.suffix = suffix
 
@@ -1229,12 +1240,10 @@ class case:
 
         # Maximum remaining time for PBS or similar batch system.
 
-        if self.exec_solver:
-
-            b = cs_exec_environment.batch_info()
-            max_time = b.get_remaining_time()
-            if max_time != None:
-                os.putenv('CS_MAXTIME', max_time)
+        b = cs_exec_environment.batch_info()
+        max_time = b.get_remaining_time()
+        if max_time != None:
+            os.putenv('CS_MAXTIME', max_time)
 
         # Now run the calculation
 
@@ -1296,7 +1305,7 @@ class case:
 
         os.chdir(self.exec_dir)
 
-        self.update_scripts_tmp(('failed', 'finished'), 'saving')
+        self.update_scripts_tmp(('ready', 'failed', 'finished'), 'saving')
 
         # Now save results
 
@@ -1322,7 +1331,7 @@ class case:
 
         self.summary_finalize()
 
-        self.copy_result('summary')
+        self.copy_result(os.path.join(self.exec_dir, 'summary'))
 
         # Remove the Salome temporary file
 
@@ -1356,7 +1365,7 @@ class case:
                 retcode = self.prepare_data(n_procs,
                                             hosts_list,
                                             mpi_environment)
-            if run_solver == True and run_solver == True:
+            if run_solver == True:
                 self.run_solver()
 
             if save_results == True:
diff --git a/bin/cs_case_domain.py b/bin/cs_case_domain.py
index 327d1a4..6d63da7 100644
--- a/bin/cs_case_domain.py
+++ b/bin/cs_case_domain.py
@@ -747,11 +747,12 @@ class domain(base_domain):
             self.copy_data_file(self.thermochemistry_data,
                                 'dp_thch',
                                 'thermochemistry')
-            self.copy_data_file(os.path.join(cs_config.dirs.pkgdatadir,
-                                             'data',
-                                             'thch',
-                                             'JANAF'),
-                                'JANAF')
+            if not os.path.isfile('JANAF'):
+                self.copy_data_file(os.path.join(cs_config.dirs.pkgdatadir,
+                                                 'data',
+                                                 'thch',
+                                                 'JANAF'),
+                                    'JANAF')
 
         if self.meteo_data != None:
             self.copy_data_file(self.meteo_data,
@@ -1034,7 +1035,7 @@ class domain(base_domain):
                 if f in dir_files:
                     user_files.append(f)
             if len(user_files) > 0:
-                self.copy_results_to_dir(restart_files, 'RES_USER')
+                self.copy_results_to_dir(user_files, 'RES_USER')
 
         # Parameter or similar data files
 
@@ -1224,7 +1225,6 @@ class syrthes_domain(base_domain):
 
             # Copy source files to execution directory
 
-
             if (self.exec_dir != self.result_dir):
                 exec_src = os.path.join(self.exec_dir, 'src_syrthes')
                 os.mkdir(exec_src)
@@ -1279,15 +1279,15 @@ class syrthes_domain(base_domain):
 
         if by_suffix == True:
             self.result_dir = os.path.join(self.case_dir, 'RESU', 'RESU_SYR')
-            self.result_suffix = name
+            self.result_dir += '.' + name
 
         else:
             self.result_dir = os.path.join(self.case_dir,
                                            'RESU',
                                            name,
                                            'RESU_SYR')
-            if (self.tag != None):
-                self.result_dir += '.' + self.tag
+        if (self.tag != None):
+            self.result_dir += '.' + self.tag
 
         if not os.path.isdir(self.result_dir):
             os.makedirs(self.result_dir)
diff --git a/bin/cs_check_mesh.py b/bin/cs_check_mesh.py
index b3471c1..e5d0fdd 100644
--- a/bin/cs_check_mesh.py
+++ b/bin/cs_check_mesh.py
@@ -65,6 +65,13 @@ def run_check(opts):
     cur_dir = os.getcwd()
 
     cmd = os.path.join(cs_config.dirs.ecs_bindir, 'cs_preprocess')
+
+    for o in ('-h', '--help'):
+        if o in opts:
+            cmd = cmd + " " + str(o)
+            retval = run_command(cmd)
+            return retval
+
     for o in opts:
         cmd = cmd + " " + str(o)
     cmd = cmd + " --ensight --case check_mesh"
diff --git a/bin/cs_exec_environment.py b/bin/cs_exec_environment.py
index e748be6..c70da0c 100644
--- a/bin/cs_exec_environment.py
+++ b/bin/cs_exec_environment.py
@@ -77,20 +77,21 @@ def run_command(cmd, echo = False, stdout = sys.stdout, stderr = sys.stderr):
     if have_subprocess == True:
         p = subprocess.Popen(cmd,
                              shell=True,
-                             stdout=subprocess.PIPE,
-                             stderr=subprocess.PIPE)
-        output = p.communicate()
+                             stdout=stdout,
+                             stderr=stderr)
+        p.communicate()
         returncode = p.returncode
 
     else:
         p = popen2.Popen3(cmd, capturestderr=True)
         returncode = p.wait()
         output = (p.fromchild.read(), p.childerr.read())
-
-    if len(output[0]) > 0:
-        stdout.write(output[0])
-    if len(output[1]) > 0:
-        stderr.write(output[1])
+        if len(output[0]) > 0:
+            stdout.write(output[0])
+        if len(output[1]) > 0:
+            stderr.write(output[1])
+        p.fromchild.close()
+        p.childerr.close()
 
     return returncode
 
@@ -223,10 +224,20 @@ class resource_info(batch_info):
                 self.n_nodes = int(s)
 
         if self.manager == None and self.batch_type == 'LSF':
-            s = os.getenv('LSB_HOSTS')
             self.manager = 'LSF'
+            s = os.getenv('LSB_MCPU_HOSTS')
             if s != None:
-                self.hosts_list = s.split(' ')
+                mcpu_list = s.split(' ')
+                self.hosts_list = []
+                for i in range(len(mcpu_list)/2):
+                    host = mcpu_list[i*2]
+                    count = int(mcpu_list[i*2 + 1])
+                    for j in range(count):
+                        self.hosts_list.append(host)
+            else:
+                s = os.getenv('LSB_HOSTS')
+                if s != None:
+                    self.hosts_list = s.split(' ')
 
         if self.manager == None and self.batch_type == 'LOADL':
             s = os.getenv('LOADL_PROCESSOR_LIST')
@@ -358,7 +369,7 @@ MPI_MPMD_execve     = (1<<3)
 
 class mpi_environment:
 
-    def __init__(self, resource_info=None):
+    def __init__(self, resource_info=None, wdir = None):
         """
         Returns MPI environment info.
         """
@@ -403,25 +414,63 @@ class mpi_environment:
         if len(mpi_lib.bindir) > 0:
             p.insert(0, mpi_lib.bindir)
 
-        init_method(p, resource_info)
+        init_method(p, resource_info, wdir)
 
     #---------------------------------------------------------------------------
 
-    def __init_mpich2__(self, p, resource_info=None):
+    def __init_mpich2__(self, p, resource_info=None, wdir = None):
 
         """
         Initialize for MPICH2 environment.
+
+        MPICH2 allows for 4 different process managers, all or some
+        of which may be built depending on installation options:
+
+        - HYDRA is the default starting with MPICH2-1.3, and is available
+          in MPICH2-1.2. It natively uses existing daemons on the system
+          such as ssh, SLURM, PBS, etc.
+
+        - MPD is the traditional process manager, which consists of a
+          ring of daemons. A hostsfile may be defined to start this
+          ring (a machinefile may still be used for mpiexec for
+          finer control, though we do not use it here).
+          We try to test if such a ring is already running, and
+          start and stop it if this is not the case.
+
+        - spmd may be used both on Windows and Linux. It consists
+          of independent daemons, so if a hostsfile is used, it
+          must be passed to mpiexec (we do not attempt to start
+          or stop the daemons here if this manager is used).
+
+        - gforker is a simple manager that creates all processes on
+          a single machine (the equivalent seem possible with HYDRA
+          using "mpiexec -bootstrap fork")
         """
 
         # Determine base executable paths
 
+        # Also try to determine if mpiexec is that of MPD or of another
+        # process manager, using the knowledge that MPD's mpiexec
+        # is a Python script, while other MPICH2 mpiexec's are binary.
+        # We could have a false positive if another wrapper is used,
+        # but we still need to find mpdboot.
+
         launcher_names = ['mpiexec', 'mpirun']
+        mpd_setup = False
 
         for name in launcher_names:
-            for dir in p:
-                absname = os.path.join(dir, name)
+            for d in p:
+                absname = os.path.join(d, name)
                 if os.path.isfile(absname):
-                    if dir == mpi_lib.bindir:
+                    # Determine if the launcher is a Python script
+                    f = open(absname, 'r')
+                    if f.read(2) == '#!':
+                        l = f.readline()
+                        if l.find('python') > 0:
+                            mpd_setup = True
+                    f.close()
+                    # Set launcher name
+                    if d == mpi_lib.bindir:
                         self.mpiexec = absname
                     else:
                         self.mpiexec = name
@@ -429,22 +478,28 @@ class mpi_environment:
             if self.mpiexec != None:
                 break
 
-        for dir in p:
-            if os.path.isfile(os.path.join(dir, 'mpdboot')):
-                if dir == mpi_lib.bindir:
-                    self.mpiboot = os.path.join(dir, 'mpdboot')
-                    self.mpihalt = os.path.join(dir, 'mpdallexit')
-                else:
-                    self.mpiboot = 'mpdboot'
-                    self.mpihalt = 'mpdallexit'
-                break
+        # If we are using a root MPD, no need for setup
 
-        # Note that the self.mpiboot and self.mpihalt commands may be
-        # too simplistic in certain cases. For example, it would be
-        # interesting to run mpdringtest first, and depending on its
-        # exit code (0 if ring is up, 255 if not up), run mpdboot.
-        # The same, mpdlistjobs could be run before mpdallexit to ensure
-        # that we do not kill an mpdring if another job is running.
+        s = os.getenv('MPD_USE_ROOT_MPD')
+        if s != None and int(s) != 0:
+            mpd_setup = False
+
+        # If a setup seems necessary, check paths
+
+        if mpd_setup:
+            for d in p:
+                if os.path.isfile(os.path.join(d, 'mpdboot')):
+                    if d == mpi_lib.bindir:
+                        self.mpiboot = os.path.join(d, 'mpdboot')
+                        self.mpihalt = os.path.join(d, 'mpdallexit')
+                        mpdtrace = os.path.join(d, 'mpdtrace')
+                        mpdlistjobs = os.path.join(d, 'mpdlistjobs')
+                    else:
+                        self.mpiboot = 'mpdboot'
+                        self.mpihalt = 'mpdallexit'
+                        mpdtrace = 'mpdtrace'
+                        mpdlistjobs = 'mpdlistjobs'
+                break
 
         # Determine processor count and MPMD handling
 
@@ -473,16 +528,32 @@ class mpi_environment:
             elif resource_info.manager == 'PBS':
                 # Convert PBS to MPD format (based on MPICH2 documentation)
                 # before MPI boot.
-                self.gen_hostsfile = 'sort $PBS_NODEFILE | uniq -C ' \
-                    + '| awk \'{ printf("%s:%s", $2, $1); }\' > ./mpd.nodes'
-                self.del_hostsfile = 'rm -f ./mpd.nodes'
                 if self.mpiboot != None:
-                    self.mpiboot = pbs_to_mpd \
-                        + self.mpiboot + ' --file ./mpd.nodes\n'
+                    self.gen_hostsfile = 'sort $PBS_NODEFILE | uniq -C ' \
+                        + '| awk \'{ printf("%s:%s", $2, $1); }\' > ./mpd.nodes'
+                    self.del_hostsfile = 'rm -f ./mpd.nodes'
+                    self.mpiboot += ' --file ./mpd.nodes'
             else:
-                hostsfile = resource_info.get_hosts_file(self)
-                if hostsfile != None and self.mpiboot != None:
-                    self.mpiboot += ' --file ' + hostsfile
+                hostsfile = resource_info.get_hosts_file(wdir)
+                if hostsfile != None:
+                    if self.mpiboot != None:
+                        self.mpiboot += ' --file ' + hostsfile
+                    else:
+                        self.mpiexec += ' --machinefile ' + hostsfile
+
+        # Finalize mpiboot and mpihalt commands.
+        # We use 'mpdtrace' to determine if a ring is already running,
+        # and mpdlistjobs to determine if other jobs are still running.
+        # This means that a hostsfile will be ignored if an MPD ring
+        # is already running, but will avoid killing other running jobs.
+
+        if self.mpiboot != None:
+            self.mpiboot = \
+                mpdtrace + ' > /dev/null 2>&1\n' \
+                + 'if test $? != 0 ; then ' + self.mpiboot + ' ; fi'
+            self.mpihalt = \
+                'listjobs = `' + mpdlistjobs + ' | wc -l`\n' \
+                + 'if test $listjobs = 0 ; then ; ' + self.mpihalt + ' ; fi'
 
         # Info commands
 
@@ -490,7 +561,7 @@ class mpi_environment:
 
     #---------------------------------------------------------------------------
 
-    def __init_mpich1__(self, p, resource_info=None):
+    def __init_mpich1__(self, p, resource_info=None, wdir = None):
 
         """
         Initialize for MPICH1 environment.
@@ -504,10 +575,10 @@ class mpi_environment:
                           'mpirun']
 
         for name in launcher_names:
-            for dir in p:
-                absname = os.path.join(dir, name)
+            for d in p:
+                absname = os.path.join(d, name)
                 if os.path.isfile(absname):
-                    if dir == mpi_lib.bindir:
+                    if d == mpi_lib.bindir:
                         self.mpiexec = absname
                     else:
                         self.mpiexec = name
@@ -530,7 +601,7 @@ class mpi_environment:
         # Resource manager info
 
         if resource_info != None:
-            hostsfile = resource_info.get_hosts_file(self)
+            hostsfile = resource_info.get_hosts_file(wdir)
             if hostsfile != None:
                 self.mpiexec += ' -machinefile ' + hostsfile
 
@@ -540,7 +611,7 @@ class mpi_environment:
 
     #---------------------------------------------------------------------------
 
-    def __init_openmpi__(self, p, resource_info=None):
+    def __init_openmpi__(self, p, resource_info=None, wdir = None):
         """
         Initialize for OpenMPI environment.
         """
@@ -551,10 +622,10 @@ class mpi_environment:
                           'mpiexec', 'mpirun']
 
         for name in launcher_names:
-            for dir in p:
-                absname = os.path.join(dir, name)
+            for d in p:
+                absname = os.path.join(d, name)
                 if os.path.isfile(absname):
-                    if dir == mpi_lib.bindir:
+                    if d == mpi_lib.bindir:
                         self.mpiexec = absname
                     else:
                         self.mpiexec = name
@@ -580,7 +651,7 @@ class mpi_environment:
 
         if resource_info != None:
             if not resource_info.manager in ['SLURM', 'PBS']:
-                hostsfile = resource_info.get_hosts_file()
+                hostsfile = resource_info.get_hosts_file(wdir)
                 if hostsfile != None:
                     self.mpiexec += ' --machinefile ' + hostsfile
 
@@ -590,7 +661,7 @@ class mpi_environment:
 
     #---------------------------------------------------------------------------
 
-    def __init_lam__(self, p, resource_info=None):
+    def __init_lam__(self, p, resource_info=None, wdir = None):
         """
         Initialize for LAM/MPI environment.
         """
@@ -600,10 +671,10 @@ class mpi_environment:
         launcher_names = ['mpiexec.lam', 'mpirun.lam', 'mpiexec', 'mpirun']
 
         for name in launcher_names:
-            for dir in p:
-                absname = os.path.join(dir, name)
+            for d in p:
+                absname = os.path.join(d, name)
                 if os.path.isfile(absname):
-                    if dir == mpi_lib.bindir:
+                    if d == mpi_lib.bindir:
                         self.mpiexec = absname
                     else:
                         self.mpiexec = name
@@ -611,11 +682,11 @@ class mpi_environment:
             if self.mpiexec != None:
                 break
 
-        for dir in p:
-            if os.path.isfile(os.path.join(dir, 'lamboot')):
-                if dir == mpi_lib.bindir:
-                    self.mpiboot = os.path.join(dir, 'lamboot')
-                    self.mpihalt = os.path.join(dir, 'lamhalt')
+        for d in p:
+            if os.path.isfile(os.path.join(d, 'lamboot')):
+                if d == mpi_lib.bindir:
+                    self.mpiboot = os.path.join(d, 'lamboot')
+                    self.mpihalt = os.path.join(d, 'lamhalt')
                 else:
                     self.mpiboot = 'lamboot'
                     self.mpihalt = 'lamhalt'
@@ -641,18 +712,23 @@ class mpi_environment:
         # Resource manager info
 
         if resource_info != None:
-            hostsfile = resource_info.get_hosts_file(self)
+            hostsfile = resource_info.get_hosts_file(wdir)
             if hostsfile != None and self.mpiboot != None:
                 self.mpiboot += ' ' + hostsfile
                 self.mpihalt += ' ' + hostsfile
 
+        # Finalize mpiboot and mpihalt commands
+
+        if self.mpiboot != None:
+            self.mpiboot += '|| exit $?'
+
         # Info commands
 
         self.info_cmds = ['laminfo -all']
 
     #---------------------------------------------------------------------------
 
-    def __init_bgl__(self, p, resource_info=None):
+    def __init_bgl__(self, p, resource_info=None, wdir = None):
 
         """
         Initialize for Blue Gene/L environment.
@@ -676,7 +752,7 @@ class mpi_environment:
 
     #---------------------------------------------------------------------------
 
-    def __init_bgp__(self, p, resource_info=None):
+    def __init_bgp__(self, p, resource_info=None, wdir = None):
 
         """
         Initialize for Blue Gene/P environment.
@@ -699,9 +775,14 @@ class mpi_environment:
 
     #---------------------------------------------------------------------------
 
-    def __init_hp_mpi__(self, p, resource_info=None):
+    def __init_hp_mpi__(self, p, resource_info=None, wdir = None):
         """
         Initialize for HP MPI environment.
+
+        The last version of HP MPI is version 2.3, released early 2009.
+        HP MPI was then acquired by Platform MPI (formerly Scali MPI),
+        which merged Scali MPI and HP MPI in Platform MPI 8.0.
+        Platform MPI still seems to use the mpirun launcher syntax.
         """
 
         # Determine base executable paths
@@ -709,13 +790,11 @@ class mpi_environment:
         self.mpiexec = 'mpirun'
 
         if not os.path.isabs(self.mpiexec):
-            for dir in p:
-                absname = os.path.join(dir, self.mpiexec)
+            for d in p:
+                absname = os.path.join(d, self.mpiexec)
                 if os.path.isfile(absname):
-                    if dir == mpi_lib.bindir:
+                    if d == mpi_lib.bindir:
                         self.mpiexec = absname
-                    else:
-                        self.mpiexec = launcher_name
                     break
 
         # Determine processor count and MPMD handling
@@ -738,19 +817,18 @@ class mpi_environment:
 
     #---------------------------------------------------------------------------
 
-    def __init_mpibull2__(self, p, resource_info=None):
+    def __init_mpibull2__(self, p, resource_info=None, wdir = None):
         """
         Initialize for MPIBULL2 environment.
         """
 
         self.__init_mpich2__(p, resource_info)
 
-        # On a Bull Novascale machine using MPIBULL2 (based on
-        # MPICH2), mpdboot and mpdallexit commands exist, as well as mpiexec
-        # (which connects to the mpd ring), but the SLURM srun launcher or
-        # mpibull2-launch meta-launcher (which can integrate directly to
-        # several resource managers using prun, srun, orterun, or mprun)
-        # should be simpler to use.
+        # On a Bull Novascale machine using MPIBULL2 (based on MPICH2),
+        # mpdboot and mpdallexit commands and related mpiexec may be found,
+        # but the SLURM srun launcher or mpibull2-launch meta-launcher
+        # (which can integrate directly to several resource managers
+        # using prun, srun, orterun, or mprun) should be simpler to use.
 
         # The SLURM configuration is slightly different from that of MPICH2.
 
@@ -772,7 +850,7 @@ class mpi_environment:
 
     #---------------------------------------------------------------------------
 
-    def __init_other__(self, resource_info=None):
+    def __init_other__(self, p, resource_info=None, wdir = None):
         """
         Initialize MPI environment info for environments not handled
         in one the the previous cases.
@@ -848,7 +926,7 @@ class exec_environment:
         # Associate default launcher and associated options based on
         # known MPI types, use default otherwise
 
-        self.mpi_env = mpi_environment(self.resources)
+        self.mpi_env = mpi_environment(self.resources, wdir)
 
 #-------------------------------------------------------------------------------
 
diff --git a/bin/cs_info.py b/bin/cs_info.py
index 207519d..1a59425 100644
--- a/bin/cs_info.py
+++ b/bin/cs_info.py
@@ -3,7 +3,7 @@
 #     This file is part of the Code_Saturne User Interface, element of the
 #     Code_Saturne CFD tool.
 #
-#     Copyright (C) 1998-2008 EDF S.A., France
+#     Copyright (C) 1998-2010 EDF S.A., France
 #
 #     contact: saturne-support at edf.fr
 #
@@ -71,7 +71,7 @@ def process_cmd_line(argv):
 
     parser.add_option("-g", "--guide", dest="guides", type="string",
                       metavar="<guide>", action="append",
-                      help="open a manual [refcard, user, theory, tutorial]")
+                      help="open a manual [refcard, user, theory, tutorial, developper]")
 
     parser.add_option("--version", dest="version",
                       action="store_true",
@@ -83,11 +83,15 @@ def process_cmd_line(argv):
 
     (options, args) = parser.parse_args(argv)
 
-    if len(args) > 0:
+    if options.version:
+        print_version()
+        sys.exit(0)
+
+    if len(args) > 0 or len(options.guides) == 0:
         parser.print_help()
         sys.exit(1)
 
-    return options.guides, options.pdf_reader, options.version
+    return options.guides, options.pdf_reader
 
 
 #-------------------------------------------------------------------------------
@@ -141,17 +145,10 @@ def launch_manual(reader, m):
 
         elif os.name == "posix":
 
-            for t in sys_tools:
-                cmd = t + ' ' + manual + ' 2>/dev/null &'
-                try: os.system(cmd)
-                except: pass
-                return
-
-            for r in readers:
+            for r in (sys_tools + readers):
                 cmd = r + ' ' + manual + ' 2>/dev/null &'
-                try: os.system(cmd)
-                except: pass
-                return
+                if os.system(cmd) == 0:
+                    return
 
 
 #-------------------------------------------------------------------------------
@@ -164,10 +161,7 @@ def main(argv):
     Main function.
     """
 
-    manuals, reader, version = process_cmd_line(argv)
-
-    if version:
-        print_version()
+    manuals, reader = process_cmd_line(argv)
 
     for m in manuals:
         launch_manual(reader, m)
diff --git a/bin/runcase.in b/bin/runcase.in
index 91009d8..fa311c5 100644
--- a/bin/runcase.in
+++ b/bin/runcase.in
@@ -51,7 +51,6 @@
 #
 #PBS -l nodes=4:ppn=2
 #PBS -l walltime=1:00:00
-#PBS -l mem=320mb
 #
 #PBS -j eo
 #PBS -N nameandcase
@@ -315,6 +314,8 @@ else
 #  On the CCRT, there is no TMPDIR. We work by default in SCRATCHDIR
   if [ "$SCRATCHDIR" != "" ] ; then
     RUN=$SCRATCHDIR/tmp_Saturne/$STUDY.$CASE.$DATE
+  elif [ -d "/scratch/$USER" ] ; then
+    RUN=/scratch/$USER/tmp_Saturne/$STUDY.$CASE.$DATE
 #
   elif [ "$TMPDIR" != "" -a "$TMPDIR" != "/tmp" ] ; then
     RUN=$TMPDIR/tmp_Saturne/$STUDY.$CASE.$DATE
@@ -967,7 +968,7 @@ if [ $EXEC_KERNEL = yes ] ; then
     fi
   done
 
-  for f in probes_*.dat ; do
+  for f in probes_*.dat str_*.dat Lag_*.dat ; do
     if [ -f $f ] ; then
       if [ ! -d $RESU/HIST.$SUFFIX ] ; then
         mkdir $RESU/HIST.$SUFFIX
diff --git a/bin/runcase.py.in b/bin/runcase.py.in
index fa60816..e146626 100755
--- a/bin/runcase.py.in
+++ b/bin/runcase.py.in
@@ -2,7 +2,7 @@
 #-------------------------------------------------------------------------------
 #   This file is part of the Code_Saturne Solver.
 #
-#   Copyright (C) 2009  EDF
+#   Copyright (C) 2009-2010  EDF
 #
 #   Code_Saturne is free software; you can redistribute it and/or modify it
 #   under the terms of the GNU General Public License as published by the
@@ -41,12 +41,11 @@
 #
 #-------------------------------------------------------------------------------
 #
-# Batch options for PBS or Torque (example: Chatou cluster)
+# Batch options for PBS or Torque (example: Clamart2 cluster)
 # ===============================
 #
 #PBS -l nodes=4:ppn=2
 #PBS -l walltime=1:00:00
-#PBS -l mem=320mb
 #
 #PBS -j eo
 #PBS -N nameandcase
@@ -140,18 +139,58 @@ from cs_case import *
 
 casedir = 'CASEDIRNAME'
 
+# Meshes should be defined as a list, for example:
+#   MESHES = ['part1.des', 'part2.unv']
+
+# In case of badly oriented cells, the Preprocessor will try to
+# reorient cells if REORIENT is set to True.
+
 MESHES = None
 REORIENT = False
 
+# To join meshes with the Preprocessor, the JOIN variable should contain
+# the Preprocessor command line arguments for joining, for example:
+#   JOIN = '-j --color 3 4 6'
+# Otherwise, set JOIN = None.
+
+# Periodicity is an extension of joining, and works in a similar
+# fashion; for example (with 2 periodic directions):
+#   PERIODICITY = --perio --trans 10 0 0 --perio --trans 0 1 0
+# Otherwise, set PERIODICITY to None.
+
+# A variable may be defined over several lines, using the \ character,
+# for example:
+#   PERIODICITY="--perio --trans -10.2 0 0 --color 2                 \
+#                --perio --rota --angle 90 --dir 0 0 1 --invpt 0 0 0 \
+#                        --color 3 4
+
+# See the user documentation or run 'cs_preprocess --help' for details.
+
 JOIN = None
 PERIODICITY = None
 
+# Additional files.
+
+# If thermochemistry applies, the name of the thermochemistry data file
+# may be specified through THERMOCHEMISTRY_DATA. For example:
+#   THERMOCHEMISTRY_DATA='dp_FCP'
+# If meteorological profiles are used, the name of the meteo data file
+# may be specified through METEO_DATA. For example:
+#   METEO_DATA='meteo'
+
+# Additional input files found in the DATA subdirectory may be defined in
+# the USER_INPUT_FILES list. Similarly, additional output files to
+# retrieve can be defined in USER_OUTPUT_FILES, for example:
+#   USER_OUTPOUT_FILES = ['plot1.dat', 'plot2.dump']
+
+# By default, the corresponding values are set to None.
+
 THERMOCHEMISTRY_DATA = None
 METEO_DATA = None
 USER_INPUT_FILES = None
 USER_OUTPUT_FILES = None
 
-# Number of processors associated with resolution domain (auto if none)
+# Number of MPI processes associated with the whole calculation (auto if none).
 
 N_PROCS = None
 N_PROCS_MIN = 1
@@ -159,35 +198,85 @@ N_PROCS_MAX = None
 
 # Partition options (if separate run from resolution)
 
+# PARTITION_LIST defines the partitionings that will be built
+# if EXEC_SOLVER is set to False and EXEC_PARTITION to True (see below).
+# For example, PARTITION_LIST = (128, 256) will produce files
+# 'domain_number_128' and 'domain_number_256' in RESU/PARTITION_OUTPUT.
+
+# PARTITION_OPTS may contain other partitioner options, for example
+#   PARTITION_OPTS = '--scotch --no-perio'; by default, it is set to None.
+
 PARTITION_LIST = None
+PARTITION_OPTS = None
 
 # Solver options
 
+# when the GUI is used, the PARAMETERS variable should contain the name
+# of the XML parameters file, which should always be placed in the
+# DATA subdirectory (for example, PARAMETERS = 'case1.xml').
+
+# CHECK_ARGS allows activation of elementary mesh quality tests, as
+# well as basic linear algebra operations micro-benchmarks, and
+# may thus take the following values:
+#   '-q' (or '--quality') for mesh quality criteria and gradient tests for
+# a known function (sin(x+2y+3z)).
+#   '--benchmark' or '--benchmark --mpitrace' for basic linear algebra
+# operation benchmarks.
+
+# CUT_WARPED_FACES used to cut the faces whose warp angle is larger than a
+# given tolerance (in degrees), for example: CUT_WARPED_FACES = '--cwf 0.01'
+# Otherwise, it is set to None.
+
+# OUTPUT_ARGS allows setting the command-line argument for redirection of
+# the output, for example: OUTPUT_ARGS = '--logp 1'.
+# Otherwise, it is set to None.
+
 PARAMETERS = None
-SOLCOM = False
 CUT_WARPED_FACES = None
 CHECK_ARGS = None
 OUTPUT_ARGS = None
 
-# For SYRTHES couplings, 'MPI' or 'sockets' modes may be used
-
-SYR_COUPLING_MODE = 'MPI'
-SYR_ECHO_COMM = None
-
-# Optional list of hosts
+# Optional list of hosts (if not using a batch system).
 
 HOSTS_LIST = None
 
-# Operations to execute
+# Calculation stages to execute.
+# If EXEC_SOLVER is set to False, the Preprocessor's preprocessor_output file
+# is copied in RESU, and the Partitioner's output is copied in a
+# PARTITION_OUTPUT directory in RESU. Note also that when partitioning
+# with no solver execution, the number of processors required is not known
+# in advance, so the PARTITION_LIST variable above must also be defined.
 
 EXEC_PREPROCESS = True
 EXEC_PARTITION = True
 EXEC_SOLVER = True
 
+# The user may choose to use a mesh in the old .tlc or .slc format instead
+# of a preprocessed mesh by setting SOLCOM = True.
+# Note that this is deprecated, and incompatible with parallel execution.
+
+SOLCOM = False
+
 # Adaptation (not operational yet)
 
 HOMARD_PREFIX = None
 
+# CS_TMP_PREFIX variable allows the user to specify in which temporary
+# directory the calculation will run. If set to None, a default directory
+# will be used (architecture dependent). If a value is specified,
+# the temporary directory will be of the form:
+#  <CS_TMP_PREFIX>/tmp_Saturne/<STUDY>.<CASE>.<DATE>
+
+CS_TMP_PREFIX = None
+
+# VALGRIND enables running of the solver through Valgrind if this
+# memory-checking tool is available. In this case, it should
+# contain the corresponding command-line arguments, such as:
+#   VALGRIND='valgrind --tool=memcheck'
+# Otherwise, it should be set to None.
+
+VALGRIND = None
+
 #-------------------------------------------------------------------------------
 
 def def_exec_prefix():
@@ -195,6 +284,9 @@ def def_exec_prefix():
     Define execution directory prefix.
     """
 
+    if CS_TMP_PREFIX != None:
+        return os.path.join(CS_TMP_PREFIX, "tmp_Saturne")
+
     exec_prefix = None
 
     # Preferential base working directories
@@ -205,6 +297,7 @@ def def_exec_prefix():
         user = os.getenv('USER')
 
         exec_prefix_prefs = [os.getenv('SCRATCHDIR'),
+                             os.path.join('/scratch', user),
                              os.path.join('/local00/users', user),
                              os.path.join('/local01/users', user)]
 
@@ -231,6 +324,7 @@ if __name__ == '__main__':
                join = JOIN,
                periodicity = PERIODICITY,
                partition_list = PARTITION_LIST,
+               partition_opts = PARTITION_OPTS,
                param = PARAMETERS,
                solcom = SOLCOM,
                cut_warped_faces = CUT_WARPED_FACES,
@@ -244,6 +338,9 @@ if __name__ == '__main__':
                n_procs_min = N_PROCS_MIN,
                n_procs_max = N_PROCS_MAX)
 
+    if VALGRIND != None:
+        d.valgrind = VALGRIND
+
     # Possible SYRTHES coupling
 
     if os.path.isdir(os.path.join(casedir, 'DATA_SYR')):
@@ -268,10 +365,10 @@ if __name__ == '__main__':
 
     suffix = None
 
-    mpi_env = None
-
     # Force MPI environment if mpi_environment != None
 
+    mpi_env = None
+
     # Syntax is as follows:
     #
     # mpi_env = mpi_environment()
diff --git a/bin/runcase_mpi_env b/bin/runcase_mpi_env
index 4532e96..def8cc0 100755
--- a/bin/runcase_mpi_env
+++ b/bin/runcase_mpi_env
@@ -4,7 +4,7 @@
 #     This file is part of the Code_Saturne Kernel, element of the
 #     Code_Saturne CFD tool.
 #
-#     Copyright (C) 1998-2008 EDF S.A., France
+#     Copyright (C) 1998-2010 EDF S.A., France
 #
 #     contact: saturne-support at edf.fr
 #
@@ -34,6 +34,10 @@ if [ -f "$TMPDIR/machines" ] ; then     # Univ Manchester queueing system
    MPIHOSTS="$TMPDIR/machines"
 elif [ ! -z "$PBS_NODEFILE" ] ; then    # PBS queueing system
    MPIHOSTS="$PBS_NODEFILE"
+elif [ ! -z "$LSB_MCPU_HOSTS" ] ; then       # LSF queueing system
+   \rm -f $RUN/hostsfile
+   echo $LSB_MCPU_HOSTS | awk '{ for (ii = 1; ii < NF+1; ii+=2) nn = ii+1; { for (jj = 1; jj < $nn; jj++ ) print $ii }}' >> $RUN/hostsfile
+   MPIHOSTS="$RUN/hostsfile"
 elif [ ! -z "$LSB_HOSTS" ] ; then       # LSF queueing system
    \rm -f $RUN/hostsfile
    echo $LSB_HOSTS | awk '{ for (ii = 1; ii < NF+1; ++ii) print $ii }' >> $RUN/hostsfile
@@ -48,13 +52,16 @@ fi
 # Check for the number of processors
 if [ -z  "${NUMBER_OF_PROCESSORS}" ] ; then
   if [ ! -z  "${NSLOTS}" ] ; then
-    # Univ Manchester queueing system
+    # Sun Grid Engine
     NUMBER_OF_PROCESSORS=$NSLOTS
   elif [ ! -z "${SLURM_NPROCS}" ] ; then
-    # LSF queueing system with Slurm
+    # SLURM
     NUMBER_OF_PROCESSORS=$SLURM_NPROCS
+  elif [ ! -z "${LSB_MCPU_HOSTS}" ] ; then
+    # LSF queueing system, using LSB_MCPU_HOSTS
+    NUMBER_OF_PROCESSORS=`echo $LSB_MCPU_HOSTS | awk 'BEGIN {CPUS=0} {for (ii=2; i <= NF;ii+=2) CPUS+=$ii} END {print(CPUS)}'`
   elif [ ! -z "${LSB_HOSTS}" ] ; then
-    # LSF queueing system without Slurm
+    # LSF queueing system, using LSB_HOSTS
     NUMBER_OF_PROCESSORS=`echo $LSB_HOSTS | wc -w`
   elif [ ! -z  "${MPIHOSTS}" ] ; then
     # PBS queueing system
diff --git a/bin/runcase_mpi_rank b/bin/runcase_mpi_rank
index b02132e..924a002 100755
--- a/bin/runcase_mpi_rank
+++ b/bin/runcase_mpi_rank
@@ -32,7 +32,7 @@
 # In order to get the MPI rank from a script launched
 # by mpirun (or prun, mpijob, or equivalent):
 #
-# MPI_RANK=`cs_runcase_mpi_rank $@`
+# MPI_RANK=`runcase_mpi_rank $@`
 #
 # Mainly useful to launch MPMD applications
 # like coupling within MPI 1.2 environment
diff --git a/config/config.rpath b/config/config.rpath
index c547c68..17298f2 100755
--- a/config/config.rpath
+++ b/config/config.rpath
@@ -2,7 +2,7 @@
 # Output a system dependent set of variables, describing how to set the
 # run time search path of shared libraries in an executable.
 #
-#   Copyright 1996-2007 Free Software Foundation, Inc.
+#   Copyright 1996-2010 Free Software Foundation, Inc.
 #   Taken from GNU libtool, 2001
 #   Originally by Gordon Matzigkeit <gord at gnu.ai.mit.edu>, 1996
 #
@@ -47,7 +47,7 @@ for cc_temp in $CC""; do
 done
 cc_basename=`echo "$cc_temp" | sed -e 's%^.*/%%'`
 
-# Code taken from libtool.m4's AC_LIBTOOL_PROG_COMPILER_PIC.
+# Code taken from libtool.m4's _LT_COMPILER_PIC.
 
 wl=
 if test "$GCC" = yes; then
@@ -64,7 +64,7 @@ else
           ;;
       esac
       ;;
-    mingw* | cygwin* | pw32* | os2*)
+    mingw* | cygwin* | pw32* | os2* | cegcc*)
       ;;
     hpux9* | hpux10* | hpux11*)
       wl='-Wl,'
@@ -76,7 +76,13 @@ else
       ;;
     linux* | k*bsd*-gnu)
       case $cc_basename in
-        icc* | ecc*)
+        ecc*)
+          wl='-Wl,'
+          ;;
+        icc* | ifort*)
+          wl='-Wl,'
+          ;;
+        lf95*)
           wl='-Wl,'
           ;;
         pgcc | pgf77 | pgf90)
@@ -124,7 +130,7 @@ else
   esac
 fi
 
-# Code taken from libtool.m4's AC_LIBTOOL_PROG_LD_SHLIBS.
+# Code taken from libtool.m4's _LT_LINKER_SHLIBS.
 
 hardcode_libdir_flag_spec=
 hardcode_libdir_separator=
@@ -132,7 +138,7 @@ hardcode_direct=no
 hardcode_minus_L=no
 
 case "$host_os" in
-  cygwin* | mingw* | pw32*)
+  cygwin* | mingw* | pw32* | cegcc*)
     # FIXME: the MSVC++ port hasn't been tested in a loooong time
     # When not using gcc, we currently assume that we are using
     # Microsoft Visual C++.
@@ -158,7 +164,7 @@ if test "$with_gnu_ld" = yes; then
   # option of GNU ld is called -rpath, not --rpath.
   hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
   case "$host_os" in
-    aix3* | aix4* | aix5*)
+    aix[3-9]*)
       # On AIX/PPC, the GNU linker is very broken
       if test "$host_cpu" != ia64; then
         ld_shlibs=no
@@ -182,7 +188,7 @@ if test "$with_gnu_ld" = yes; then
         ld_shlibs=no
       fi
       ;;
-    cygwin* | mingw* | pw32*)
+    cygwin* | mingw* | pw32* | cegcc*)
       # hardcode_libdir_flag_spec is actually meaningless, as there is
       # no search path for DLLs.
       hardcode_libdir_flag_spec='-L$libdir'
@@ -254,7 +260,7 @@ else
         hardcode_direct=unsupported
       fi
       ;;
-    aix4* | aix5*)
+    aix[4-9]*)
       if test "$host_cpu" = ia64; then
         # On IA64, the linker does run time linking by default, so we don't
         # have to do anything special.
@@ -264,7 +270,7 @@ else
         # Test if we are trying to use run time linking or normal
         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
         # need to do runtime linking.
-        case $host_os in aix4.[23]|aix4.[23].*|aix5*)
+        case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
           for ld_flag in $LDFLAGS; do
             if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
               aix_use_runtimelinking=yes
@@ -326,7 +332,7 @@ else
       ;;
     bsdi[45]*)
       ;;
-    cygwin* | mingw* | pw32*)
+    cygwin* | mingw* | pw32* | cegcc*)
       # When not using gcc, we currently assume that we are using
       # Microsoft Visual C++.
       # hardcode_libdir_flag_spec is actually meaningless, as there is
@@ -494,7 +500,7 @@ else
 fi
 
 # Check dynamic linker characteristics
-# Code taken from libtool.m4's AC_LIBTOOL_SYS_DYNAMIC_LINKER.
+# Code taken from libtool.m4's _LT_SYS_DYNAMIC_LINKER.
 # Unlike libtool.m4, here we don't care about _all_ names of the library, but
 # only about the one the linker finds when passed -lNAME. This is the last
 # element of library_names_spec in libtool.m4, or possibly two of them if the
@@ -505,7 +511,7 @@ case "$host_os" in
   aix3*)
     library_names_spec='$libname.a'
     ;;
-  aix4* | aix5*)
+  aix[4-9]*)
     library_names_spec='$libname$shrext'
     ;;
   amigaos*)
@@ -517,7 +523,7 @@ case "$host_os" in
   bsdi[45]*)
     library_names_spec='$libname$shrext'
     ;;
-  cygwin* | mingw* | pw32*)
+  cygwin* | mingw* | pw32* | cegcc*)
     shrext=.dll
     library_names_spec='$libname.dll.a $libname.lib'
     ;;
diff --git a/config/cs_auto_flags.sh b/config/cs_auto_flags.sh
index be6f5b7..aa61718 100644
--- a/config/cs_auto_flags.sh
+++ b/config/cs_auto_flags.sh
@@ -3,7 +3,7 @@
 # This file is part of the Code_Saturne Kernel, element of the
 # Code_Saturne CFD tool.
 #
-# Copyright (C) 2009 EDF S.A., France
+# Copyright (C) 2009-2010 EDF S.A., France
 #
 # The Code_Saturne Kernel is free software; you can redistribute it
 # and/or modify it under the terms of the GNU General Public License
@@ -53,8 +53,6 @@
 # libs_default_opt       # Added to $LDFLAGS for optimization (default: "")
 # libs_default_prf       # Added to $LDFLAGS for profiling    (default: "")
 
-# cs_disable_shared      # Disable shared librairies          (default: "")
-
 # Two other environment variable strings are defined, containing possibly
 # more detailed compiler information:
 #
@@ -149,7 +147,7 @@ if test "x$cs_gcc" = "xgcc"; then
   # Practical version info for option setting
   cs_cc_version="`$CC -v 2>&1 |grep 'gcc version' |\
                   sed 's/.*gcc version \([-a-z0-9\.]*\).*/\1/'`"
-  cs_cc_vendor=`echo $cc_version |sed 's/\([a-z]*\).*/\1/'`
+  cs_cc_vendor=`echo $cs_cc_version |sed 's/\([a-z]*\).*/\1/'`
   cs_cc_version=`echo $cs_cc_version |sed 's/[-a-z]//g'`
 
   if test "x" = "x$cs_cc_vendor" -a "x" != "x$cs_cc_version"; then
@@ -221,6 +219,13 @@ if test "x$cs_gcc" = "xgcc"; then
       ;;
   esac
 
+  case "$cs_cc_vendor-$cs_cc_version" in
+    gcc-4.[56]*)
+      cflags_default_opt="$cflags_default_opt -fexcess-precision=fast"
+      cflags_default_hot="$cflags_default_hot -fexcess-precision=fast"
+      ;;
+  esac
+
   case "$host_os" in
     *cygwin)
     cflags_default="`echo $cflags_default | sed -e 's/c99/gnu99/g'`"
@@ -242,7 +247,8 @@ elif test "x$cs_gcc" = "xicc"; then
   cs_cc_compiler_known=yes
 
   # Default compiler flags
-  cflags_default="-strict-ansi -std=c99 -funsigned-char -Wall -Wcheck -Wshadow -Wpointer-arith -Wmissing-prototypes -Wuninitialized -Wunused"
+  # (temporarily disable "operands evaluated in unspecified order" remark -- 981)
+  cflags_default="-strict-ansi -std=c99 -funsigned-char -Wall -Wcheck -Wshadow -Wpointer-arith -Wmissing-prototypes -Wuninitialized -Wunused -wd981"
   cflags_default_dbg="-g -O0 -traceback -w2 -Wp64 -ftrapuv"
   cflags_default_opt="-O2"
   cflags_default_hot="-O3"
@@ -277,9 +283,10 @@ if test "x$cs_cc_compiler_known" != "xyes" ; then
     cs_cc_compiler_known=yes
 
     # Default compiler flags
-    cflags_default="-c99"
+    cflags_default="-c99 -noswitcherror"
     cflags_default_dbg="-g -Mbounds"
-    cflags_default_opt="-fast -fastsse"
+    cflags_default_opt="-O2"
+    cflags_default_hot="-fast"
     cflags_default_prf="-Mprof=func,lines"
     cflags_default_omp="-mp"
 
@@ -321,20 +328,18 @@ if test "x$cs_cc_compiler_known" != "xyes" ; then
 
     grep 'Blue Gene' $outfile > /dev/null
     if test "$?" = "0" ; then
-      # Default compiler flags
+      # Default compiler flags (we assume that MPI wrappers are used)
       cs_ibm_bg_type=`grep 'Blue Gene' $outfile | sed -e 's/.*Blue Gene\/\([A-Z]\).*/\1/'`
-      if test "$cs_ibm_bg_type" = "L" ; then
-        cppflags_default="-I/bgl/BlueLight/ppcfloor/bglsys/include"
-        cflags_default="-g -qmaxmem=-1 -qarch=440d -qtune=440"
+      if test "x$cs_ibm_bg_type" = "xL" ; then
+        cflags_default=""
         cflags_default_opt="-O3"
         cflags_default_hot="-O3 -qhot"
-        cflags_default_dbg=""
-      elif test "$cs_ibm_bg_type" = "P" ; then
-        cppflags_default="-I/bgsys/drivers/ppcfloor/comm/include"
-        cflags_default="-g -qmaxmem=-1 -qarch=450d -qtune=450"
+        cflags_default_dbg="-g"
+      elif test "x$cs_ibm_bg_type" = "xP" ; then
+        cflags_default=""
         cflags_default_opt="-O3"
         cflags_default_hot="-O3 -qhot"
-        cflags_default_dbg=""
+        cflags_default_dbg="-g"
       fi
     fi
 
@@ -436,7 +441,7 @@ if test "x$cs_cc_compiler_known" != "xyes" ; then
         cflags_default="-c99 -64"
         cflags_default_opt="-O2 -woff 1521,1552,1096"
         cflags_default_dbg="-g -woff 1429,1521,1209 -fullwarn"
-        cflags_default_prf="-fbexe"
+        cflags_default_prf="$cflags_default_opt"
 
       fi
       ;;
@@ -458,7 +463,7 @@ if test "x$cs_cc_compiler_known" != "xyes" ; then
         cs_linker_set=yes
 
         # Default compiler flags
-        cflags_default="-Aa +e +DA2.0W"
+        cflags_default="-AC99 +e"
         cflags_default_opt="+O2"
         cflags_default_hot="+O3"
         cflags_default_dbg="-g"
@@ -466,12 +471,20 @@ if test "x$cs_cc_compiler_known" != "xyes" ; then
         cflags_default_omp="+Oopenmp" # most pragmas require +O3
 
         # Default linker flags
-        ldflags_default="+DA2.0W +FPVZOUD +U77"
+        ldflags_default="+FPVZOUD +U77"
         ldflags_default_opt="+O1"
         ldflags_default_dbg="-g"
         ldflags_default_prf="-fbexe"
         cflags_default_omp="+Oopenmp"
 
+        if test "$host_cpu" = "ia64" ; then
+          cflags_default="$cflags_default +DD64"
+          ldflags_default="$ldflags_default +DD64"
+        else
+          cflags_default="$cflags_default +DA2.0w"
+          ldflags_default="$ldflags_default +DA2.0w"
+        fi
+
       fi
       ;;
 
@@ -611,7 +624,8 @@ if test "x$cs_fc_compiler_known" != "xyes" ; then
     cs_fc_compiler_known=yes
 
     # Default compiler flags
-    fcflags_default="-cpp -fpic -warn"
+    # (temporarily disable "unused variable" remark -- 7712)
+    fcflags_default="-cpp -fpic -warn -diag-disable 7712"
     fcflags_default_dbg="-g -O0 -traceback -check all -fpe0 -ftrapuv"
     fcflags_default_opt="-O2"
     fcflags_default_hot="-O3"
@@ -646,9 +660,10 @@ if test "x$cs_fc_compiler_known" != "xyes" ; then
     cs_fc_compiler_known=yes
 
     # Default compiler flags
-    fcflags_default="-Mpreprocess"
+    fcflags_default="-Mpreprocess -noswitcherror"
     fcflags_default_dbg="-g -Mbounds"
-    fcflags_default_opt="-fast -fastsse"
+    fcflags_default_opt="-O2"
+    fcflags_default_hot="-fast"
     fcflags_default_prf="-Mprof=func,lines"
     fcflags_default_omp="-mp"
 
@@ -673,6 +688,7 @@ if test "x$cs_fc_compiler_known" != "xyes" ; then
     cs_fc_compiler_known=yes
 
     fcflags_default="-q64 -qextname -qsuffix=cpp=f90"
+    fcflags_default_dbg="-g"
     fcflags_default_opt="-O3"
     fcflags_default_prf="-pg"
     fcflags_default_omp="-qsmp=omp"
@@ -683,16 +699,16 @@ if test "x$cs_fc_compiler_known" != "xyes" ; then
 
     if test "$?" = "0" ; then
 
-      # Default compiler flags
+      # Default compiler flags (we assume that MPI wrappers are used)
       cs_ibm_bg_type=`grep 'Blue Gene' $outfile | sed -e 's/.*Blue Gene\/\([A-Z]\).*/\1/'`
       if test "$cs_ibm_bg_type" = "L" ; then
-        fcflags_default="-g -qmaxmem=-1 -qarch=440d -qtune=440 -qextname -qsuffix=cpp=f90"
-        fcflags_default_dbg=""
+        fcflags_default="-qextname -qsuffix=cpp=f90"
+        fcflags_default_dbg="-g"
         fcflags_default_opt="-O3"
         fcflags_default_hot="-O3 -qhot"
       elif test "$cs_ibm_bg_type" = "P" ; then
-        fcflags_default="-g -qmaxmem=-1 -qarch=450d -qtune=450 -qextname -qsuffix=cpp=f90"
-        fcflags_default_dbg=""
+        fcflags_default="-qextname -qsuffix=cpp=f90"
+        fcflags_default_dbg="-g"
         fcflags_default_opt="-O3"
         fcflags_default_hot="-O3 -qhot"
       fi
@@ -830,7 +846,7 @@ if test "x$cs_linker_set" != "xyes" ; then
       ldflags_default="-64 -Wl,-woff,85"
       ldflags_default_opt=""
       ldflags_default_dbg="-g"
-      ldflags_default_prf=""
+      ldflags_default_prf="-p"
       ;;
 
     solaris2.*)
@@ -850,37 +866,6 @@ if test "x$cs_linker_set" != "xyes" ; then
 
 fi
 
-# Additional libraries and options for specific systems
-#------------------------------------------------------
-
-if test "$cs_ibm_bg_type" = "L" ; then #  For Blue Gene/L
-
-  bg_sys_ldflags="-L/bgl/BlueLight/ppcfloor/bglsys/lib"
-  bg_sys_libs="-lmpich.rts -lmsglayer.rts -lrts.rts -ldevices.rts -lnss_files -lnss_dns -lresolv"
-  bg_trace="/bgl/local/lib/libmpitrace.a"
-  if test ! -f "$bg_trace" ; then
-    bg_trace=""
-  fi
-
-  ldflags_default="${ldflags_default} -Wl,-allow-multiple-definition -L/opt/ibmcmp/xlmass/bg/4.3/blrts_lib ${bg_sys_ldflags}"
-  libs_default="-lmass -lmassv ${bg_trace} ${bg_sys_libs}"
-  cs_disable_shared=yes
-
-elif test "$cs_ibm_bg_type" = "P" ; then #  For Blue Gene/P
-
-  bg_sys_ldflags="-L/bgsys/drivers/ppcfloor/comm/lib -L/bgsys/drivers/ppcfloor/runtime/SPI"
-  bg_sys_libs="-lmpich.cnk -ldcmf.cnk -ldcmfcoll.cnk -lSPI.cna -lrt -lpthread"
-  bg_trace="/bgsys/local/tools_ibm/lib/libmpitrace.a"
-  if test ! -f "$bg_trace" ; then
-    bg_trace=""
-  fi
-
-  ldflags_default="${ldflags_default} -Wl,-allow-multiple-definition -L/opt/ibmcmp/xlmass/bg/4.4/bglib ${bg_sys_ldflags}"
-  libs_default="-lmass -lmassv ${bg_trace} ${bg_sys_libs}"
-  cs_disable_shared=yes
-
-fi
-
 # Finish
 
 export LANG=$save_LANG
diff --git a/config/cs_blas.m4 b/config/cs_blas.m4
index 704a21f..b45a8a9 100644
--- a/config/cs_blas.m4
+++ b/config/cs_blas.m4
@@ -78,12 +78,6 @@ if test "x$with_blas" != "xno" ; then
 
   # Add known paths and libraries for Blue Gene/L or P if not given
 
-  if test "x$with_blas_type" = "x" ; then
-    if test "x$cs_ibm_bg_type" != "x" ; then
-      with_blas_type="ESSL"
-    fi
-  fi
-
   # Test for IBM ESSL BLAS
 
   if test "x$with_blas_type" = "x" -o "x$with_blas_type" = "xESSL" ; then
@@ -92,22 +86,6 @@ if test "x$with_blas" != "xno" ; then
     # Fortran libraries, and header is for C. Test library (link) first,
     # as header is only useful if library is present.
 
-    if test "x$BLAS_CPPFLAGS" = "x" ; then
-      if test "x$cs_ibm_bg_type" = "xL" ; then
-        BLAS_CPPFLAGS="-I/opt/ibmmath/essl/4.2/include"
-      elif test "x$cs_ibm_bg_type" = "xP" ; then
-        BLAS_CPPFLAGS="-I/opt/ibmmath/essl/4.4/include"
-      fi
-    fi
-
-    if test "x$BLAS_LDFLAGS" = "x" ; then
-      if test "x$cs_ibm_bg_type" = "xL" ; then
-        BLAS_LDFLAGS="-L/opt/ibmmath/essl/4.2/lib"
-      elif test "x$cs_ibm_bg_type" = "xP" ; then
-        BLAS_LDFLAGS="-L/opt/ibmmath/essl/4.4/lib"
-      fi
-    fi
-
     AC_LANG_PUSH([Fortran])
     
     if test "$1" = "yes" -o "x$with_blas_libs" = "x"; then # Threaded version ?
diff --git a/config/cs_fortran.m4 b/config/cs_fortran.m4
index b606565..697a5f8 100644
--- a/config/cs_fortran.m4
+++ b/config/cs_fortran.m4
@@ -110,7 +110,9 @@ AC_MSG_RESULT($cs_fc_flush)
 AC_LANG_POP([Fortran])
 
 if test "x$cs_fc_flush" = "xyes"; then
-  FCFLAGS="${FCFLAGS} -D_CS_FC_HAVE_FLUSH"
+  if test "x$cs_ibm_bg_type" = "x" ; then
+    FCFLAGS="${FCFLAGS} -D_CS_FC_HAVE_FLUSH"
+  fi
 fi
 
 unset $cs_fc_flush
diff --git a/config/cs_mpi.m4 b/config/cs_mpi.m4
index 02a4f5c..a2a0533 100644
--- a/config/cs_mpi.m4
+++ b/config/cs_mpi.m4
@@ -202,9 +202,9 @@ if test "x$with_mpi" != "xno" -a "x$cs_have_mpi" = "xno" ; then
     CPPFLAGS="$saved_CPPFLAGS $MPI_CPPFLAGS"
     mpi_type=""
     if test "x$cs_ibm_bg_type" != "x" ; then
-      if test "x$cs_ibm_bg_type" = "L" ; then
+      if test "x$cs_ibm_bg_type" = "xL" ; then
         mpi_type=BGL_MPI
-      elif test "x$cs_ibm_bg_type" = "P" ; then
+      elif test "x$cs_ibm_bg_type" = "xP" ; then
         mpi_type=BGP_MPI
       fi
     fi
diff --git a/config/gettext.m4 b/config/gettext.m4
index c9ae1f7..f84e6a5 100644
--- a/config/gettext.m4
+++ b/config/gettext.m4
@@ -1,5 +1,5 @@
-# gettext.m4 serial 60 (gettext-0.17)
-dnl Copyright (C) 1995-2007 Free Software Foundation, Inc.
+# gettext.m4 serial 63 (gettext-0.18)
+dnl Copyright (C) 1995-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -15,7 +15,7 @@ dnl They are *not* in the public domain.
 
 dnl Authors:
 dnl   Ulrich Drepper <drepper at cygnus.com>, 1995-2000.
-dnl   Bruno Haible <haible at clisp.cons.org>, 2000-2006.
+dnl   Bruno Haible <haible at clisp.cons.org>, 2000-2006, 2008-2010.
 
 dnl Macro to add for using GNU gettext.
 
@@ -60,6 +60,8 @@ AC_DEFUN([AM_GNU_GETTEXT],
   ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], ,
     [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT
 ])])])])])
+  ifelse(ifelse([$1], [], [old])[]ifelse([$1], [no-libtool], [old]), [old],
+    [AC_DIAGNOSE([obsolete], [Use of AM_GNU_GETTEXT without [external] argument is deprecated.])])
   ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], ,
     [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT
 ])])])])
@@ -123,11 +125,11 @@ AC_DEFUN([AM_GNU_GETTEXT],
     gt_use_preinstalled_gnugettext=no
     ifelse(gt_included_intl, yes, [
       AC_MSG_CHECKING([whether included gettext is requested])
-      AC_ARG_WITH(included-gettext,
+      AC_ARG_WITH([included-gettext],
         [  --with-included-gettext use the GNU gettext library included here],
         nls_cv_force_use_gnu_gettext=$withval,
         nls_cv_force_use_gnu_gettext=no)
-      AC_MSG_RESULT($nls_cv_force_use_gnu_gettext)
+      AC_MSG_RESULT([$nls_cv_force_use_gnu_gettext])
 
       nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
       if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
@@ -267,7 +269,7 @@ return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_a
 
     if test "$gt_use_preinstalled_gnugettext" = "yes" \
        || test "$nls_cv_use_gnu_gettext" = "yes"; then
-      AC_DEFINE(ENABLE_NLS, 1,
+      AC_DEFINE([ENABLE_NLS], [1],
         [Define to 1 if translation of program messages to the user's native language
    is requested.])
     else
@@ -301,9 +303,9 @@ return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_a
       fi
 
       dnl For backward compatibility. Some packages may be using this.
-      AC_DEFINE(HAVE_GETTEXT, 1,
+      AC_DEFINE([HAVE_GETTEXT], [1],
        [Define if the GNU gettext() function is already present or preinstalled.])
-      AC_DEFINE(HAVE_DCGETTEXT, 1,
+      AC_DEFINE([HAVE_DCGETTEXT], [1],
        [Define if the GNU dcgettext() function is already present or preinstalled.])
     fi
 
@@ -319,9 +321,9 @@ return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_a
     fi
 
     dnl Make all variables we use known to autoconf.
-    AC_SUBST(BUILD_INCLUDED_LIBINTL)
-    AC_SUBST(USE_INCLUDED_LIBINTL)
-    AC_SUBST(CATOBJEXT)
+    AC_SUBST([BUILD_INCLUDED_LIBINTL])
+    AC_SUBST([USE_INCLUDED_LIBINTL])
+    AC_SUBST([CATOBJEXT])
 
     dnl For backward compatibility. Some configure.ins may be using this.
     nls_cv_header_intl=
@@ -329,36 +331,36 @@ return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_a
 
     dnl For backward compatibility. Some Makefiles may be using this.
     DATADIRNAME=share
-    AC_SUBST(DATADIRNAME)
+    AC_SUBST([DATADIRNAME])
 
     dnl For backward compatibility. Some Makefiles may be using this.
     INSTOBJEXT=.mo
-    AC_SUBST(INSTOBJEXT)
+    AC_SUBST([INSTOBJEXT])
 
     dnl For backward compatibility. Some Makefiles may be using this.
     GENCAT=gencat
-    AC_SUBST(GENCAT)
+    AC_SUBST([GENCAT])
 
     dnl For backward compatibility. Some Makefiles may be using this.
     INTLOBJS=
     if test "$USE_INCLUDED_LIBINTL" = yes; then
       INTLOBJS="\$(GETTOBJS)"
     fi
-    AC_SUBST(INTLOBJS)
+    AC_SUBST([INTLOBJS])
 
     dnl Enable libtool support if the surrounding package wishes it.
     INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix
-    AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX)
+    AC_SUBST([INTL_LIBTOOL_SUFFIX_PREFIX])
   ])
 
   dnl For backward compatibility. Some Makefiles may be using this.
   INTLLIBS="$LIBINTL"
-  AC_SUBST(INTLLIBS)
+  AC_SUBST([INTLLIBS])
 
   dnl Make all documented variables known to autoconf.
-  AC_SUBST(LIBINTL)
-  AC_SUBST(LTLIBINTL)
-  AC_SUBST(POSUB)
+  AC_SUBST([LIBINTL])
+  AC_SUBST([LTLIBINTL])
+  AC_SUBST([POSUB])
 ])
 
 
diff --git a/config/iconv.m4 b/config/iconv.m4
index 66bc76f..e2041b9 100644
--- a/config/iconv.m4
+++ b/config/iconv.m4
@@ -1,5 +1,5 @@
-# iconv.m4 serial AM6 (gettext-0.17)
-dnl Copyright (C) 2000-2002, 2007 Free Software Foundation, Inc.
+# iconv.m4 serial 11 (gettext-0.18.1)
+dnl Copyright (C) 2000-2002, 2007-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -34,7 +34,7 @@ AC_DEFUN([AM_ICONV_LINK],
   am_save_CPPFLAGS="$CPPFLAGS"
   AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV])
 
-  AC_CACHE_CHECK([for iconv], am_cv_func_iconv, [
+  AC_CACHE_CHECK([for iconv], [am_cv_func_iconv], [
     am_cv_func_iconv="no, consider installing GNU libiconv"
     am_cv_lib_iconv=no
     AC_TRY_LINK([#include <stdlib.h>
@@ -42,7 +42,7 @@ AC_DEFUN([AM_ICONV_LINK],
       [iconv_t cd = iconv_open("","");
        iconv(cd,NULL,NULL,NULL,NULL);
        iconv_close(cd);],
-      am_cv_func_iconv=yes)
+      [am_cv_func_iconv=yes])
     if test "$am_cv_func_iconv" != yes; then
       am_save_LIBS="$LIBS"
       LIBS="$LIBS $LIBICONV"
@@ -51,14 +51,14 @@ AC_DEFUN([AM_ICONV_LINK],
         [iconv_t cd = iconv_open("","");
          iconv(cd,NULL,NULL,NULL,NULL);
          iconv_close(cd);],
-        am_cv_lib_iconv=yes
-        am_cv_func_iconv=yes)
+        [am_cv_lib_iconv=yes]
+        [am_cv_func_iconv=yes])
       LIBS="$am_save_LIBS"
     fi
   ])
   if test "$am_cv_func_iconv" = yes; then
-    AC_CACHE_CHECK([for working iconv], am_cv_func_iconv_works, [
-      dnl This tests against bugs in AIX 5.1 and HP-UX 11.11.
+    AC_CACHE_CHECK([for working iconv], [am_cv_func_iconv_works], [
+      dnl This tests against bugs in AIX 5.1, HP-UX 11.11, Solaris 10.
       am_save_LIBS="$LIBS"
       if test $am_cv_lib_iconv = yes; then
         LIBS="$LIBS $LIBICONV"
@@ -87,6 +87,25 @@ int main ()
           return 1;
       }
   }
+  /* Test against Solaris 10 bug: Failures are not distinguishable from
+     successful returns.  */
+  {
+    iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
+    if (cd_ascii_to_88591 != (iconv_t)(-1))
+      {
+        static const char input[] = "\263";
+        char buf[10];
+        const char *inptr = input;
+        size_t inbytesleft = strlen (input);
+        char *outptr = buf;
+        size_t outbytesleft = sizeof (buf);
+        size_t res = iconv (cd_ascii_to_88591,
+                            (char **) &inptr, &inbytesleft,
+                            &outptr, &outbytesleft);
+        if (res == 0)
+          return 1;
+      }
+  }
 #if 0 /* This bug could be worked around by the caller.  */
   /* Test against HP-UX 11.11 bug: Positive return value instead of 0.  */
   {
@@ -134,7 +153,7 @@ int main ()
     am_func_iconv=no am_cv_lib_iconv=no
   fi
   if test "$am_func_iconv" = yes; then
-    AC_DEFINE(HAVE_ICONV, 1,
+    AC_DEFINE([HAVE_ICONV], [1],
       [Define if you have the iconv() function and it works.])
   fi
   if test "$am_cv_lib_iconv" = yes; then
@@ -147,16 +166,31 @@ int main ()
     LIBICONV=
     LTLIBICONV=
   fi
-  AC_SUBST(LIBICONV)
-  AC_SUBST(LTLIBICONV)
+  AC_SUBST([LIBICONV])
+  AC_SUBST([LTLIBICONV])
 ])
 
-AC_DEFUN([AM_ICONV],
+dnl Define AM_ICONV using AC_DEFUN_ONCE for Autoconf >= 2.64, in order to
+dnl avoid warnings like
+dnl "warning: AC_REQUIRE: `AM_ICONV' was expanded before it was required".
+dnl This is tricky because of the way 'aclocal' is implemented:
+dnl - It requires defining an auxiliary macro whose name ends in AC_DEFUN.
+dnl   Otherwise aclocal's initial scan pass would miss the macro definition.
+dnl - It requires a line break inside the AC_DEFUN_ONCE and AC_DEFUN expansions.
+dnl   Otherwise aclocal would emit many "Use of uninitialized value $1"
+dnl   warnings.
+m4_define([gl_iconv_AC_DEFUN],
+  m4_version_prereq([2.64],
+    [[AC_DEFUN_ONCE(
+        [$1], [$2])]],
+    [[AC_DEFUN(
+        [$1], [$2])]]))
+gl_iconv_AC_DEFUN([AM_ICONV],
 [
   AM_ICONV_LINK
   if test "$am_cv_func_iconv" = yes; then
     AC_MSG_CHECKING([for iconv declaration])
-    AC_CACHE_VAL(am_cv_proto_iconv, [
+    AC_CACHE_VAL([am_cv_proto_iconv], [
       AC_TRY_COMPILE([
 #include <stdlib.h>
 #include <iconv.h>
@@ -169,12 +203,12 @@ size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, si
 #else
 size_t iconv();
 #endif
-], [], am_cv_proto_iconv_arg1="", am_cv_proto_iconv_arg1="const")
+], [], [am_cv_proto_iconv_arg1=""], [am_cv_proto_iconv_arg1="const"])
       am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"])
     am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
-    AC_MSG_RESULT([$]{ac_t:-
-         }[$]am_cv_proto_iconv)
-    AC_DEFINE_UNQUOTED(ICONV_CONST, $am_cv_proto_iconv_arg1,
+    AC_MSG_RESULT([
+         $am_cv_proto_iconv])
+    AC_DEFINE_UNQUOTED([ICONV_CONST], [$am_cv_proto_iconv_arg1],
       [Define as const if the declaration of iconv() needs const.])
   fi
 ])
diff --git a/config/lib-ld.m4 b/config/lib-ld.m4
index 96c4e2c..ebb3052 100644
--- a/config/lib-ld.m4
+++ b/config/lib-ld.m4
@@ -1,5 +1,5 @@
-# lib-ld.m4 serial 3 (gettext-0.13)
-dnl Copyright (C) 1996-2003 Free Software Foundation, Inc.
+# lib-ld.m4 serial 4 (gettext-0.18)
+dnl Copyright (C) 1996-2003, 2009-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -10,7 +10,7 @@ dnl with libtool.m4.
 
 dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no.
 AC_DEFUN([AC_LIB_PROG_LD_GNU],
-[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_cv_prog_gnu_ld,
+[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], [acl_cv_prog_gnu_ld],
 [# I'd rather use --version here, but apparently some GNU ld's only accept -v.
 case `$LD -v 2>&1 </dev/null` in
 *GNU* | *'with BFD'*)
@@ -23,7 +23,7 @@ with_gnu_ld=$acl_cv_prog_gnu_ld
 
 dnl From libtool-1.4. Sets the variable LD.
 AC_DEFUN([AC_LIB_PROG_LD],
-[AC_ARG_WITH(gnu-ld,
+[AC_ARG_WITH([gnu-ld],
 [  --with-gnu-ld           assume the C compiler uses GNU ld [default=no]],
 test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
 AC_REQUIRE([AC_PROG_CC])dnl
@@ -59,7 +59,7 @@ if test "$GCC" = yes; then
       # Canonicalize the path of ld
       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
-	ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
+        ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
       done
       test -z "$LD" && LD="$ac_prog"
       ;;
@@ -77,7 +77,7 @@ elif test "$with_gnu_ld" = yes; then
 else
   AC_MSG_CHECKING([for non-GNU ld])
 fi
-AC_CACHE_VAL(acl_cv_path_LD,
+AC_CACHE_VAL([acl_cv_path_LD],
 [if test -z "$LD"; then
   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
   for ac_dir in $PATH; do
@@ -89,9 +89,9 @@ AC_CACHE_VAL(acl_cv_path_LD,
       # Break only if it was the GNU/non-GNU ld that we prefer.
       case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in
       *GNU* | *'with BFD'*)
-	test "$with_gnu_ld" != no && break ;;
+        test "$with_gnu_ld" != no && break ;;
       *)
-	test "$with_gnu_ld" != yes && break ;;
+        test "$with_gnu_ld" != yes && break ;;
       esac
     fi
   done
@@ -101,9 +101,9 @@ else
 fi])
 LD="$acl_cv_path_LD"
 if test -n "$LD"; then
-  AC_MSG_RESULT($LD)
+  AC_MSG_RESULT([$LD])
 else
-  AC_MSG_RESULT(no)
+  AC_MSG_RESULT([no])
 fi
 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
 AC_LIB_PROG_LD_GNU
diff --git a/config/lib-link.m4 b/config/lib-link.m4
index e3d26fc..c73bd8e 100644
--- a/config/lib-link.m4
+++ b/config/lib-link.m4
@@ -1,12 +1,12 @@
-# lib-link.m4 serial 13 (gettext-0.17)
-dnl Copyright (C) 2001-2007 Free Software Foundation, Inc.
+# lib-link.m4 serial 21 (gettext-0.18)
+dnl Copyright (C) 2001-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
 
 dnl From Bruno Haible.
 
-AC_PREREQ(2.54)
+AC_PREREQ([2.54])
 
 dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
 dnl the libraries corresponding to explicit and implicit dependencies.
@@ -18,9 +18,9 @@ AC_DEFUN([AC_LIB_LINKFLAGS],
 [
   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
   AC_REQUIRE([AC_LIB_RPATH])
-  define([Name],[translit([$1],[./-], [___])])
-  define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
-                               [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
+  pushdef([Name],[translit([$1],[./-], [___])])
+  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
+                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
   AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
     AC_LIB_LINKFLAGS_BODY([$1], [$2])
     ac_cv_lib[]Name[]_libs="$LIB[]NAME"
@@ -39,16 +39,17 @@ AC_DEFUN([AC_LIB_LINKFLAGS],
   dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
   dnl results of this search when this library appears as a dependency.
   HAVE_LIB[]NAME=yes
-  undefine([Name])
-  undefine([NAME])
+  popdef([NAME])
+  popdef([Name])
 ])
 
-dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode)
+dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode, [missing-message])
 dnl searches for libname and the libraries corresponding to explicit and
 dnl implicit dependencies, together with the specified include files and
-dnl the ability to compile and link the specified testcode. If found, it
-dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and
-dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and
+dnl the ability to compile and link the specified testcode. The missing-message
+dnl defaults to 'no' and may contain additional hints for the user.
+dnl If found, it sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME}
+dnl and LTLIB${NAME} variables and augments the CPPFLAGS variable, and
 dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
 dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
 dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
@@ -57,9 +58,9 @@ AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
 [
   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
   AC_REQUIRE([AC_LIB_RPATH])
-  define([Name],[translit([$1],[./-], [___])])
-  define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
-                               [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
+  pushdef([Name],[translit([$1],[./-], [___])])
+  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
+                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
 
   dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
   dnl accordingly.
@@ -73,13 +74,25 @@ AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
 
   AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
     ac_save_LIBS="$LIBS"
-    LIBS="$LIBS $LIB[]NAME"
-    AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no])
+    dnl If $LIB[]NAME contains some -l options, add it to the end of LIBS,
+    dnl because these -l options might require -L options that are present in
+    dnl LIBS. -l options benefit only from the -L options listed before it.
+    dnl Otherwise, add it to the front of LIBS, because it may be a static
+    dnl library that depends on another static library that is present in LIBS.
+    dnl Static libraries benefit only from the static libraries listed after
+    dnl it.
+    case " $LIB[]NAME" in
+      *" -l"*) LIBS="$LIBS $LIB[]NAME" ;;
+      *)       LIBS="$LIB[]NAME $LIBS" ;;
+    esac
+    AC_TRY_LINK([$3], [$4],
+      [ac_cv_lib[]Name=yes],
+      [ac_cv_lib[]Name='m4_if([$5], [], [no], [[$5]])'])
     LIBS="$ac_save_LIBS"
   ])
   if test "$ac_cv_lib[]Name" = yes; then
     HAVE_LIB[]NAME=yes
-    AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.])
+    AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the lib][$1 library.])
     AC_MSG_CHECKING([how to link with lib[]$1])
     AC_MSG_RESULT([$LIB[]NAME])
   else
@@ -95,8 +108,8 @@ AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
   AC_SUBST([LIB]NAME)
   AC_SUBST([LTLIB]NAME)
   AC_SUBST([LIB]NAME[_PREFIX])
-  undefine([Name])
-  undefine([NAME])
+  popdef([NAME])
+  popdef([Name])
 ])
 
 dnl Determine the platform dependent parameters needed to use rpath:
@@ -114,7 +127,7 @@ AC_DEFUN([AC_LIB_RPATH],
   AC_REQUIRE([AC_LIB_PROG_LD])            dnl we use $LD, $with_gnu_ld
   AC_REQUIRE([AC_CANONICAL_HOST])         dnl we use $host
   AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
-  AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [
+  AC_CACHE_CHECK([for shared library run path origin], [acl_cv_rpath], [
     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
     . ./conftest.sh
@@ -131,11 +144,32 @@ AC_DEFUN([AC_LIB_RPATH],
   acl_hardcode_direct="$acl_cv_hardcode_direct"
   acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
   dnl Determine whether the user wants rpath handling at all.
-  AC_ARG_ENABLE(rpath,
+  AC_ARG_ENABLE([rpath],
     [  --disable-rpath         do not hardcode runtime library paths],
     :, enable_rpath=yes)
 ])
 
+dnl AC_LIB_FROMPACKAGE(name, package)
+dnl declares that libname comes from the given package. The configure file
+dnl will then not have a --with-libname-prefix option but a
+dnl --with-package-prefix option. Several libraries can come from the same
+dnl package. This declaration must occur before an AC_LIB_LINKFLAGS or similar
+dnl macro call that searches for libname.
+AC_DEFUN([AC_LIB_FROMPACKAGE],
+[
+  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
+                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
+  define([acl_frompackage_]NAME, [$2])
+  popdef([NAME])
+  pushdef([PACK],[$2])
+  pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-],
+                                  [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
+  define([acl_libsinpackage_]PACKUP,
+    m4_ifdef([acl_libsinpackage_]PACKUP, [acl_libsinpackage_]PACKUP[[, ]],)[lib$1])
+  popdef([PACKUP])
+  popdef([PACK])
+])
+
 dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
 dnl the libraries corresponding to explicit and implicit dependencies.
 dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
@@ -144,19 +178,23 @@ dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
 AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
 [
   AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
-  define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
-                               [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
+  pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
+                                [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
+  pushdef([PACK],[m4_ifdef([acl_frompackage_]NAME, [acl_frompackage_]NAME, lib[$1])])
+  pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-],
+                                  [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
+  pushdef([PACKLIBS],[m4_ifdef([acl_frompackage_]NAME, [acl_libsinpackage_]PACKUP, lib[$1])])
   dnl Autoconf >= 2.61 supports dots in --with options.
-  define([N_A_M_E],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit([$1],[.],[_])],[$1])])
+  pushdef([P_A_C_K],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit(PACK,[.],[_])],PACK)])
   dnl By default, look in $includedir and $libdir.
   use_additional=yes
   AC_LIB_WITH_FINAL_PREFIX([
     eval additional_includedir=\"$includedir\"
     eval additional_libdir=\"$libdir\"
   ])
-  AC_LIB_ARG_WITH([lib]N_A_M_E[-prefix],
-[  --with-lib]N_A_M_E[-prefix[=DIR]  search for lib$1 in DIR/include and DIR/lib
-  --without-lib]N_A_M_E[-prefix     don't search for lib$1 in includedir and libdir],
+  AC_ARG_WITH(P_A_C_K[-prefix],
+[[  --with-]]P_A_C_K[[-prefix[=DIR]  search for ]PACKLIBS[ in DIR/include and DIR/lib
+  --without-]]P_A_C_K[[-prefix     don't search for ]PACKLIBS[ in includedir and libdir]],
 [
     if test "X$withval" = "Xno"; then
       use_additional=no
@@ -169,6 +207,10 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
       else
         additional_includedir="$withval/include"
         additional_libdir="$withval/$acl_libdirstem"
+        if test "$acl_libdirstem2" != "$acl_libdirstem" \
+           && ! test -d "$withval/$acl_libdirstem"; then
+          additional_libdir="$withval/$acl_libdirstem2"
+        fi
       fi
     fi
 ])
@@ -178,6 +220,9 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
   LTLIB[]NAME=
   INC[]NAME=
   LIB[]NAME[]_PREFIX=
+  dnl HAVE_LIB${NAME} is an indicator that LIB${NAME}, LTLIB${NAME} have been
+  dnl computed. So it has to be reset here.
+  HAVE_LIB[]NAME=
   rpathdirs=
   ltrpathdirs=
   names_already_handled=
@@ -327,7 +372,9 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
               dnl Linking with a shared library. We attempt to hardcode its
               dnl directory into the executable's runpath, unless it's the
               dnl standard /usr/lib.
-              if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then
+              if test "$enable_rpath" = no \
+                 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
+                 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
                 dnl No hardcoding is needed.
                 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
               else
@@ -415,7 +462,16 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
             case "$found_dir" in
               */$acl_libdirstem | */$acl_libdirstem/)
                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
-                LIB[]NAME[]_PREFIX="$basedir"
+                if test "$name" = '$1'; then
+                  LIB[]NAME[]_PREFIX="$basedir"
+                fi
+                additional_includedir="$basedir/include"
+                ;;
+              */$acl_libdirstem2 | */$acl_libdirstem2/)
+                basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
+                if test "$name" = '$1'; then
+                  LIB[]NAME[]_PREFIX="$basedir"
+                fi
                 additional_includedir="$basedir/include"
                 ;;
             esac
@@ -476,9 +532,11 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
                     dnl   3. if it's already present in $LDFLAGS or the already
                     dnl      constructed $LIBNAME,
                     dnl   4. if it doesn't exist as a directory.
-                    if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
+                    if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
+                       && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
                       haveit=
-                      if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
+                      if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
+                         || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
                         if test -n "$GCC"; then
                           case $host_os in
                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
@@ -609,6 +667,11 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
       LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir"
     done
   fi
+  popdef([P_A_C_K])
+  popdef([PACKLIBS])
+  popdef([PACKUP])
+  popdef([PACK])
+  popdef([NAME])
 ])
 
 dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR,
@@ -654,7 +717,8 @@ AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS],
         if test -n "$next"; then
           dir="$next"
           dnl No need to hardcode the standard /usr/lib.
-          if test "X$dir" != "X/usr/$acl_libdirstem"; then
+          if test "X$dir" != "X/usr/$acl_libdirstem" \
+             && test "X$dir" != "X/usr/$acl_libdirstem2"; then
             rpathdirs="$rpathdirs $dir"
           fi
           next=
@@ -663,7 +727,8 @@ AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS],
             -L) next=yes ;;
             -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'`
                  dnl No need to hardcode the standard /usr/lib.
-                 if test "X$dir" != "X/usr/$acl_libdirstem"; then
+                 if test "X$dir" != "X/usr/$acl_libdirstem" \
+                    && test "X$dir" != "X/usr/$acl_libdirstem2"; then
                    rpathdirs="$rpathdirs $dir"
                  fi
                  next= ;;
diff --git a/config/lib-prefix.m4 b/config/lib-prefix.m4
index a8684e1..1601cea 100644
--- a/config/lib-prefix.m4
+++ b/config/lib-prefix.m4
@@ -1,5 +1,5 @@
-# lib-prefix.m4 serial 5 (gettext-0.15)
-dnl Copyright (C) 2001-2005 Free Software Foundation, Inc.
+# lib-prefix.m4 serial 7 (gettext-0.18)
+dnl Copyright (C) 2001-2005, 2008-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -153,33 +153,72 @@ AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX],
   prefix="$acl_save_prefix"
 ])
 
-dnl AC_LIB_PREPARE_MULTILIB creates a variable acl_libdirstem, containing
-dnl the basename of the libdir, either "lib" or "lib64".
+dnl AC_LIB_PREPARE_MULTILIB creates
+dnl - a variable acl_libdirstem, containing the basename of the libdir, either
+dnl   "lib" or "lib64" or "lib/64",
+dnl - a variable acl_libdirstem2, as a secondary possible value for
+dnl   acl_libdirstem, either the same as acl_libdirstem or "lib/sparcv9" or
+dnl   "lib/amd64".
 AC_DEFUN([AC_LIB_PREPARE_MULTILIB],
 [
-  dnl There is no formal standard regarding lib and lib64. The current
-  dnl practice is that on a system supporting 32-bit and 64-bit instruction
-  dnl sets or ABIs, 64-bit libraries go under $prefix/lib64 and 32-bit
-  dnl libraries go under $prefix/lib. We determine the compiler's default
-  dnl mode by looking at the compiler's library search path. If at least
-  dnl of its elements ends in /lib64 or points to a directory whose absolute
-  dnl pathname ends in /lib64, we assume a 64-bit ABI. Otherwise we use the
-  dnl default, namely "lib".
+  dnl There is no formal standard regarding lib and lib64.
+  dnl On glibc systems, the current practice is that on a system supporting
+  dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
+  dnl $prefix/lib64 and 32-bit libraries go under $prefix/lib. We determine
+  dnl the compiler's default mode by looking at the compiler's library search
+  dnl path. If at least one of its elements ends in /lib64 or points to a
+  dnl directory whose absolute pathname ends in /lib64, we assume a 64-bit ABI.
+  dnl Otherwise we use the default, namely "lib".
+  dnl On Solaris systems, the current practice is that on a system supporting
+  dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
+  dnl $prefix/lib/64 (which is a symlink to either $prefix/lib/sparcv9 or
+  dnl $prefix/lib/amd64) and 32-bit libraries go under $prefix/lib.
+  AC_REQUIRE([AC_CANONICAL_HOST])
   acl_libdirstem=lib
-  searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
-  if test -n "$searchpath"; then
-    acl_save_IFS="${IFS= 	}"; IFS=":"
-    for searchdir in $searchpath; do
-      if test -d "$searchdir"; then
-        case "$searchdir" in
-          */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
-          *) searchdir=`cd "$searchdir" && pwd`
-             case "$searchdir" in
-               */lib64 ) acl_libdirstem=lib64 ;;
-             esac ;;
+  acl_libdirstem2=
+  case "$host_os" in
+    solaris*)
+      dnl See Solaris 10 Software Developer Collection > Solaris 64-bit Developer's Guide > The Development Environment
+      dnl <http://docs.sun.com/app/docs/doc/816-5138/dev-env?l=en&a=view>.
+      dnl "Portable Makefiles should refer to any library directories using the 64 symbolic link."
+      dnl But we want to recognize the sparcv9 or amd64 subdirectory also if the
+      dnl symlink is missing, so we set acl_libdirstem2 too.
+      AC_CACHE_CHECK([for 64-bit host], [gl_cv_solaris_64bit],
+        [AC_EGREP_CPP([sixtyfour bits], [
+#ifdef _LP64
+sixtyfour bits
+#endif
+           ], [gl_cv_solaris_64bit=yes], [gl_cv_solaris_64bit=no])
+        ])
+      if test $gl_cv_solaris_64bit = yes; then
+        acl_libdirstem=lib/64
+        case "$host_cpu" in
+          sparc*)        acl_libdirstem2=lib/sparcv9 ;;
+          i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
         esac
       fi
-    done
-    IFS="$acl_save_IFS"
-  fi
+      ;;
+    *)
+      searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
+      if test -n "$searchpath"; then
+        acl_save_IFS="${IFS= 	}"; IFS=":"
+        for searchdir in $searchpath; do
+          if test -d "$searchdir"; then
+            case "$searchdir" in
+              */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
+              */../ | */.. )
+                # Better ignore directories of this form. They are misleading.
+                ;;
+              *) searchdir=`cd "$searchdir" && pwd`
+                 case "$searchdir" in
+                   */lib64 ) acl_libdirstem=lib64 ;;
+                 esac ;;
+            esac
+          fi
+        done
+        IFS="$acl_save_IFS"
+      fi
+      ;;
+  esac
+  test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
 ])
diff --git a/config/libtool.m4 b/config/libtool.m4
index 39ba996..d812584 100644
--- a/config/libtool.m4
+++ b/config/libtool.m4
@@ -1,7 +1,8 @@
 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
 #
 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-#                 2006, 2007, 2008 Free Software Foundation, Inc.
+#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
+#                 Inc.
 #   Written by Gordon Matzigkeit, 1996
 #
 # This file is free software; the Free Software Foundation gives
@@ -10,7 +11,8 @@
 
 m4_define([_LT_COPYING], [dnl
 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-#                 2006, 2007, 2008 Free Software Foundation, Inc.
+#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
+#                 Inc.
 #   Written by Gordon Matzigkeit, 1996
 #
 #   This file is part of GNU Libtool.
@@ -37,7 +39,7 @@ m4_define([_LT_COPYING], [dnl
 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 ])
 
-# serial 56 LT_INIT
+# serial 57 LT_INIT
 
 
 # LT_PREREQ(VERSION)
@@ -66,6 +68,7 @@ esac
 # ------------------
 AC_DEFUN([LT_INIT],
 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
+AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
 AC_BEFORE([$0], [LT_LANG])dnl
 AC_BEFORE([$0], [LT_OUTPUT])dnl
 AC_BEFORE([$0], [LTDL_INIT])dnl
@@ -82,6 +85,8 @@ AC_REQUIRE([LTVERSION_VERSION])dnl
 AC_REQUIRE([LTOBSOLETE_VERSION])dnl
 m4_require([_LT_PROG_LTMAIN])dnl
 
+_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
+
 dnl Parse OPTIONS
 _LT_SET_OPTIONS([$0], [$1])
 
@@ -118,7 +123,7 @@ m4_defun([_LT_CC_BASENAME],
     *) break;;
   esac
 done
-cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
+cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
 ])
 
 
@@ -138,6 +143,9 @@ m4_defun([_LT_FILEUTILS_DEFAULTS],
 m4_defun([_LT_SETUP],
 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
+AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
+
 _LT_DECL([], [host_alias], [0], [The host system])dnl
 _LT_DECL([], [host], [0])dnl
 _LT_DECL([], [host_os], [0])dnl
@@ -160,10 +168,13 @@ _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
 dnl
 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
+m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
 m4_require([_LT_CMD_RELOAD])dnl
 m4_require([_LT_CHECK_MAGIC_METHOD])dnl
+m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
+m4_require([_LT_WITH_SYSROOT])dnl
 
 _LT_CONFIG_LIBTOOL_INIT([
 # See if we are running on zsh, and set the options which allow our
@@ -179,7 +190,6 @@ fi
 _LT_CHECK_OBJDIR
 
 m4_require([_LT_TAG_COMPILER])dnl
-_LT_PROG_ECHO_BACKSLASH
 
 case $host_os in
 aix3*)
@@ -193,23 +203,6 @@ aix3*)
   ;;
 esac
 
-# Sed substitution that helps us do robust quoting.  It backslashifies
-# metacharacters that are still active within double-quoted strings.
-sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\([["`\\]]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
 # Global variables:
 ofile=libtool
 can_build_shared=yes
@@ -250,6 +243,28 @@ _LT_CONFIG_COMMANDS
 ])# _LT_SETUP
 
 
+# _LT_PREPARE_SED_QUOTE_VARS
+# --------------------------
+# Define a few sed substitution that help us do robust quoting.
+m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
+[# Backslashify metacharacters that are still active within
+# double-quoted strings.
+sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
+
+# Same as above, but do not quote variable references.
+double_quote_subst='s/\([["`\\]]\)/\\\1/g'
+
+# Sed substitution to delay expansion of an escaped shell variable in a
+# double_quote_subst'ed string.
+delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
+
+# Sed substitution to delay expansion of an escaped single quote.
+delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
+
+# Sed substitution to avoid accidental globbing in evaled expressions
+no_glob_subst='s/\*/\\\*/g'
+])
+
 # _LT_PROG_LTMAIN
 # ---------------
 # Note that this code is called both from `configure', and `config.status'
@@ -408,7 +423,7 @@ m4_define([_lt_decl_all_varnames],
 # declaration there will have the same value as in `configure'.  VARNAME
 # must have a single quote delimited value for this to work.
 m4_define([_LT_CONFIG_STATUS_DECLARE],
-[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`'])
+[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
 
 
 # _LT_CONFIG_STATUS_DECLARATIONS
@@ -418,7 +433,7 @@ m4_define([_LT_CONFIG_STATUS_DECLARE],
 # embedded single quotes properly.  In configure, this macro expands
 # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
 #
-#    <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`'
+#    <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
 m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
 [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
     [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
@@ -517,12 +532,20 @@ LTCC='$LTCC'
 LTCFLAGS='$LTCFLAGS'
 compiler='$compiler_DEFAULT'
 
+# A function that is used when there is no print builtin or printf.
+func_fallback_echo ()
+{
+  eval 'cat <<_LTECHO_EOF
+\$[]1
+_LTECHO_EOF'
+}
+
 # Quote evaled strings.
 for var in lt_decl_all_varnames([[ \
 ]], lt_decl_quote_varnames); do
-    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
+    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
     *[[\\\\\\\`\\"\\\$]]*)
-      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
+      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
       ;;
     *)
       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
@@ -533,9 +556,9 @@ done
 # Double-quote double-evaled strings.
 for var in lt_decl_all_varnames([[ \
 ]], lt_decl_dquote_varnames); do
-    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
+    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
     *[[\\\\\\\`\\"\\\$]]*)
-      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
+      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
       ;;
     *)
       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
@@ -543,16 +566,38 @@ for var in lt_decl_all_varnames([[ \
     esac
 done
 
-# Fix-up fallback echo if it was mangled by the above quoting rules.
-case \$lt_ECHO in
-*'\\\[$]0 --fallback-echo"')dnl "
-  lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
-  ;;
-esac
-
 _LT_OUTPUT_LIBTOOL_INIT
 ])
 
+# _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
+# ------------------------------------
+# Generate a child script FILE with all initialization necessary to
+# reuse the environment learned by the parent script, and make the
+# file executable.  If COMMENT is supplied, it is inserted after the
+# `#!' sequence but before initialization text begins.  After this
+# macro, additional text can be appended to FILE to form the body of
+# the child script.  The macro ends with non-zero status if the
+# file could not be fully written (such as if the disk is full).
+m4_ifdef([AS_INIT_GENERATED],
+[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
+[m4_defun([_LT_GENERATED_FILE_INIT],
+[m4_require([AS_PREPARE])]dnl
+[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
+[lt_write_fail=0
+cat >$1 <<_ASEOF || lt_write_fail=1
+#! $SHELL
+# Generated by $as_me.
+$2
+SHELL=\${CONFIG_SHELL-$SHELL}
+export SHELL
+_ASEOF
+cat >>$1 <<\_ASEOF || lt_write_fail=1
+AS_SHELL_SANITIZE
+_AS_PREPARE
+exec AS_MESSAGE_FD>&1
+_ASEOF
+test $lt_write_fail = 0 && chmod +x $1[]dnl
+m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
 
 # LT_OUTPUT
 # ---------
@@ -562,20 +607,11 @@ _LT_OUTPUT_LIBTOOL_INIT
 AC_DEFUN([LT_OUTPUT],
 [: ${CONFIG_LT=./config.lt}
 AC_MSG_NOTICE([creating $CONFIG_LT])
-cat >"$CONFIG_LT" <<_LTEOF
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate a libtool stub with the current configuration.
-
-lt_cl_silent=false
-SHELL=\${CONFIG_SHELL-$SHELL}
-_LTEOF
+_LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
+[# Run this file to recreate a libtool stub with the current configuration.])
 
 cat >>"$CONFIG_LT" <<\_LTEOF
-AS_SHELL_SANITIZE
-_AS_PREPARE
-
-exec AS_MESSAGE_FD>&1
+lt_cl_silent=false
 exec AS_MESSAGE_LOG_FD>>config.log
 {
   echo
@@ -601,7 +637,7 @@ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
 m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
 configured by $[0], generated by m4_PACKAGE_STRING.
 
-Copyright (C) 2008 Free Software Foundation, Inc.
+Copyright (C) 2010 Free Software Foundation, Inc.
 This config.lt script is free software; the Free Software Foundation
 gives unlimited permision to copy, distribute and modify it."
 
@@ -646,15 +682,13 @@ chmod +x "$CONFIG_LT"
 # appending to config.log, which fails on DOS, as config.log is still kept
 # open by configure.  Here we exec the FD to /dev/null, effectively closing
 # config.log, so it can be properly (re)opened and appended to by config.lt.
-if test "$no_create" != yes; then
-  lt_cl_success=:
-  test "$silent" = yes &&
-    lt_config_lt_args="$lt_config_lt_args --quiet"
-  exec AS_MESSAGE_LOG_FD>/dev/null
-  $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
-  exec AS_MESSAGE_LOG_FD>>config.log
-  $lt_cl_success || AS_EXIT(1)
-fi
+lt_cl_success=:
+test "$silent" = yes &&
+  lt_config_lt_args="$lt_config_lt_args --quiet"
+exec AS_MESSAGE_LOG_FD>/dev/null
+$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
+exec AS_MESSAGE_LOG_FD>>config.log
+$lt_cl_success || AS_EXIT(1)
 ])# LT_OUTPUT
 
 
@@ -717,15 +751,12 @@ _LT_EOF
   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
   # text mode, it properly converts lines to CR/LF.  This bash problem
   # is reportedly fixed, but why not run on old versions too?
-  sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
-    || (rm -f "$cfgfile"; exit 1)
+  sed '$q' "$ltmain" >> "$cfgfile" \
+     || (rm -f "$cfgfile"; exit 1)
 
-  _LT_PROG_XSI_SHELLFNS
+  _LT_PROG_REPLACE_SHELLFNS
 
-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
-    || (rm -f "$cfgfile"; exit 1)
-
-  mv -f "$cfgfile" "$ofile" ||
+   mv -f "$cfgfile" "$ofile" ||
     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
   chmod +x "$ofile"
 ],
@@ -831,11 +862,13 @@ AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
 AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
 AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
 AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
+AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
 dnl aclocal-1.4 backwards compatibility:
 dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
 dnl AC_DEFUN([AC_LIBTOOL_F77], [])
 dnl AC_DEFUN([AC_LIBTOOL_FC], [])
 dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
+dnl AC_DEFUN([AC_LIBTOOL_RC], [])
 
 
 # _LT_TAG_COMPILER
@@ -940,6 +973,31 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
 	[lt_cv_ld_exported_symbols_list=no])
 	LDFLAGS="$save_LDFLAGS"
     ])
+    AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
+      [lt_cv_ld_force_load=no
+      cat > conftest.c << _LT_EOF
+int forced_loaded() { return 2;}
+_LT_EOF
+      echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
+      $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
+      echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
+      $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
+      echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
+      $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
+      cat > conftest.c << _LT_EOF
+int main() { return 0;}
+_LT_EOF
+      echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
+      $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
+      _lt_result=$?
+      if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
+	lt_cv_ld_force_load=yes
+      else
+	cat conftest.err >&AS_MESSAGE_LOG_FD
+      fi
+        rm -f conftest.err libconftest.a conftest conftest.c
+        rm -rf conftest.dSYM
+    ])
     case $host_os in
     rhapsody* | darwin1.[[012]])
       _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
@@ -967,7 +1025,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
     else
       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
     fi
-    if test "$DSYMUTIL" != ":"; then
+    if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
       _lt_dsymutil='~$DSYMUTIL $lib || :'
     else
       _lt_dsymutil=
@@ -987,7 +1045,11 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
   _LT_TAGVAR(hardcode_direct, $1)=no
   _LT_TAGVAR(hardcode_automatic, $1)=yes
   _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
-  _LT_TAGVAR(whole_archive_flag_spec, $1)=''
+  if test "$lt_cv_ld_force_load" = "yes"; then
+    _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+  else
+    _LT_TAGVAR(whole_archive_flag_spec, $1)=''
+  fi
   _LT_TAGVAR(link_all_deplibs, $1)=yes
   _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
   case $cc_basename in
@@ -995,7 +1057,7 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
      *) _lt_dar_can_shared=$GCC ;;
   esac
   if test "$_lt_dar_can_shared" = "yes"; then
-    output_verbose_link_cmd=echo
+    output_verbose_link_cmd=func_echo_all
     _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
     _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
     _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
@@ -1011,203 +1073,142 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
   fi
 ])
 
-# _LT_SYS_MODULE_PATH_AIX
-# -----------------------
+# _LT_SYS_MODULE_PATH_AIX([TAGNAME])
+# ----------------------------------
 # Links a minimal program and checks the executable
 # for the system default hardcoded library path. In most cases,
 # this is /usr/lib:/lib, but when the MPI compilers are used
 # the location of the communication and MPI libs are included too.
 # If we don't find anything, use the default library path according
 # to the aix ld manual.
+# Store the results from the different compilers for each TAGNAME.
+# Allow to override them for all tags through lt_cv_aix_libpath.
 m4_defun([_LT_SYS_MODULE_PATH_AIX],
 [m4_require([_LT_DECL_SED])dnl
-AC_LINK_IFELSE(AC_LANG_PROGRAM,[
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi],[])
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+if test "${lt_cv_aix_libpath+set}" = set; then
+  aix_libpath=$lt_cv_aix_libpath
+else
+  AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
+  [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
+  lt_aix_libpath_sed='[
+      /Import File Strings/,/^$/ {
+	  /^0/ {
+	      s/^0  *\([^ ]*\) *$/\1/
+	      p
+	  }
+      }]'
+  _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  # Check for a 64-bit object if we didn't find anything.
+  if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
+    _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  fi],[])
+  if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
+    _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
+  fi
+  ])
+  aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
+fi
 ])# _LT_SYS_MODULE_PATH_AIX
 
 
 # _LT_SHELL_INIT(ARG)
 # -------------------
 m4_define([_LT_SHELL_INIT],
-[ifdef([AC_DIVERSION_NOTICE],
-	     [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
-	 [AC_DIVERT_PUSH(NOTICE)])
-$1
-AC_DIVERT_POP
-])# _LT_SHELL_INIT
+[m4_divert_text([M4SH-INIT], [$1
+])])# _LT_SHELL_INIT
+
 
 
 # _LT_PROG_ECHO_BACKSLASH
 # -----------------------
-# Add some code to the start of the generated configure script which
-# will find an echo command which doesn't interpret backslashes.
+# Find how we can fake an echo command that does not interpret backslash.
+# In particular, with Autoconf 2.60 or later we add some code to the start
+# of the generated configure script which will find a shell with a builtin
+# printf (which we can use as an echo command).
 m4_defun([_LT_PROG_ECHO_BACKSLASH],
-[_LT_SHELL_INIT([
-# Check that we are running under the correct shell.
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-case X$lt_ECHO in
-X*--fallback-echo)
-  # Remove one level of quotation (which was required for Make).
-  ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
-  ;;
-esac
-
-ECHO=${lt_ECHO-echo}
-if test "X[$]1" = X--no-reexec; then
-  # Discard the --no-reexec flag, and continue.
-  shift
-elif test "X[$]1" = X--fallback-echo; then
-  # Avoid inline document here, it may be left over
-  :
-elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
-  # Yippee, $ECHO works!
-  :
+[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
+ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+
+AC_MSG_CHECKING([how to print strings])
+# Test print first, because it will be a builtin if present.
+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
+   test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
+  ECHO='print -r --'
+elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
+  ECHO='printf %s\n'
 else
-  # Restart under the correct shell.
-  exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
-fi
-
-if test "X[$]1" = X--fallback-echo; then
-  # used as fallback echo
-  shift
-  cat <<_LT_EOF
-[$]*
-_LT_EOF
-  exit 0
+  # Use this function as a fallback that always works.
+  func_fallback_echo ()
+  {
+    eval 'cat <<_LTECHO_EOF
+$[]1
+_LTECHO_EOF'
+  }
+  ECHO='func_fallback_echo'
 fi
 
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-if test -z "$lt_ECHO"; then
-  if test "X${echo_test_string+set}" != Xset; then
-    # find a string as large as possible, as long as the shell can cope with it
-    for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
-      # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
-      if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
-	 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
-      then
-        break
-      fi
-    done
-  fi
-
-  if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
-     echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
-     test "X$echo_testing_string" = "X$echo_test_string"; then
-    :
-  else
-    # The Solaris, AIX, and Digital Unix default echo programs unquote
-    # backslashes.  This makes it impossible to quote backslashes using
-    #   echo "$something" | sed 's/\\/\\\\/g'
-    #
-    # So, first we look for a working echo in the user's PATH.
-
-    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-    for dir in $PATH /usr/ucb; do
-      IFS="$lt_save_ifs"
-      if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
-         test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
-         echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
-         test "X$echo_testing_string" = "X$echo_test_string"; then
-        ECHO="$dir/echo"
-        break
-      fi
-    done
-    IFS="$lt_save_ifs"
-
-    if test "X$ECHO" = Xecho; then
-      # We didn't find a better echo, so look for alternatives.
-      if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
-         echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
-         test "X$echo_testing_string" = "X$echo_test_string"; then
-        # This shell has a builtin print -r that does the trick.
-        ECHO='print -r'
-      elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
-	   test "X$CONFIG_SHELL" != X/bin/ksh; then
-        # If we have ksh, try running configure again with it.
-        ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
-        export ORIGINAL_CONFIG_SHELL
-        CONFIG_SHELL=/bin/ksh
-        export CONFIG_SHELL
-        exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
-      else
-        # Try using printf.
-        ECHO='printf %s\n'
-        if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
-	   echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
-	   test "X$echo_testing_string" = "X$echo_test_string"; then
-	  # Cool, printf works
-	  :
-        elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
-	     test "X$echo_testing_string" = 'X\t' &&
-	     echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
-	     test "X$echo_testing_string" = "X$echo_test_string"; then
-	  CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
-	  export CONFIG_SHELL
-	  SHELL="$CONFIG_SHELL"
-	  export SHELL
-	  ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
-        elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
-	     test "X$echo_testing_string" = 'X\t' &&
-	     echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
-	     test "X$echo_testing_string" = "X$echo_test_string"; then
-	  ECHO="$CONFIG_SHELL [$]0 --fallback-echo"
-        else
-	  # maybe with a smaller string...
-	  prev=:
-
-	  for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
-	    if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
-	    then
-	      break
-	    fi
-	    prev="$cmd"
-	  done
+# func_echo_all arg...
+# Invoke $ECHO with all args, space-separated.
+func_echo_all ()
+{
+    $ECHO "$*" 
+}
 
-	  if test "$prev" != 'sed 50q "[$]0"'; then
-	    echo_test_string=`eval $prev`
-	    export echo_test_string
-	    exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
-	  else
-	    # Oops.  We lost completely, so just stick with echo.
-	    ECHO=echo
-	  fi
-        fi
-      fi
-    fi
-  fi
-fi
+case "$ECHO" in
+  printf*) AC_MSG_RESULT([printf]) ;;
+  print*) AC_MSG_RESULT([print -r]) ;;
+  *) AC_MSG_RESULT([cat]) ;;
+esac
 
-# Copy echo and quote the copy suitably for passing to libtool from
-# the Makefile, instead of quoting the original, which is used later.
-lt_ECHO=$ECHO
-if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
-   lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
-fi
+m4_ifdef([_AS_DETECT_SUGGESTED],
+[_AS_DETECT_SUGGESTED([
+  test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
+    ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+    ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
+    ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+    PATH=/empty FPATH=/empty; export PATH FPATH
+    test "X`printf %s $ECHO`" = "X$ECHO" \
+      || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
 
-AC_SUBST(lt_ECHO)
-])
 _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
-_LT_DECL([], [ECHO], [1],
-    [An echo program that does not interpret backslashes])
+_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
 ])# _LT_PROG_ECHO_BACKSLASH
 
 
+# _LT_WITH_SYSROOT
+# ----------------
+AC_DEFUN([_LT_WITH_SYSROOT],
+[AC_MSG_CHECKING([for sysroot])
+AC_ARG_WITH([sysroot],
+[  --with-sysroot[=DIR] Search for dependent libraries within DIR
+                        (or the compiler's sysroot if not specified).],
+[], [with_sysroot=no])
+
+dnl lt_sysroot will always be passed unquoted.  We quote it here
+dnl in case the user passed a directory name.
+lt_sysroot=
+case ${with_sysroot} in #(
+ yes)
+   if test "$GCC" = yes; then
+     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
+   fi
+   ;; #(
+ /*)
+   lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
+   ;; #(
+ no|'')
+   ;; #(
+ *)
+   AC_MSG_RESULT([${with_sysroot}])
+   AC_MSG_ERROR([The sysroot must be an absolute path.])
+   ;;
+esac
+
+ AC_MSG_RESULT([${lt_sysroot:-no}])
+_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
+[dependent libraries, and in which our libraries should be installed.])])
+
 # _LT_ENABLE_LOCK
 # ---------------
 m4_defun([_LT_ENABLE_LOCK],
@@ -1236,7 +1237,7 @@ ia64-*-hpux*)
   ;;
 *-*-irix6*)
   # Find out which ABI we are using.
-  echo '[#]line __oline__ "configure"' > conftest.$ac_ext
+  echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
   if AC_TRY_EVAL(ac_compile); then
     if test "$lt_cv_prog_gnu_ld" = yes; then
       case `/usr/bin/file conftest.$ac_objext` in
@@ -1354,14 +1355,47 @@ need_locks="$enable_libtool_lock"
 ])# _LT_ENABLE_LOCK
 
 
+# _LT_PROG_AR
+# -----------
+m4_defun([_LT_PROG_AR],
+[AC_CHECK_TOOLS(AR, [ar], false)
+: ${AR=ar}
+: ${AR_FLAGS=cru}
+_LT_DECL([], [AR], [1], [The archiver])
+_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
+
+AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
+  [lt_cv_ar_at_file=no
+   AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
+     [echo conftest.$ac_objext > conftest.lst
+      lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
+      AC_TRY_EVAL([lt_ar_try])
+      if test "$ac_status" -eq 0; then
+	# Ensure the archiver fails upon bogus file names.
+	rm -f conftest.$ac_objext libconftest.a
+	AC_TRY_EVAL([lt_ar_try])
+	if test "$ac_status" -ne 0; then
+          lt_cv_ar_at_file=@
+        fi
+      fi
+      rm -f conftest.* libconftest.a
+     ])
+  ])
+
+if test "x$lt_cv_ar_at_file" = xno; then
+  archiver_list_spec=
+else
+  archiver_list_spec=$lt_cv_ar_at_file
+fi
+_LT_DECL([], [archiver_list_spec], [1],
+  [How to feed a file listing to the archiver])
+])# _LT_PROG_AR
+
+
 # _LT_CMD_OLD_ARCHIVE
 # -------------------
 m4_defun([_LT_CMD_OLD_ARCHIVE],
-[AC_CHECK_TOOL(AR, ar, false)
-test -z "$AR" && AR=ar
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-_LT_DECL([], [AR], [1], [The archiver])
-_LT_DECL([], [AR_FLAGS], [1])
+[_LT_PROG_AR
 
 AC_CHECK_TOOL(STRIP, strip, :)
 test -z "$STRIP" && STRIP=:
@@ -1388,10 +1422,19 @@ if test -n "$RANLIB"; then
   esac
   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
 fi
+
+case $host_os in
+  darwin*)
+    lock_old_archive_extraction=yes ;;
+  *)
+    lock_old_archive_extraction=no ;;
+esac
 _LT_DECL([], [old_postinstall_cmds], [2])
 _LT_DECL([], [old_postuninstall_cmds], [2])
 _LT_TAGDECL([], [old_archive_cmds], [2],
     [Commands used to build an old-style archive])
+_LT_DECL([], [lock_old_archive_extraction], [0],
+    [Whether to use a lock for old archive extraction])
 ])# _LT_CMD_OLD_ARCHIVE
 
 
@@ -1416,15 +1459,15 @@ AC_CACHE_CHECK([$1], [$2],
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&AS_MESSAGE_LOG_FD
-   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
+   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        $2=yes
@@ -1464,7 +1507,7 @@ AC_CACHE_CHECK([$1], [$2],
      if test -s conftest.err; then
        # Append any errors to the config.log.
        cat conftest.err 1>&AS_MESSAGE_LOG_FD
-       $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
        if diff conftest.exp conftest.er2 >/dev/null; then
          $2=yes
@@ -1527,6 +1570,11 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
     lt_cv_sys_max_cmd_len=8192;
     ;;
 
+  mint*)
+    # On MiNT this can take a long time and run out of memory.
+    lt_cv_sys_max_cmd_len=8192;
+    ;;
+
   amigaos*)
     # On AmigaOS with pdksh, this test takes hours, literally.
     # So we just punt and use a minimum line length of 8192.
@@ -1591,8 +1639,8 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
       # If test is not a shell built-in, we'll probably end up computing a
       # maximum length that is only half of the actual maximum length, but
       # we can't tell.
-      while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
-	         = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
+      while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
+	         = "X$teststring$teststring"; } >/dev/null 2>&1 &&
 	      test $i != 17 # 1/2 MB should be enough
       do
         i=`expr $i + 1`
@@ -1643,7 +1691,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-[#line __oline__ "configure"
+[#line $LINENO "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -1684,7 +1732,13 @@ else
 #  endif
 #endif
 
-void fnord() { int i=42;}
+/* When -fvisbility=hidden is used, assume the code has been annotated
+   correspondingly for the symbols needed.  */
+#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
+int fnord () __attribute__((visibility("default")));
+#endif
+
+int fnord () { return 42; }
 int main ()
 {
   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
@@ -1693,7 +1747,11 @@ int main ()
   if (self)
     {
       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
-      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
+      else
+        {
+	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
+          else puts (dlerror ());
+	}
       /* dlclose (self); */
     }
   else
@@ -1869,16 +1927,16 @@ AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&AS_MESSAGE_LOG_FD
-   echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
+   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
@@ -2037,6 +2095,7 @@ m4_require([_LT_DECL_EGREP])dnl
 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
 m4_require([_LT_DECL_OBJDUMP])dnl
 m4_require([_LT_DECL_SED])dnl
+m4_require([_LT_CHECK_SHELL_FEATURES])dnl
 AC_MSG_CHECKING([dynamic linker characteristics])
 m4_if([$1],
 	[], [
@@ -2045,16 +2104,23 @@ if test "$GCC" = yes; then
     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
     *) lt_awk_arg="/^libraries:/" ;;
   esac
-  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-  if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
+  case $host_os in
+    mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
+    *) lt_sed_strip_eq="s,=/,/,g" ;;
+  esac
+  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
+  case $lt_search_path_spec in
+  *\;*)
     # if the path contains ";" then we assume it to be the separator
     # otherwise default to the standard path separator (i.e. ":") - it is
     # assumed that no part of a normal pathname contains ";" but that should
     # okay in the real world where ";" in dirpaths is itself problematic.
-    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
-  else
-    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-  fi
+    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
+    ;;
+  *)
+    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
+    ;;
+  esac
   # Ok, now we have the path, separated by spaces, we can step through it
   # and add multilib dir if necessary.
   lt_tmp_lt_search_path_spec=
@@ -2067,7 +2133,7 @@ if test "$GCC" = yes; then
 	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
     fi
   done
-  lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
+  lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
 BEGIN {RS=" "; FS="/|\n";} {
   lt_foo="";
   lt_count=0;
@@ -2087,7 +2153,13 @@ BEGIN {RS=" "; FS="/|\n";} {
   if (lt_foo != "") { lt_freq[[lt_foo]]++; }
   if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
 }'`
-  sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
+  # AWK program above erroneously prepends '/' to C:/dos/paths
+  # for these hosts.
+  case $host_os in
+    mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
+      $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
+  esac
+  sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
 else
   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
 fi])
@@ -2175,7 +2247,7 @@ amigaos*)
   m68k)
     library_names_spec='$libname.ixlibrary $libname.a'
     # Create ${libname}_ixlibrary.a entries in /sys/libs.
-    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
+    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
     ;;
   esac
   ;;
@@ -2206,8 +2278,9 @@ cygwin* | mingw* | pw32* | cegcc*)
   need_version=no
   need_lib_prefix=no
 
-  case $GCC,$host_os in
-  yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
+  case $GCC,$cc_basename in
+  yes,*)
+    # gcc
     library_names_spec='$libname.dll.a'
     # DLL is installed to $(libdir)/../bin by postinstall_cmds
     postinstall_cmds='base_file=`basename \${file}`~
@@ -2228,36 +2301,83 @@ cygwin* | mingw* | pw32* | cegcc*)
     cygwin*)
       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+m4_if([$1], [],[
+      sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
       ;;
     mingw* | cegcc*)
       # MinGW DLLs use traditional 'lib' prefix
       soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-      if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
-        # It is most probably a Windows format PATH printed by
-        # mingw gcc, but we are running on Cygwin. Gcc prints its search
-        # path with ; separators, and with drive letters. We can handle the
-        # drive letters (cygwin fileutils understands them), so leave them,
-        # especially as we might pass files found there to a mingw objdump,
-        # which wouldn't understand a cygwinified path. Ahh.
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
-      else
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-      fi
       ;;
     pw32*)
       # pw32 DLLs use 'pw' prefix rather than 'lib'
       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
       ;;
     esac
+    dynamic_linker='Win32 ld.exe'
+    ;;
+
+  *,cl*)
+    # Native MSVC
+    libname_spec='$name'
+    soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
+    library_names_spec='${libname}.dll.lib'
+
+    case $build_os in
+    mingw*)
+      sys_lib_search_path_spec=
+      lt_save_ifs=$IFS
+      IFS=';'
+      for lt_path in $LIB
+      do
+        IFS=$lt_save_ifs
+        # Let DOS variable expansion print the short 8.3 style file name.
+        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
+        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
+      done
+      IFS=$lt_save_ifs
+      # Convert to MSYS style.
+      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
+      ;;
+    cygwin*)
+      # Convert to unix form, then to dos form, then back to unix form
+      # but this time dos style (no spaces!) so that the unix form looks
+      # like /cygdrive/c/PROGRA~1:/cygdr...
+      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
+      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
+      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      ;;
+    *)
+      sys_lib_search_path_spec="$LIB"
+      if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
+        # It is most probably a Windows format PATH.
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
+      else
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      fi
+      # FIXME: find the short name or the path components, as spaces are
+      # common. (e.g. "Program Files" -> "PROGRA~1")
+      ;;
+    esac
+
+    # DLL is installed to $(libdir)/../bin by postinstall_cmds
+    postinstall_cmds='base_file=`basename \${file}`~
+      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
+      dldir=$destdir/`dirname \$dlpath`~
+      test -d \$dldir || mkdir -p \$dldir~
+      $install_prog $dir/$dlname \$dldir/$dlname'
+    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
+      dlpath=$dir/\$dldll~
+       $RM \$dlpath'
+    shlibpath_overrides_runpath=yes
+    dynamic_linker='Win32 link.exe'
     ;;
 
   *)
+    # Assume MSVC wrapper
     library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
+    dynamic_linker='Win32 ld.exe'
     ;;
   esac
-  dynamic_linker='Win32 ld.exe'
   # FIXME: first we should search . and the directory the executable is in
   shlibpath_var=PATH
   ;;
@@ -2344,6 +2464,19 @@ gnu*)
   hardcode_into_libs=yes
   ;;
 
+haiku*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  dynamic_linker="$host_os runtime_loader"
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LIBRARY_PATH
+  shlibpath_overrides_runpath=yes
+  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
+  hardcode_into_libs=yes
+  ;;
+
 hpux9* | hpux10* | hpux11*)
   # Give a soname corresponding to the major version so that dld.sl refuses to
   # link against other versions.
@@ -2386,8 +2519,10 @@ hpux9* | hpux10* | hpux11*)
     soname_spec='${libname}${release}${shared_ext}$major'
     ;;
   esac
-  # HP-UX runs *really* slowly unless shared libraries are mode 555.
+  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
   postinstall_cmds='chmod 555 $lib'
+  # or fails outright, so override atomically:
+  install_override_mode=555
   ;;
 
 interix[[3-9]]*)
@@ -2445,7 +2580,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux* | k*bsd*-gnu)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -2454,16 +2589,21 @@ linux* | k*bsd*-gnu)
   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
   shlibpath_var=LD_LIBRARY_PATH
   shlibpath_overrides_runpath=no
+
   # Some binutils ld are patched to set DT_RUNPATH
-  save_LDFLAGS=$LDFLAGS
-  save_libdir=$libdir
-  eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
-       LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
-  AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
-    [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
-       [shlibpath_overrides_runpath=yes])])
-  LDFLAGS=$save_LDFLAGS
-  libdir=$save_libdir
+  AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
+    [lt_cv_shlibpath_overrides_runpath=no
+    save_LDFLAGS=$LDFLAGS
+    save_libdir=$libdir
+    eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
+	 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
+    AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
+      [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
+	 [lt_cv_shlibpath_overrides_runpath=yes])])
+    LDFLAGS=$save_LDFLAGS
+    libdir=$save_libdir
+    ])
+  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
 
   # This implies no fast_install, which is unacceptable.
   # Some rework will be needed to allow for fast_install
@@ -2472,7 +2612,7 @@ linux* | k*bsd*-gnu)
 
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
@@ -2705,6 +2845,8 @@ _LT_DECL([], [library_names_spec], [1],
     The last name is the one that the linker finds with -lNAME]])
 _LT_DECL([], [soname_spec], [1],
     [[The coded name of the library, if different from the real name]])
+_LT_DECL([], [install_override_mode], [1],
+    [Permission mode override for installation of shared libraries])
 _LT_DECL([], [postinstall_cmds], [2],
     [Command to use after installation of a shared archive])
 _LT_DECL([], [postuninstall_cmds], [2],
@@ -2817,6 +2959,7 @@ AC_REQUIRE([AC_CANONICAL_HOST])dnl
 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
 m4_require([_LT_DECL_SED])dnl
 m4_require([_LT_DECL_EGREP])dnl
+m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
 
 AC_ARG_WITH([gnu-ld],
     [AS_HELP_STRING([--with-gnu-ld],
@@ -2938,6 +3081,11 @@ case $reload_flag in
 esac
 reload_cmds='$LD$reload_flag -o $output$reload_objs'
 case $host_os in
+  cygwin* | mingw* | pw32* | cegcc*)
+    if test "$GCC" != yes; then
+      reload_cmds=false
+    fi
+    ;;
   darwin*)
     if test "$GCC" = yes; then
       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
@@ -2946,8 +3094,8 @@ case $host_os in
     fi
     ;;
 esac
-_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl
-_LT_DECL([], [reload_cmds], [2])dnl
+_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
+_LT_TAGDECL([], [reload_cmds], [2])dnl
 ])# _LT_CMD_RELOAD
 
 
@@ -2999,16 +3147,18 @@ mingw* | pw32*)
   # Base MSYS/MinGW do not provide the 'file' command needed by
   # func_win32_libid shell function, so use a weaker test based on 'objdump',
   # unless we find 'file', for example because we are cross-compiling.
-  if ( file / ) >/dev/null 2>&1; then
+  # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
+  if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
     lt_cv_file_magic_cmd='func_win32_libid'
   else
-    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
+    # Keep this pattern in sync with the one in func_win32_libid.
+    lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
     lt_cv_file_magic_cmd='$OBJDUMP -f'
   fi
   ;;
 
-cegcc)
+cegcc*)
   # use the weaker test based on 'objdump'. See mingw*.
   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
   lt_cv_file_magic_cmd='$OBJDUMP -f'
@@ -3038,6 +3188,10 @@ gnu*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
+haiku*)
+  lt_cv_deplibs_check_method=pass_all
+  ;;
+
 hpux10.20* | hpux11*)
   lt_cv_file_magic_cmd=/usr/bin/file
   case $host_cpu in
@@ -3046,11 +3200,11 @@ hpux10.20* | hpux11*)
     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
     ;;
   hppa*64*)
-    [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
+    [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
     ;;
   *)
-    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
+    lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
     lt_cv_file_magic_test_file=/usr/lib/libc.sl
     ;;
   esac
@@ -3072,7 +3226,7 @@ irix5* | irix6* | nonstopux*)
   ;;
 
 # This must be Linux ELF.
-linux* | k*bsd*-gnu)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -3150,6 +3304,21 @@ tpf*)
   ;;
 esac
 ])
+
+file_magic_glob=
+want_nocaseglob=no
+if test "$build" = "$host"; then
+  case $host_os in
+  mingw* | pw32*)
+    if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
+      want_nocaseglob=yes
+    else
+      file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
+    fi
+    ;;
+  esac
+fi
+
 file_magic_cmd=$lt_cv_file_magic_cmd
 deplibs_check_method=$lt_cv_deplibs_check_method
 test -z "$deplibs_check_method" && deplibs_check_method=unknown
@@ -3157,7 +3326,11 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
 _LT_DECL([], [deplibs_check_method], [1],
     [Method to check whether dependent libraries are shared objects])
 _LT_DECL([], [file_magic_cmd], [1],
-    [Command to use when deplibs_check_method == "file_magic"])
+    [Command to use when deplibs_check_method = "file_magic"])
+_LT_DECL([], [file_magic_glob], [1],
+    [How to find potential files when deplibs_check_method = "file_magic"])
+_LT_DECL([], [want_nocaseglob], [1],
+    [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
 ])# _LT_CHECK_MAGIC_METHOD
 
 
@@ -3214,7 +3387,19 @@ if test "$lt_cv_path_NM" != "no"; then
   NM="$lt_cv_path_NM"
 else
   # Didn't find any BSD compatible name lister, look for dumpbin.
-  AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :)
+  if test -n "$DUMPBIN"; then :
+    # Let the user override the test.
+  else
+    AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
+    case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
+    *COFF*)
+      DUMPBIN="$DUMPBIN -symbols"
+      ;;
+    *)
+      DUMPBIN=:
+      ;;
+    esac
+  fi
   AC_SUBST([DUMPBIN])
   if test "$DUMPBIN" != ":"; then
     NM="$DUMPBIN"
@@ -3227,13 +3412,13 @@ _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
 AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
   [lt_cv_nm_interface="BSD nm"
   echo "int some_variable = 0;" > conftest.$ac_ext
-  (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
+  (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
   (eval "$ac_compile" 2>conftest.err)
   cat conftest.err >&AS_MESSAGE_LOG_FD
-  (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
+  (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
   cat conftest.err >&AS_MESSAGE_LOG_FD
-  (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD)
+  (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
   cat conftest.out >&AS_MESSAGE_LOG_FD
   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
     lt_cv_nm_interface="MS dumpbin"
@@ -3248,6 +3433,67 @@ dnl aclocal-1.4 backwards compatibility:
 dnl AC_DEFUN([AM_PROG_NM], [])
 dnl AC_DEFUN([AC_PROG_NM], [])
 
+# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
+# --------------------------------
+# how to determine the name of the shared library
+# associated with a specific link library.
+#  -- PORTME fill in with the dynamic library characteristics
+m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
+[m4_require([_LT_DECL_EGREP])
+m4_require([_LT_DECL_OBJDUMP])
+m4_require([_LT_DECL_DLLTOOL])
+AC_CACHE_CHECK([how to associate runtime and link libraries],
+lt_cv_sharedlib_from_linklib_cmd,
+[lt_cv_sharedlib_from_linklib_cmd='unknown'
+
+case $host_os in
+cygwin* | mingw* | pw32* | cegcc*)
+  # two different shell functions defined in ltmain.sh
+  # decide which to use based on capabilities of $DLLTOOL
+  case `$DLLTOOL --help 2>&1` in
+  *--identify-strict*)
+    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
+    ;;
+  *)
+    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
+    ;;
+  esac
+  ;;
+*)
+  # fallback: assume linklib IS sharedlib
+  lt_cv_sharedlib_from_linklib_cmd="$ECHO"
+  ;;
+esac
+])
+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
+
+_LT_DECL([], [sharedlib_from_linklib_cmd], [1],
+    [Command to associate shared and link libraries])
+])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
+
+
+# _LT_PATH_MANIFEST_TOOL
+# ----------------------
+# locate the manifest tool
+m4_defun([_LT_PATH_MANIFEST_TOOL],
+[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
+AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
+  [lt_cv_path_mainfest_tool=no
+  echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
+  $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
+  cat conftest.err >&AS_MESSAGE_LOG_FD
+  if $GREP 'Manifest Tool' conftest.out > /dev/null; then
+    lt_cv_path_mainfest_tool=yes
+  fi
+  rm -f conftest*])
+if test "x$lt_cv_path_mainfest_tool" != xyes; then
+  MANIFEST_TOOL=:
+fi
+_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
+])# _LT_PATH_MANIFEST_TOOL
+
 
 # LT_LIB_M
 # --------
@@ -3256,7 +3502,7 @@ AC_DEFUN([LT_LIB_M],
 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
 LIBM=
 case $host in
-*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
+*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
   # These system don't have libm, or don't need it
   ;;
 *-ncr-sysv4.3*)
@@ -3284,7 +3530,12 @@ m4_defun([_LT_COMPILER_NO_RTTI],
 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
 
 if test "$GCC" = yes; then
-  _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
+  case $cc_basename in
+  nvcc*)
+    _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
+  *)
+    _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
+  esac
 
   _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
     lt_cv_prog_compiler_rtti_exceptions,
@@ -3301,6 +3552,7 @@ _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
 m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
 AC_REQUIRE([AC_PROG_CC])dnl
+AC_REQUIRE([AC_PROG_AWK])dnl
 AC_REQUIRE([LT_PATH_NM])dnl
 AC_REQUIRE([LT_PATH_LD])dnl
 m4_require([_LT_DECL_SED])dnl
@@ -3368,8 +3620,8 @@ esac
 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
 
 # Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p'"
+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
 
 # Handle CRLF in mingw tool chain
 opt_cr=
@@ -3405,6 +3657,7 @@ for ac_symprfx in "" "_"; do
   else
     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[	 ]]\($symcode$symcode*\)[[	 ]][[	 ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
   fi
+  lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
 
   # Check to see that the pipe works correctly.
   pipe_works=no
@@ -3426,7 +3679,7 @@ _LT_EOF
   if AC_TRY_EVAL(ac_compile); then
     # Now try to grab the symbols.
     nlist=conftest.nm
-    if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
+    if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
       # Try sorting and uniquifying the output.
       if sort "$nlist" | uniq > "$nlist"T; then
 	mv -f "$nlist"T "$nlist"
@@ -3438,6 +3691,18 @@ _LT_EOF
       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
 	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
 	  cat <<_LT_EOF > conftest.$ac_ext
+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
+/* DATA imports from DLLs on WIN32 con't be const, because runtime
+   relocations are performed -- see ld's documentation on pseudo-relocs.  */
+# define LT@&t at _DLSYM_CONST
+#elif defined(__osf__)
+/* This system does not cope well with relocations in const data.  */
+# define LT@&t at _DLSYM_CONST
+#else
+# define LT@&t at _DLSYM_CONST const
+#endif
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -3449,7 +3714,7 @@ _LT_EOF
 	  cat <<_LT_EOF >> conftest.$ac_ext
 
 /* The mapping between symbol names and symbols.  */
-const struct {
+LT@&t at _DLSYM_CONST struct {
   const char *name;
   void       *address;
 }
@@ -3475,15 +3740,15 @@ static const void *lt_preloaded_setup() {
 _LT_EOF
 	  # Now try linking the two files.
 	  mv conftest.$ac_objext conftstm.$ac_objext
-	  lt_save_LIBS="$LIBS"
-	  lt_save_CFLAGS="$CFLAGS"
+	  lt_globsym_save_LIBS=$LIBS
+	  lt_globsym_save_CFLAGS=$CFLAGS
 	  LIBS="conftstm.$ac_objext"
 	  CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
 	  if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
 	    pipe_works=yes
 	  fi
-	  LIBS="$lt_save_LIBS"
-	  CFLAGS="$lt_save_CFLAGS"
+	  LIBS=$lt_globsym_save_LIBS
+	  CFLAGS=$lt_globsym_save_CFLAGS
 	else
 	  echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
 	fi
@@ -3516,6 +3781,13 @@ else
   AC_MSG_RESULT(ok)
 fi
 
+# Response file support.
+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
+  nm_file_list_spec='@'
+elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
+  nm_file_list_spec='@'
+fi
+
 _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
     [Take the output of nm and produce a listing of raw symbols and C names])
 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
@@ -3526,6 +3798,8 @@ _LT_DECL([global_symbol_to_c_name_address],
 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
     [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
     [Transform the output of nm in a C name address pair when lib prefix is needed])
+_LT_DECL([], [nm_file_list_spec], [1],
+    [Specify filename containing input files for $NM])
 ]) # _LT_CMD_GLOBAL_SYMBOLS
 
 
@@ -3537,7 +3811,6 @@ _LT_TAGVAR(lt_prog_compiler_wl, $1)=
 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
 _LT_TAGVAR(lt_prog_compiler_static, $1)=
 
-AC_MSG_CHECKING([for $compiler option to produce PIC])
 m4_if([$1], [CXX], [
   # C++ specific cases for pic, static, wl, etc.
   if test "$GXX" = yes; then
@@ -3588,6 +3861,11 @@ m4_if([$1], [CXX], [
       # DJGPP does not support shared libraries at all
       _LT_TAGVAR(lt_prog_compiler_pic, $1)=
       ;;
+    haiku*)
+      # PIC is the default for Haiku.
+      # The "-static" flag exists, but is broken.
+      _LT_TAGVAR(lt_prog_compiler_static, $1)=
+      ;;
     interix[[3-9]]*)
       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
       # Instead, we relocate shared libraries at runtime.
@@ -3637,6 +3915,12 @@ m4_if([$1], [CXX], [
 	  ;;
 	esac
 	;;
+      mingw* | cygwin* | os2* | pw32* | cegcc*)
+	# This hack is so that the source file can tell whether it is being
+	# built for inclusion in a dll (and should export symbols for example).
+	m4_if([$1], [GCJ], [],
+	  [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
+	;;
       dgux*)
 	case $cc_basename in
 	  ec++*)
@@ -3693,7 +3977,7 @@ m4_if([$1], [CXX], [
 	    ;;
 	esac
 	;;
-      linux* | k*bsd*-gnu)
+      linux* | k*bsd*-gnu | kopensolaris*-gnu)
 	case $cc_basename in
 	  KCC*)
 	    # KAI C++ Compiler
@@ -3726,8 +4010,8 @@ m4_if([$1], [CXX], [
 	    _LT_TAGVAR(lt_prog_compiler_pic, $1)=
 	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 	    ;;
-	  xlc* | xlC*)
-	    # IBM XL 8.0 on PPC
+	  xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
+	    # IBM XL 8.0, 9.0 on PPC and BlueGene
 	    _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
 	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
@@ -3789,7 +4073,7 @@ m4_if([$1], [CXX], [
 	;;
       solaris*)
 	case $cc_basename in
-	  CC*)
+	  CC* | sunCC*)
 	    # Sun C++ 4.2, 5.x and Centerline C++
 	    _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 	    _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
@@ -3893,6 +4177,12 @@ m4_if([$1], [CXX], [
       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
       ;;
 
+    haiku*)
+      # PIC is the default for Haiku.
+      # The "-static" flag exists, but is broken.
+      _LT_TAGVAR(lt_prog_compiler_static, $1)=
+      ;;
+
     hpux*)
       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
@@ -3935,6 +4225,13 @@ m4_if([$1], [CXX], [
       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
       ;;
     esac
+
+    case $cc_basename in
+    nvcc*) # Cuda Compiler Driver 2.2
+      _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
+      _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC'
+      ;;
+    esac
   else
     # PORTME Check for flag to pass linker flags through the system compiler.
     case $host_os in
@@ -3977,7 +4274,7 @@ m4_if([$1], [CXX], [
       _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
       ;;
 
-    linux* | k*bsd*-gnu)
+    linux* | k*bsd*-gnu | kopensolaris*-gnu)
       case $cc_basename in
       # old Intel for x86_64 which still supported -KPIC.
       ecc*)
@@ -3998,7 +4295,13 @@ m4_if([$1], [CXX], [
 	_LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
 	_LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
 	;;
-      pgcc* | pgf77* | pgf90* | pgf95*)
+      nagfor*)
+	# NAG Fortran compiler
+	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
+	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
+	_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	;;
+      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
         # Portland Group compilers (*not* the Pentium gcc compiler,
 	# which looks to be a dead project)
 	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
@@ -4010,25 +4313,25 @@ m4_if([$1], [CXX], [
         # All Alpha code is PIC.
         _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
         ;;
-      xl*)
-	# IBM XL C 8.0/Fortran 10.1 on PPC
+      xl* | bgxl* | bgf* | mpixl*)
+	# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
 	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 	_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
 	_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
 	;;
       *)
 	case `$CC -V 2>&1 | sed 5q` in
-	*Sun\ C*)
-	  # Sun C 5.9
+	*Sun\ F* | *Sun*Fortran*)
+	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
 	  _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	  _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+	  _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
 	  ;;
-	*Sun\ F*)
-	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
+	*Sun\ C*)
+	  # Sun C 5.9
 	  _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
 	  _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
-	  _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
+	  _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 	  ;;
 	esac
 	;;
@@ -4060,7 +4363,7 @@ m4_if([$1], [CXX], [
       _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
       _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
       case $cc_basename in
-      f77* | f90* | f95*)
+      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
 	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
       *)
 	_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
@@ -4117,9 +4420,11 @@ case $host_os in
     _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t at m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
     ;;
 esac
-AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
-_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
-	[How to pass a linker flag through the compiler])
+
+AC_CACHE_CHECK([for $compiler option to produce PIC],
+  [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
+  [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
+_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
 
 #
 # Check to make sure the PIC flag actually works.
@@ -4138,6 +4443,8 @@ fi
 _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
 	[Additional compiler flags for building library objects])
 
+_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
+	[How to pass a linker flag through the compiler])
 #
 # Check to make sure the static flag actually works.
 #
@@ -4158,6 +4465,7 @@ _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
 m4_defun([_LT_LINKER_SHLIBS],
 [AC_REQUIRE([LT_PATH_LD])dnl
 AC_REQUIRE([LT_PATH_NM])dnl
+m4_require([_LT_PATH_MANIFEST_TOOL])dnl
 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
 m4_require([_LT_DECL_EGREP])dnl
 m4_require([_LT_DECL_SED])dnl
@@ -4166,27 +4474,35 @@ m4_require([_LT_TAG_COMPILER])dnl
 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
 m4_if([$1], [CXX], [
   _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
+  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
   case $host_os in
   aix[[4-9]]*)
     # If we're using GNU nm, then we don't want the "-C" option.
     # -C means demangle to AIX nm, but means don't demangle with GNU nm
+    # Also, AIX nm treats weak defined symbols like other global defined
+    # symbols, whereas GNU nm marks them as "W".
     if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
-      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
+      _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
     else
       _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
     fi
     ;;
   pw32*)
     _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
-  ;;
+    ;;
   cygwin* | mingw* | cegcc*)
-    _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
-  ;;
+    case $cc_basename in
+    cl*) ;;
+    *)
+      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
+      _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
+      ;;
+    esac
+    ;;
   *)
     _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
-  ;;
+    ;;
   esac
-  _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
 ], [
   runpath_var=
   _LT_TAGVAR(allow_undefined_flag, $1)=
@@ -4249,7 +4565,33 @@ dnl Note also adjust exclude_expsyms for C++ above.
   esac
 
   _LT_TAGVAR(ld_shlibs, $1)=yes
+
+  # On some targets, GNU ld is compatible enough with the native linker
+  # that we're better off using the native interface for both.
+  lt_use_gnu_ld_interface=no
   if test "$with_gnu_ld" = yes; then
+    case $host_os in
+      aix*)
+	# The AIX port of GNU ld has always aspired to compatibility
+	# with the native linker.  However, as the warning in the GNU ld
+	# block says, versions before 2.19.5* couldn't really create working
+	# shared libraries, regardless of the interface used.
+	case `$LD -v 2>&1` in
+	  *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
+	  *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
+	  *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
+	  *)
+	    lt_use_gnu_ld_interface=yes
+	    ;;
+	esac
+	;;
+      *)
+	lt_use_gnu_ld_interface=yes
+	;;
+    esac
+  fi
+
+  if test "$lt_use_gnu_ld_interface" = yes; then
     # If archive_cmds runs LD, not CC, wlarc should be empty
     wlarc='${wl}'
 
@@ -4267,6 +4609,7 @@ dnl Note also adjust exclude_expsyms for C++ above.
     fi
     supports_anon_versioning=no
     case `$LD -v 2>&1` in
+      *GNU\ gold*) supports_anon_versioning=yes ;;
       *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
@@ -4282,11 +4625,12 @@ dnl Note also adjust exclude_expsyms for C++ above.
 	_LT_TAGVAR(ld_shlibs, $1)=no
 	cat <<_LT_EOF 1>&2
 
-*** Warning: the GNU linker, at least up to release 2.9.1, is reported
+*** Warning: the GNU linker, at least up to release 2.19, is reported
 *** to be unable to reliably create shared libraries on AIX.
 *** Therefore, libtool is disabling shared libraries support.  If you
-*** really care for shared libraries, you may want to modify your PATH
-*** so that a non-GNU linker is found, and then restart.
+*** really care for shared libraries, you may want to install binutils
+*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
+*** You will then need to restart the configuration process.
 
 _LT_EOF
       fi
@@ -4322,10 +4666,12 @@ _LT_EOF
       # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
       # as there is no search path for DLLs.
       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
+      _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
       _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
       _LT_TAGVAR(always_export_symbols, $1)=no
       _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
-      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
+      _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
+      _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
 
       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
@@ -4343,6 +4689,11 @@ _LT_EOF
       fi
       ;;
 
+    haiku*)
+      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+      _LT_TAGVAR(link_all_deplibs, $1)=yes
+      ;;
+
     interix[[3-9]]*)
       _LT_TAGVAR(hardcode_direct, $1)=no
       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
@@ -4358,7 +4709,7 @@ _LT_EOF
       _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
       ;;
 
-    gnu* | linux* | tpf* | k*bsd*-gnu)
+    gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
       tmp_diet=no
       if test "$host_os" = linux-dietlibc; then
 	case $cc_basename in
@@ -4368,15 +4719,16 @@ _LT_EOF
       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
 	 && test "$tmp_diet" = no
       then
-	tmp_addflag=
+	tmp_addflag=' $pic_flag'
 	tmp_sharedflag='-shared'
 	case $cc_basename,$host_cpu in
         pgcc*)				# Portland Group C compiler
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag'
 	  ;;
-	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	pgf77* | pgf90* | pgf95* | pgfortran*)
+					# Portland Group f77 and f90 compilers
+	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag -Mnomain' ;;
 	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
 	  tmp_addflag=' -i_dynamic' ;;
@@ -4387,13 +4739,17 @@ _LT_EOF
 	lf95*)				# Lahey Fortran 8.1
 	  _LT_TAGVAR(whole_archive_flag_spec, $1)=
 	  tmp_sharedflag='--shared' ;;
-	xl[[cC]]*)			# IBM XL C 8.0 on PPC (deal with xlf below)
+	xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
 	  tmp_sharedflag='-qmkshrobj'
 	  tmp_addflag= ;;
+	nvcc*)	# Cuda Compiler Driver 2.2
+	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
+	  _LT_TAGVAR(compiler_needs_object, $1)=yes
+	  ;;
 	esac
 	case `$CC -V 2>&1 | sed 5q` in
 	*Sun\ C*)			# Sun C 5.9
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  _LT_TAGVAR(compiler_needs_object, $1)=yes
 	  tmp_sharedflag='-G' ;;
 	*Sun\ F*)			# Sun Fortran 8.3
@@ -4409,17 +4765,17 @@ _LT_EOF
         fi
 
 	case $cc_basename in
-	xlf*)
+	xlf* | bgf* | bgxlf* | mpixlf*)
 	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
 	  _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
 	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
 	  _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
-	  _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
+	  _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
 	  if test "x$supports_anon_versioning" = xyes; then
 	    _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
 	      cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
 	      echo "local: *; };" >> $output_objdir/$libname.ver~
-	      $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
+	      $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
 	  fi
 	  ;;
 	esac
@@ -4433,8 +4789,8 @@ _LT_EOF
 	_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
 	wlarc=
       else
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       fi
       ;;
 
@@ -4452,8 +4808,8 @@ _LT_EOF
 
 _LT_EOF
       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	_LT_TAGVAR(ld_shlibs, $1)=no
       fi
@@ -4499,8 +4855,8 @@ _LT_EOF
 
     *)
       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	_LT_TAGVAR(ld_shlibs, $1)=no
       fi
@@ -4540,8 +4896,10 @@ _LT_EOF
       else
 	# If we're using GNU nm, then we don't want the "-C" option.
 	# -C means demangle to AIX nm, but means don't demangle with GNU nm
+	# Also, AIX nm treats weak defined symbols like other global
+	# defined symbols, whereas GNU nm marks them as "W".
 	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
-	  _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
+	  _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	else
 	  _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	fi
@@ -4628,9 +4986,9 @@ _LT_EOF
 	_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
         # Determine the default libpath from the value encoded in an
         # empty executable.
-        _LT_SYS_MODULE_PATH_AIX
+        _LT_SYS_MODULE_PATH_AIX([$1])
         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
-        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
       else
 	if test "$host_cpu" = ia64; then
 	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
@@ -4639,14 +4997,19 @@ _LT_EOF
 	else
 	 # Determine the default libpath from the value encoded in an
 	 # empty executable.
-	 _LT_SYS_MODULE_PATH_AIX
+	 _LT_SYS_MODULE_PATH_AIX([$1])
 	 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 	  # Warning - without using the other run time loading flags,
 	  # -berok will link without error, but may produce a broken library.
 	  _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 	  _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	  # Exported symbols can be pulled into shared objects from archives
-	  _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
+	  if test "$with_gnu_ld" = yes; then
+	    # We only use this code for GNU lds that support --whole-archive.
+	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
+	  else
+	    # Exported symbols can be pulled into shared objects from archives
+	    _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
+	  fi
 	  _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
 	  # This is similar to how AIX traditionally builds its shared libraries.
 	  _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
@@ -4678,20 +5041,63 @@ _LT_EOF
       # Microsoft Visual C++.
       # hardcode_libdir_flag_spec is actually meaningless, as there is
       # no search path for DLLs.
-      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
-      _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-      # Tell ltmain to make .lib files, not .a files.
-      libext=lib
-      # Tell ltmain to make .dll files, not .so files.
-      shrext_cmds=".dll"
-      # FIXME: Setting linknames here is a bad hack.
-      _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
-      # The linker will automatically build a .lib file if we build a DLL.
-      _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
-      # FIXME: Should let the user specify the lib program.
-      _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
-      _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
-      _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
+      case $cc_basename in
+      cl*)
+	# Native MSVC
+	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
+	_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
+	_LT_TAGVAR(always_export_symbols, $1)=yes
+	_LT_TAGVAR(file_list_spec, $1)='@'
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	_LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
+	_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
+	    sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
+	  else
+	    sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
+	  fi~
+	  $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
+	  linknames='
+	# The linker will not automatically build a static lib if we build a DLL.
+	# _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
+	_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
+	_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
+	# Don't use ranlib
+	_LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
+	_LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
+	  lt_tool_outputfile="@TOOL_OUTPUT@"~
+	  case $lt_outputfile in
+	    *.exe|*.EXE) ;;
+	    *)
+	      lt_outputfile="$lt_outputfile.exe"
+	      lt_tool_outputfile="$lt_tool_outputfile.exe"
+	      ;;
+	  esac~
+	  if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
+	    $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
+	    $RM "$lt_outputfile.manifest";
+	  fi'
+	;;
+      *)
+	# Assume MSVC wrapper
+	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
+	_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	_LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
+	# The linker will automatically build a .lib file if we build a DLL.
+	_LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
+	# FIXME: Should let the user specify the lib program.
+	_LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
+	_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
+	;;
+      esac
       ;;
 
     darwin* | rhapsody*)
@@ -4729,7 +5135,7 @@ _LT_EOF
 
     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
     freebsd* | dragonfly*)
-      _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
+      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
       _LT_TAGVAR(hardcode_direct, $1)=yes
       _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
@@ -4737,7 +5143,7 @@ _LT_EOF
 
     hpux9*)
       if test "$GCC" = yes; then
-	_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       else
 	_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       fi
@@ -4752,8 +5158,8 @@ _LT_EOF
       ;;
 
     hpux10*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
       else
 	_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
       fi
@@ -4771,16 +5177,16 @@ _LT_EOF
       ;;
 
     hpux11*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
 	case $host_cpu in
 	hppa*64*)
 	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	ia64*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+	  _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       else
@@ -4792,7 +5198,14 @@ _LT_EOF
 	  _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+	m4_if($1, [], [
+	  # Older versions of the 11.00 compiler do not understand -b yet
+	  # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
+	  _LT_LINKER_OPTION([if $CC understands -b],
+	    _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
+	    [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
+	    [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
+	  [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
 	  ;;
 	esac
       fi
@@ -4820,19 +5233,34 @@ _LT_EOF
 
     irix5* | irix6* | nonstopux*)
       if test "$GCC" = yes; then
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	# Try to use the -exported_symbol ld option, if it does not
 	# work, assume that -exports_file does not work either and
 	# implicitly export all symbols.
-        save_LDFLAGS="$LDFLAGS"
-        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
-        AC_LINK_IFELSE(int foo(void) {},
-          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-        )
-        LDFLAGS="$save_LDFLAGS"
+	# This should be the same for all languages, so no per-tag cache variable.
+	AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
+	  [lt_cv_irix_exported_symbol],
+	  [save_LDFLAGS="$LDFLAGS"
+	   LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
+	   AC_LINK_IFELSE(
+	     [AC_LANG_SOURCE(
+	        [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
+			      [C++], [[int foo (void) { return 0; }]],
+			      [Fortran 77], [[
+      subroutine foo
+      end]],
+			      [Fortran], [[
+      subroutine foo
+      end]])])],
+	      [lt_cv_irix_exported_symbol=yes],
+	      [lt_cv_irix_exported_symbol=no])
+           LDFLAGS="$save_LDFLAGS"])
+	if test "$lt_cv_irix_exported_symbol" = yes; then
+          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
+	fi
       else
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
+	_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
       fi
       _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
@@ -4894,17 +5322,17 @@ _LT_EOF
       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
       _LT_TAGVAR(hardcode_minus_L, $1)=yes
       _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-      _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
+      _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
       _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
       ;;
 
     osf3*)
       if test "$GCC" = yes; then
 	_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
       else
 	_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
       fi
       _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
       _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
@@ -4914,13 +5342,13 @@ _LT_EOF
     osf4* | osf5*)	# as osf3* with the addition of -msym flag
       if test "$GCC" = yes; then
 	_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
       else
 	_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 	_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
-	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
+	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
 
 	# Both c and cxx compiler support -rpath directly
 	_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
@@ -4933,9 +5361,9 @@ _LT_EOF
       _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
       if test "$GCC" = yes; then
 	wlarc='${wl}'
-	_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	  $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
+	  $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
       else
 	case `$CC -V 2>&1` in
 	*"Compilers 5.0"*)
@@ -5111,36 +5539,38 @@ x|xyes)
       # Test whether the compiler implicitly links with -lc since on some
       # systems, -lgcc has to come before -lc. If gcc already passes -lc
       # to ld, don't add -lc before -lgcc.
-      AC_MSG_CHECKING([whether -lc should be explicitly linked in])
-      $RM conftest*
-      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
-      if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
-        soname=conftest
-        lib=conftest
-        libobjs=conftest.$ac_objext
-        deplibs=
-        wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
-	pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
-        compiler_flags=-v
-        linker_flags=-v
-        verstring=
-        output_objdir=.
-        libname=conftest
-        lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
-        _LT_TAGVAR(allow_undefined_flag, $1)=
-        if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
-        then
-	  _LT_TAGVAR(archive_cmds_need_lc, $1)=no
-        else
-	  _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
-        fi
-        _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
-      else
-        cat conftest.err 1>&5
-      fi
-      $RM conftest*
-      AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)])
+      AC_CACHE_CHECK([whether -lc should be explicitly linked in],
+	[lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
+	[$RM conftest*
+	echo "$lt_simple_compile_test_code" > conftest.$ac_ext
+
+	if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
+	  soname=conftest
+	  lib=conftest
+	  libobjs=conftest.$ac_objext
+	  deplibs=
+	  wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
+	  pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
+	  compiler_flags=-v
+	  linker_flags=-v
+	  verstring=
+	  output_objdir=.
+	  libname=conftest
+	  lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
+	  _LT_TAGVAR(allow_undefined_flag, $1)=
+	  if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
+	  then
+	    lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
+	  else
+	    lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
+	  fi
+	  _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
+	else
+	  cat conftest.err 1>&5
+	fi
+	$RM conftest*
+	])
+      _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
       ;;
     esac
   fi
@@ -5205,8 +5635,6 @@ _LT_TAGDECL([], [inherit_rpath], [0],
     to runtime path list])
 _LT_TAGDECL([], [link_all_deplibs], [0],
     [Whether libtool must link a program against all its dependency libraries])
-_LT_TAGDECL([], [fix_srcfile_path], [1],
-    [Fix the shell variable $srcfile for the compiler])
 _LT_TAGDECL([], [always_export_symbols], [0],
     [Set to "yes" if exported symbols are required])
 _LT_TAGDECL([], [export_symbols_cmds], [2],
@@ -5217,6 +5645,8 @@ _LT_TAGDECL([], [include_expsyms], [1],
     [Symbols that must always be exported])
 _LT_TAGDECL([], [prelink_cmds], [2],
     [Commands necessary for linking programs (against libraries) with templates])
+_LT_TAGDECL([], [postlink_cmds], [2],
+    [Commands necessary for finishing linking programs])
 _LT_TAGDECL([], [file_list_spec], [1],
     [Specify filename containing input files])
 dnl FIXME: Not yet implemented
@@ -5310,37 +5740,22 @@ CC="$lt_save_CC"
 ])# _LT_LANG_C_CONFIG
 
 
-# _LT_PROG_CXX
-# ------------
-# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++
-# compiler, we have our own version here.
-m4_defun([_LT_PROG_CXX],
-[
-pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes])
-AC_PROG_CXX
-if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
-    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
-    (test "X$CXX" != "Xg++"))) ; then
-  AC_PROG_CXXCPP
-else
-  _lt_caught_CXX_error=yes
-fi
-popdef([AC_MSG_ERROR])
-])# _LT_PROG_CXX
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([_LT_PROG_CXX], [])
-
-
 # _LT_LANG_CXX_CONFIG([TAG])
 # --------------------------
 # Ensure that the configuration variables for a C++ compiler are suitably
 # defined.  These variables are subsequently used by _LT_CONFIG to write
 # the compiler configuration to `libtool'.
 m4_defun([_LT_LANG_CXX_CONFIG],
-[AC_REQUIRE([_LT_PROG_CXX])dnl
-m4_require([_LT_FILEUTILS_DEFAULTS])dnl
+[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
 m4_require([_LT_DECL_EGREP])dnl
+m4_require([_LT_PATH_MANIFEST_TOOL])dnl
+if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
+    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
+    (test "X$CXX" != "Xg++"))) ; then
+  AC_PROG_CXXCPP
+else
+  _lt_caught_CXX_error=yes
+fi
 
 AC_LANG_PUSH(C++)
 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
@@ -5362,6 +5777,8 @@ _LT_TAGVAR(module_cmds, $1)=
 _LT_TAGVAR(module_expsym_cmds, $1)=
 _LT_TAGVAR(link_all_deplibs, $1)=unknown
 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
+_LT_TAGVAR(reload_flag, $1)=$reload_flag
+_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
 _LT_TAGVAR(no_undefined_flag, $1)=
 _LT_TAGVAR(whole_archive_flag_spec, $1)=
 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
@@ -5393,6 +5810,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 
   # Allow CC to be a program name with arguments.
   lt_save_CC=$CC
+  lt_save_CFLAGS=$CFLAGS
   lt_save_LD=$LD
   lt_save_GCC=$GCC
   GCC=$GXX
@@ -5410,6 +5828,7 @@ if test "$_lt_caught_CXX_error" != yes; then
   fi
   test -z "${LDCXX+set}" || LD=$LDCXX
   CC=${CXX-"c++"}
+  CFLAGS=$CXXFLAGS
   compiler=$CC
   _LT_TAGVAR(compiler, $1)=$CC
   _LT_CC_BASENAME([$compiler])
@@ -5431,8 +5850,8 @@ if test "$_lt_caught_CXX_error" != yes; then
       # Check if GNU C++ uses GNU ld as the underlying linker, since the
       # archiving commands below assume that GNU ld is being used.
       if test "$with_gnu_ld" = yes; then
-        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
-        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+        _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
+        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
 
         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
@@ -5464,7 +5883,7 @@ if test "$_lt_caught_CXX_error" != yes; then
       # Commands to make compiler produce verbose output that lists
       # what "hidden" libraries, object files and flags are used when
       # linking a shared library.
-      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
+      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
 
     else
       GXX=no
@@ -5573,10 +5992,10 @@ if test "$_lt_caught_CXX_error" != yes; then
           _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
           # Determine the default libpath from the value encoded in an empty
           # executable.
-          _LT_SYS_MODULE_PATH_AIX
+          _LT_SYS_MODULE_PATH_AIX([$1])
           _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 
-          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
         else
           if test "$host_cpu" = ia64; then
 	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
@@ -5585,14 +6004,19 @@ if test "$_lt_caught_CXX_error" != yes; then
           else
 	    # Determine the default libpath from the value encoded in an
 	    # empty executable.
-	    _LT_SYS_MODULE_PATH_AIX
+	    _LT_SYS_MODULE_PATH_AIX([$1])
 	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 	    # Warning - without using the other run time loading flags,
 	    # -berok will link without error, but may produce a broken library.
 	    _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 	    _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	    # Exported symbols can be pulled into shared objects from archives
-	    _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
+	    if test "$with_gnu_ld" = yes; then
+	      # We only use this code for GNU lds that support --whole-archive.
+	      _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
+	    else
+	      # Exported symbols can be pulled into shared objects from archives
+	      _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
+	    fi
 	    _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
 	    # This is similar to how AIX traditionally builds its shared
 	    # libraries.
@@ -5622,28 +6046,75 @@ if test "$_lt_caught_CXX_error" != yes; then
         ;;
 
       cygwin* | mingw* | pw32* | cegcc*)
-        # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
-        # as there is no search path for DLLs.
-        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-        _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
-        _LT_TAGVAR(always_export_symbols, $1)=no
-        _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
-
-        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
-          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-          # If the export-symbols file already is a .def file (1st line
-          # is EXPORTS), use it as is; otherwise, prepend...
-          _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
-	    cp $export_symbols $output_objdir/$soname.def;
-          else
-	    echo EXPORTS > $output_objdir/$soname.def;
-	    cat $export_symbols >> $output_objdir/$soname.def;
-          fi~
-          $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-        else
-          _LT_TAGVAR(ld_shlibs, $1)=no
-        fi
-        ;;
+	case $GXX,$cc_basename in
+	,cl* | no,cl*)
+	  # Native MSVC
+	  # hardcode_libdir_flag_spec is actually meaningless, as there is
+	  # no search path for DLLs.
+	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
+	  _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
+	  _LT_TAGVAR(always_export_symbols, $1)=yes
+	  _LT_TAGVAR(file_list_spec, $1)='@'
+	  # Tell ltmain to make .lib files, not .a files.
+	  libext=lib
+	  # Tell ltmain to make .dll files, not .so files.
+	  shrext_cmds=".dll"
+	  # FIXME: Setting linknames here is a bad hack.
+	  _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
+	  _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
+	      $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
+	    else
+	      $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
+	    fi~
+	    $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
+	    linknames='
+	  # The linker will not automatically build a static lib if we build a DLL.
+	  # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
+	  _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
+	  # Don't use ranlib
+	  _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
+	  _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
+	    lt_tool_outputfile="@TOOL_OUTPUT@"~
+	    case $lt_outputfile in
+	      *.exe|*.EXE) ;;
+	      *)
+		lt_outputfile="$lt_outputfile.exe"
+		lt_tool_outputfile="$lt_tool_outputfile.exe"
+		;;
+	    esac~
+	    func_to_tool_file "$lt_outputfile"~
+	    if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
+	      $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
+	      $RM "$lt_outputfile.manifest";
+	    fi'
+	  ;;
+	*)
+	  # g++
+	  # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
+	  # as there is no search path for DLLs.
+	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
+	  _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
+	  _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
+	  _LT_TAGVAR(always_export_symbols, $1)=no
+	  _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
+
+	  if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
+	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
+	    # If the export-symbols file already is a .def file (1st line
+	    # is EXPORTS), use it as is; otherwise, prepend...
+	    _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
+	      cp $export_symbols $output_objdir/$soname.def;
+	    else
+	      echo EXPORTS > $output_objdir/$soname.def;
+	      cat $export_symbols >> $output_objdir/$soname.def;
+	    fi~
+	    $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
+	  else
+	    _LT_TAGVAR(ld_shlibs, $1)=no
+	  fi
+	  ;;
+	esac
+	;;
       darwin* | rhapsody*)
         _LT_DARWIN_LINKER_FEATURES($1)
 	;;
@@ -5685,6 +6156,11 @@ if test "$_lt_caught_CXX_error" != yes; then
       gnu*)
         ;;
 
+      haiku*)
+        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+        _LT_TAGVAR(link_all_deplibs, $1)=yes
+        ;;
+
       hpux9*)
         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
         _LT_TAGVAR(hardcode_libdir_separator, $1)=:
@@ -5709,11 +6185,11 @@ if test "$_lt_caught_CXX_error" != yes; then
             # explicitly linking system object files so we need to strip them
             # from the output so that they don't get included in the library
             # dependencies.
-            output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
+            output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
             ;;
           *)
             if test "$GXX" = yes; then
-              _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
+              _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
             else
               # FIXME: insert proper C++ library support
               _LT_TAGVAR(ld_shlibs, $1)=no
@@ -5774,7 +6250,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    # explicitly linking system object files so we need to strip them
 	    # from the output so that they don't get included in the library
 	    # dependencies.
-	    output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
+	    output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
 	    ;;
           *)
 	    if test "$GXX" = yes; then
@@ -5784,10 +6260,10 @@ if test "$_lt_caught_CXX_error" != yes; then
 	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	            ;;
 	          ia64*)
-	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	            ;;
 	          *)
-	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	            ;;
 	        esac
 	      fi
@@ -5817,7 +6293,7 @@ if test "$_lt_caught_CXX_error" != yes; then
         case $cc_basename in
           CC*)
 	    # SGI C++
-	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 
 	    # Archives containing C++ object files must be created using
 	    # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
@@ -5828,9 +6304,9 @@ if test "$_lt_caught_CXX_error" != yes; then
           *)
 	    if test "$GXX" = yes; then
 	      if test "$with_gnu_ld" = no; then
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	      else
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib'
+	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
 	      fi
 	    fi
 	    _LT_TAGVAR(link_all_deplibs, $1)=yes
@@ -5841,7 +6317,7 @@ if test "$_lt_caught_CXX_error" != yes; then
         _LT_TAGVAR(inherit_rpath, $1)=yes
         ;;
 
-      linux* | k*bsd*-gnu)
+      linux* | k*bsd*-gnu | kopensolaris*-gnu)
         case $cc_basename in
           KCC*)
 	    # Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -5859,7 +6335,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    # explicitly linking system object files so we need to strip them
 	    # from the output so that they don't get included in the library
 	    # dependencies.
-	    output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
+	    output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
 
 	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
 	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
@@ -5896,26 +6372,26 @@ if test "$_lt_caught_CXX_error" != yes; then
           pgCC* | pgcpp*)
             # Portland Group C++ compiler
 	    case `$CC -V` in
-	    *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*)
+	    *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
 	      _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
 		rm -rf $tpldir~
 		$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
-		compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"'
+		compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
 	      _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
 		rm -rf $tpldir~
 		$CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
-		$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~
+		$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
 		$RANLIB $oldlib'
 	      _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
 		rm -rf $tpldir~
 		$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
-		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
+		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
 	      _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
 		rm -rf $tpldir~
 		$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
-		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
+		$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
 	      ;;
-	    *) # Version 6 will use weak symbols
+	    *) # Version 6 and above use weak symbols
 	      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
 	      _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
 	      ;;
@@ -5923,7 +6399,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 
 	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
 	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
-	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	    _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
             ;;
 	  cxx*)
 	    # Compaq C++
@@ -5942,9 +6418,9 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    # explicitly linking system object files so we need to strip them
 	    # from the output so that they don't get included in the library
 	    # dependencies.
-	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
+	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
 	    ;;
-	  xl*)
+	  xl* | mpixl* | bgxl*)
 	    # IBM XL 8.0 on PPC, with GNU ld
 	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
@@ -5964,13 +6440,13 @@ if test "$_lt_caught_CXX_error" != yes; then
 	      _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	      _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
 	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-	      _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	      _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	      _LT_TAGVAR(compiler_needs_object, $1)=yes
 
 	      # Not sure whether something based on
 	      # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
 	      # would be better.
-	      output_verbose_link_cmd='echo'
+	      output_verbose_link_cmd='func_echo_all'
 
 	      # Archives containing C++ object files must be created using
 	      # "CC -xar", where "CC" is the Sun C++ compiler.  This is
@@ -6039,7 +6515,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 	    _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
 	  fi
-	  output_verbose_link_cmd=echo
+	  output_verbose_link_cmd=func_echo_all
 	else
 	  _LT_TAGVAR(ld_shlibs, $1)=no
 	fi
@@ -6074,15 +6550,15 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    case $host in
 	      osf3*)
 	        _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 	        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
 		;;
 	      *)
 	        _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 	        _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
 	          echo "-hidden">> $lib.exp~
-	          $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp  `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~
+	          $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp  `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
 	          $RM $lib.exp'
 	        _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
 		;;
@@ -6098,17 +6574,17 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    # explicitly linking system object files so we need to strip them
 	    # from the output so that they don't get included in the library
 	    # dependencies.
-	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed'
+	    output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
 	    ;;
 	  *)
 	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
 	      _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
 	      case $host in
 	        osf3*)
-	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 		  ;;
 	        *)
-	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 		  ;;
 	      esac
 
@@ -6118,7 +6594,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 	      # Commands to make compiler produce verbose output that lists
 	      # what "hidden" libraries, object files and flags are used when
 	      # linking a shared library.
-	      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
+	      output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
 
 	    else
 	      # FIXME: insert proper C++ library support
@@ -6154,7 +6630,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 
       solaris*)
         case $cc_basename in
-          CC*)
+          CC* | sunCC*)
 	    # Sun C++ 4.2, 5.x and Centerline C++
             _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
 	    _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
@@ -6175,7 +6651,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    esac
 	    _LT_TAGVAR(link_all_deplibs, $1)=yes
 
-	    output_verbose_link_cmd='echo'
+	    output_verbose_link_cmd='func_echo_all'
 
 	    # Archives containing C++ object files must be created using
 	    # "CC -xar", where "CC" is the Sun C++ compiler.  This is
@@ -6195,14 +6671,14 @@ if test "$_lt_caught_CXX_error" != yes; then
 	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
 	      _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
 	      if $CC --version | $GREP -v '^2\.7' > /dev/null; then
-	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
+	        _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
 	        _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-		  $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
+		  $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
 
 	        # Commands to make compiler produce verbose output that lists
 	        # what "hidden" libraries, object files and flags are used when
 	        # linking a shared library.
-	        output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
+	        output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
 	      else
 	        # g++ 2.7 appears to require `-G' NOT `-shared' on this
 	        # platform.
@@ -6213,7 +6689,7 @@ if test "$_lt_caught_CXX_error" != yes; then
 	        # Commands to make compiler produce verbose output that lists
 	        # what "hidden" libraries, object files and flags are used when
 	        # linking a shared library.
-	        output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"'
+	        output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
 	      fi
 
 	      _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
@@ -6267,6 +6743,10 @@ if test "$_lt_caught_CXX_error" != yes; then
           CC*)
 	    _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
 	    _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	    _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
+	      '"$_LT_TAGVAR(old_archive_cmds, $1)"
+	    _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
+	      '"$_LT_TAGVAR(reload_cmds, $1)"
 	    ;;
 	  *)
 	    _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
@@ -6322,6 +6802,7 @@ if test "$_lt_caught_CXX_error" != yes; then
   fi # test -n "$compiler"
 
   CC=$lt_save_CC
+  CFLAGS=$lt_save_CFLAGS
   LDCXX=$LD
   LD=$lt_save_LD
   GCC=$lt_save_GCC
@@ -6336,6 +6817,29 @@ AC_LANG_POP
 ])# _LT_LANG_CXX_CONFIG
 
 
+# _LT_FUNC_STRIPNAME_CNF
+# ----------------------
+# func_stripname_cnf prefix suffix name
+# strip PREFIX and SUFFIX off of NAME.
+# PREFIX and SUFFIX must not contain globbing or regex special
+# characters, hashes, percent signs, but SUFFIX may contain a leading
+# dot (in which case that matches only a dot).
+#
+# This function is identical to the (non-XSI) version of func_stripname,
+# except this one can be used by m4 code that may be executed by configure,
+# rather than the libtool script.
+m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
+AC_REQUIRE([_LT_DECL_SED])
+AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
+func_stripname_cnf ()
+{
+  case ${2} in
+  .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
+  *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
+  esac
+} # func_stripname_cnf
+])# _LT_FUNC_STRIPNAME_CNF
+
 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
 # ---------------------------------
 # Figure out "hidden" library dependencies from verbose
@@ -6344,6 +6848,7 @@ AC_LANG_POP
 # objects, libraries and library flags.
 m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
+AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
 # Dependencies to place before and after the object being linked:
 _LT_TAGVAR(predep_objects, $1)=
 _LT_TAGVAR(postdep_objects, $1)=
@@ -6394,6 +6899,13 @@ public class foo {
 };
 _LT_EOF
 ])
+
+_lt_libdeps_save_CFLAGS=$CFLAGS
+case "$CC $CFLAGS " in #(
+*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
+*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
+esac
+
 dnl Parse the compiler output and extract the necessary
 dnl objects, libraries and library flags.
 if AC_TRY_EVAL(ac_compile); then
@@ -6405,7 +6917,7 @@ if AC_TRY_EVAL(ac_compile); then
   pre_test_object_deps_done=no
 
   for p in `eval "$output_verbose_link_cmd"`; do
-    case $p in
+    case ${prev}${p} in
 
     -L* | -R* | -l*)
        # Some compilers place space between "-{L,R}" and the path.
@@ -6414,13 +6926,22 @@ if AC_TRY_EVAL(ac_compile); then
           test $p = "-R"; then
 	 prev=$p
 	 continue
-       else
-	 prev=
        fi
 
+       # Expand the sysroot to ease extracting the directories later.
+       if test -z "$prev"; then
+         case $p in
+         -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
+         -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
+         -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
+         esac
+       fi
+       case $p in
+       =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
+       esac
        if test "$pre_test_object_deps_done" = no; then
-	 case $p in
-	 -L* | -R*)
+	 case ${prev} in
+	 -L | -R)
 	   # Internal compiler library paths should come after those
 	   # provided the user.  The postdeps already come after the
 	   # user supplied libs so there is no need to process them.
@@ -6440,8 +6961,10 @@ if AC_TRY_EVAL(ac_compile); then
 	   _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
 	 fi
        fi
+       prev=
        ;;
 
+    *.lto.$objext) ;; # Ignore GCC LTO objects
     *.$objext)
        # This assumes that the test object file only shows up
        # once in the compiler output.
@@ -6477,6 +7000,7 @@ else
 fi
 
 $RM -f confest.$objext
+CFLAGS=$_lt_libdeps_save_CFLAGS
 
 # PORTME: override above test on systems where it is broken
 m4_if([$1], [CXX],
@@ -6513,7 +7037,7 @@ linux*)
 
 solaris*)
   case $cc_basename in
-  CC*)
+  CC* | sunCC*)
     # The more standards-conforming stlport4 library is
     # incompatible with the Cstd library. Avoid specifying
     # it if it's in CXXFLAGS. Ignore libCrun as
@@ -6557,32 +7081,16 @@ _LT_TAGDECL([], [compiler_lib_search_path], [1],
 ])# _LT_SYS_HIDDEN_LIBDEPS
 
 
-# _LT_PROG_F77
-# ------------
-# Since AC_PROG_F77 is broken, in that it returns the empty string
-# if there is no fortran compiler, we have our own version here.
-m4_defun([_LT_PROG_F77],
-[
-pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes])
-AC_PROG_F77
-if test -z "$F77" || test "X$F77" = "Xno"; then
-  _lt_disable_F77=yes
-fi
-popdef([AC_MSG_ERROR])
-])# _LT_PROG_F77
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([_LT_PROG_F77], [])
-
-
 # _LT_LANG_F77_CONFIG([TAG])
 # --------------------------
 # Ensure that the configuration variables for a Fortran 77 compiler are
 # suitably defined.  These variables are subsequently used by _LT_CONFIG
 # to write the compiler configuration to `libtool'.
 m4_defun([_LT_LANG_F77_CONFIG],
-[AC_REQUIRE([_LT_PROG_F77])dnl
-AC_LANG_PUSH(Fortran 77)
+[AC_LANG_PUSH(Fortran 77)
+if test -z "$F77" || test "X$F77" = "Xno"; then
+  _lt_disable_F77=yes
+fi
 
 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
 _LT_TAGVAR(allow_undefined_flag, $1)=
@@ -6601,6 +7109,8 @@ _LT_TAGVAR(module_cmds, $1)=
 _LT_TAGVAR(module_expsym_cmds, $1)=
 _LT_TAGVAR(link_all_deplibs, $1)=unknown
 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
+_LT_TAGVAR(reload_flag, $1)=$reload_flag
+_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
 _LT_TAGVAR(no_undefined_flag, $1)=
 _LT_TAGVAR(whole_archive_flag_spec, $1)=
 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
@@ -6640,7 +7150,9 @@ if test "$_lt_disable_F77" != yes; then
   # Allow CC to be a program name with arguments.
   lt_save_CC="$CC"
   lt_save_GCC=$GCC
+  lt_save_CFLAGS=$CFLAGS
   CC=${F77-"f77"}
+  CFLAGS=$FFLAGS
   compiler=$CC
   _LT_TAGVAR(compiler, $1)=$CC
   _LT_CC_BASENAME([$compiler])
@@ -6694,38 +7206,24 @@ if test "$_lt_disable_F77" != yes; then
 
   GCC=$lt_save_GCC
   CC="$lt_save_CC"
+  CFLAGS="$lt_save_CFLAGS"
 fi # test "$_lt_disable_F77" != yes
 
 AC_LANG_POP
 ])# _LT_LANG_F77_CONFIG
 
 
-# _LT_PROG_FC
-# -----------
-# Since AC_PROG_FC is broken, in that it returns the empty string
-# if there is no fortran compiler, we have our own version here.
-m4_defun([_LT_PROG_FC],
-[
-pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes])
-AC_PROG_FC
-if test -z "$FC" || test "X$FC" = "Xno"; then
-  _lt_disable_FC=yes
-fi
-popdef([AC_MSG_ERROR])
-])# _LT_PROG_FC
-
-dnl aclocal-1.4 backwards compatibility:
-dnl AC_DEFUN([_LT_PROG_FC], [])
-
-
 # _LT_LANG_FC_CONFIG([TAG])
 # -------------------------
 # Ensure that the configuration variables for a Fortran compiler are
 # suitably defined.  These variables are subsequently used by _LT_CONFIG
 # to write the compiler configuration to `libtool'.
 m4_defun([_LT_LANG_FC_CONFIG],
-[AC_REQUIRE([_LT_PROG_FC])dnl
-AC_LANG_PUSH(Fortran)
+[AC_LANG_PUSH(Fortran)
+
+if test -z "$FC" || test "X$FC" = "Xno"; then
+  _lt_disable_FC=yes
+fi
 
 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
 _LT_TAGVAR(allow_undefined_flag, $1)=
@@ -6744,6 +7242,8 @@ _LT_TAGVAR(module_cmds, $1)=
 _LT_TAGVAR(module_expsym_cmds, $1)=
 _LT_TAGVAR(link_all_deplibs, $1)=unknown
 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
+_LT_TAGVAR(reload_flag, $1)=$reload_flag
+_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
 _LT_TAGVAR(no_undefined_flag, $1)=
 _LT_TAGVAR(whole_archive_flag_spec, $1)=
 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
@@ -6783,7 +7283,9 @@ if test "$_lt_disable_FC" != yes; then
   # Allow CC to be a program name with arguments.
   lt_save_CC="$CC"
   lt_save_GCC=$GCC
+  lt_save_CFLAGS=$CFLAGS
   CC=${FC-"f95"}
+  CFLAGS=$FCFLAGS
   compiler=$CC
   GCC=$ac_cv_fc_compiler_gnu
 
@@ -6839,7 +7341,8 @@ if test "$_lt_disable_FC" != yes; then
   fi # test -n "$compiler"
 
   GCC=$lt_save_GCC
-  CC="$lt_save_CC"
+  CC=$lt_save_CC
+  CFLAGS=$lt_save_CFLAGS
 fi # test "$_lt_disable_FC" != yes
 
 AC_LANG_POP
@@ -6876,10 +7379,12 @@ _LT_COMPILER_BOILERPLATE
 _LT_LINKER_BOILERPLATE
 
 # Allow CC to be a program name with arguments.
-lt_save_CC="$CC"
+lt_save_CC=$CC
+lt_save_CFLAGS=$CFLAGS
 lt_save_GCC=$GCC
 GCC=yes
 CC=${GCJ-"gcj"}
+CFLAGS=$GCJFLAGS
 compiler=$CC
 _LT_TAGVAR(compiler, $1)=$CC
 _LT_TAGVAR(LD, $1)="$LD"
@@ -6889,6 +7394,8 @@ _LT_CC_BASENAME([$compiler])
 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
 
 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
+_LT_TAGVAR(reload_flag, $1)=$reload_flag
+_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
 
 ## CAVEAT EMPTOR:
 ## There is no encapsulation within the following macros, do not change
@@ -6908,7 +7415,8 @@ fi
 AC_LANG_RESTORE
 
 GCC=$lt_save_GCC
-CC="$lt_save_CC"
+CC=$lt_save_CC
+CFLAGS=$lt_save_CFLAGS
 ])# _LT_LANG_GCJ_CONFIG
 
 
@@ -6943,9 +7451,11 @@ _LT_LINKER_BOILERPLATE
 
 # Allow CC to be a program name with arguments.
 lt_save_CC="$CC"
+lt_save_CFLAGS=$CFLAGS
 lt_save_GCC=$GCC
 GCC=
 CC=${RC-"windres"}
+CFLAGS=
 compiler=$CC
 _LT_TAGVAR(compiler, $1)=$CC
 _LT_CC_BASENAME([$compiler])
@@ -6958,7 +7468,8 @@ fi
 
 GCC=$lt_save_GCC
 AC_LANG_RESTORE
-CC="$lt_save_CC"
+CC=$lt_save_CC
+CFLAGS=$lt_save_CFLAGS
 ])# _LT_LANG_RC_CONFIG
 
 
@@ -7017,6 +7528,15 @@ _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
 AC_SUBST([OBJDUMP])
 ])
 
+# _LT_DECL_DLLTOOL
+# ----------------
+# Ensure DLLTOOL variable is set.
+m4_defun([_LT_DECL_DLLTOOL],
+[AC_CHECK_TOOL(DLLTOOL, dlltool, false)
+test -z "$DLLTOOL" && DLLTOOL=dlltool
+_LT_DECL([], [DLLTOOL], [1], [DLL creation program])
+AC_SUBST([DLLTOOL])
+])
 
 # _LT_DECL_SED
 # ------------
@@ -7110,8 +7630,8 @@ m4_defun([_LT_CHECK_SHELL_FEATURES],
 # Try some XSI features
 xsi_shell=no
 ( _lt_dummy="a/b/c"
-  test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
-      = c,a/b,, \
+  test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
+      = c,a/b,b/c, \
     && eval 'test $(( 1 + 1 )) -eq 2 \
     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
   && xsi_shell=yes
@@ -7150,208 +7670,162 @@ _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
 ])# _LT_CHECK_SHELL_FEATURES
 
 
-# _LT_PROG_XSI_SHELLFNS
-# ---------------------
-# Bourne and XSI compatible variants of some useful shell functions.
-m4_defun([_LT_PROG_XSI_SHELLFNS],
-[case $xsi_shell in
-  yes)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
-  case ${1} in
-    */*) func_dirname_result="${1%/*}${2}" ;;
-    *  ) func_dirname_result="${3}" ;;
-  esac
-}
-
-# func_basename file
-func_basename ()
-{
-  func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-#   dirname:  Compute the dirname of FILE.  If nonempty,
-#             add APPEND to the result, otherwise set result
-#             to NONDIR_REPLACEMENT.
-#             value returned in "$func_dirname_result"
-#   basename: Compute filename of FILE.
-#             value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
-  case ${1} in
-    */*) func_dirname_result="${1%/*}${2}" ;;
-    *  ) func_dirname_result="${3}" ;;
-  esac
-  func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
-  # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
-  # positional parameters, so assign one to ordinary parameter first.
-  func_stripname_result=${3}
-  func_stripname_result=${func_stripname_result#"${1}"}
-  func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
-  func_opt_split_opt=${1%%=*}
-  func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
-  case ${1} in
-    *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
-    *)    func_lo2o_result=${1} ;;
-  esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
-  func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
-  func_arith_result=$(( $[*] ))
-}
+# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
+# ------------------------------------------------------
+# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
+# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
+m4_defun([_LT_PROG_FUNCTION_REPLACE],
+[dnl {
+sed -e '/^$1 ()$/,/^} # $1 /c\
+$1 ()\
+{\
+m4_bpatsubsts([$2], [$], [\\], [^\([	 ]\)], [\\\1])
+} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+])
 
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
-  func_len_result=${#1}
-}
 
-_LT_EOF
-    ;;
-  *) # Bourne compatible functions.
-    cat << \_LT_EOF >> "$cfgfile"
+# _LT_PROG_REPLACE_SHELLFNS
+# -------------------------
+# Replace existing portable implementations of several shell functions with
+# equivalent extended shell implementations where those features are available..
+m4_defun([_LT_PROG_REPLACE_SHELLFNS],
+[if test x"$xsi_shell" = xyes; then
+  _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
+    case ${1} in
+      */*) func_dirname_result="${1%/*}${2}" ;;
+      *  ) func_dirname_result="${3}" ;;
+    esac])
+
+  _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
+    func_basename_result="${1##*/}"])
+
+  _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
+    case ${1} in
+      */*) func_dirname_result="${1%/*}${2}" ;;
+      *  ) func_dirname_result="${3}" ;;
+    esac
+    func_basename_result="${1##*/}"])
 
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
-  # Extract subdirectory from the argument.
-  func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
-  if test "X$func_dirname_result" = "X${1}"; then
-    func_dirname_result="${3}"
-  else
-    func_dirname_result="$func_dirname_result${2}"
-  fi
-}
+  _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
+    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
+    # positional parameters, so assign one to ordinary parameter first.
+    func_stripname_result=${3}
+    func_stripname_result=${func_stripname_result#"${1}"}
+    func_stripname_result=${func_stripname_result%"${2}"}])
 
-# func_basename file
-func_basename ()
-{
-  func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
-}
+  _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
+    func_split_long_opt_name=${1%%=*}
+    func_split_long_opt_arg=${1#*=}])
 
-dnl func_dirname_and_basename
-dnl A portable version of this function is already defined in general.m4sh
-dnl so there is no need for it here.
+  _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
+    func_split_short_opt_arg=${1#??}
+    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
 
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
-  case ${2} in
-    .*) func_stripname_result=`$ECHO "X${3}" \
-           | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
-    *)  func_stripname_result=`$ECHO "X${3}" \
-           | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
-  esac
-}
+  _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
+    case ${1} in
+      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
+      *)    func_lo2o_result=${1} ;;
+    esac])
 
-# sed scripts:
-my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[[^=]]*=//'
+  _LT_PROG_FUNCTION_REPLACE([func_xform], [    func_xform_result=${1%.*}.lo])
 
-# func_opt_split
-func_opt_split ()
-{
-  func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
-  func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
-  func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
-}
+  _LT_PROG_FUNCTION_REPLACE([func_arith], [    func_arith_result=$(( $[*] ))])
 
-# func_xform libobj-or-source
-func_xform ()
-{
-  func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'`
-}
+  _LT_PROG_FUNCTION_REPLACE([func_len], [    func_len_result=${#1}])
+fi
 
-# func_arith arithmetic-term...
-func_arith ()
-{
-  func_arith_result=`expr "$[@]"`
-}
+if test x"$lt_shell_append" = xyes; then
+  _LT_PROG_FUNCTION_REPLACE([func_append], [    eval "${1}+=\\${2}"])
 
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
-  func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
+  _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
+    func_quote_for_eval "${2}"
+dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
+    eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
 
-_LT_EOF
-esac
+  # Save a `func_append' function call where possible by direct use of '+='
+  sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
+    && mv -f "$cfgfile.tmp" "$cfgfile" \
+      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+  test 0 -eq $? || _lt_function_replace_fail=:
+else
+  # Save a `func_append' function call even when '+=' is not available
+  sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
+    && mv -f "$cfgfile.tmp" "$cfgfile" \
+      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+  test 0 -eq $? || _lt_function_replace_fail=:
+fi
 
-case $lt_shell_append in
-  yes)
-    cat << \_LT_EOF >> "$cfgfile"
+if test x"$_lt_function_replace_fail" = x":"; then
+  AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
+fi
+])
 
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
-  eval "$[1]+=\$[2]"
-}
-_LT_EOF
+# _LT_PATH_CONVERSION_FUNCTIONS
+# -----------------------------
+# Determine which file name conversion functions should be used by
+# func_to_host_file (and, implicitly, by func_to_host_path).  These are needed
+# for certain cross-compile configurations and native mingw.
+m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
+[AC_REQUIRE([AC_CANONICAL_HOST])dnl
+AC_REQUIRE([AC_CANONICAL_BUILD])dnl
+AC_MSG_CHECKING([how to convert $build file names to $host format])
+AC_CACHE_VAL(lt_cv_to_host_file_cmd,
+[case $host in
+  *-*-mingw* )
+    case $build in
+      *-*-mingw* ) # actually msys
+        lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
+        ;;
+      *-*-cygwin* )
+        lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
+        ;;
+      * ) # otherwise, assume *nix
+        lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
+        ;;
+    esac
     ;;
-  *)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
-  eval "$[1]=\$$[1]\$[2]"
-}
-
-_LT_EOF
+  *-*-cygwin* )
+    case $build in
+      *-*-mingw* ) # actually msys
+        lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
+        ;;
+      *-*-cygwin* )
+        lt_cv_to_host_file_cmd=func_convert_file_noop
+        ;;
+      * ) # otherwise, assume *nix
+        lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
+        ;;
+    esac
     ;;
-  esac
+  * ) # unhandled hosts (and "normal" native builds)
+    lt_cv_to_host_file_cmd=func_convert_file_noop
+    ;;
+esac
+])
+to_host_file_cmd=$lt_cv_to_host_file_cmd
+AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
+_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
+         [0], [convert $build file names to $host format])dnl
+
+AC_MSG_CHECKING([how to convert $build file names to toolchain format])
+AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
+[#assume ordinary cross tools, or native build.
+lt_cv_to_tool_file_cmd=func_convert_file_noop
+case $host in
+  *-*-mingw* )
+    case $build in
+      *-*-mingw* ) # actually msys
+        lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
+        ;;
+    esac
+    ;;
+esac
 ])
+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
+AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
+_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
+         [0], [convert $build files to toolchain format])dnl
+])# _LT_PATH_CONVERSION_FUNCTIONS
diff --git a/config/ltmain.sh b/config/ltmain.sh
index a72f2fd..3061e3c 100755
--- a/config/ltmain.sh
+++ b/config/ltmain.sh
@@ -1,9 +1,9 @@
-# Generated from ltmain.m4sh.
 
-# ltmain.sh (GNU libtool) 2.2.6b
+# libtool (GNU libtool) 2.4
 # Written by Gordon Matzigkeit <gord at gnu.ai.mit.edu>, 1996
 
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007 2008 Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
+# 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
 # This is free software; see the source for copying conditions.  There is NO
 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
@@ -32,50 +32,56 @@
 #
 # Provide generalized library-building support services.
 #
-#     --config             show all configuration variables
-#     --debug              enable verbose shell tracing
-# -n, --dry-run            display commands without modifying any files
-#     --features           display basic configuration information and exit
-#     --mode=MODE          use operation mode MODE
-#     --preserve-dup-deps  don't remove duplicate dependency libraries
-#     --quiet, --silent    don't print informational messages
-#     --tag=TAG            use configuration variables from tag TAG
-# -v, --verbose            print informational messages (default)
-#     --version            print version information
-# -h, --help               print short or long help message
+#       --config             show all configuration variables
+#       --debug              enable verbose shell tracing
+#   -n, --dry-run            display commands without modifying any files
+#       --features           display basic configuration information and exit
+#       --mode=MODE          use operation mode MODE
+#       --preserve-dup-deps  don't remove duplicate dependency libraries
+#       --quiet, --silent    don't print informational messages
+#       --no-quiet, --no-silent
+#                            print informational messages (default)
+#       --tag=TAG            use configuration variables from tag TAG
+#   -v, --verbose            print more informational messages than default
+#       --no-verbose         don't print the extra informational messages
+#       --version            print version information
+#   -h, --help, --help-all   print short, long, or detailed help message
 #
 # MODE must be one of the following:
 #
-#       clean              remove files from the build directory
-#       compile            compile a source file into a libtool object
-#       execute            automatically set library path, then run a program
-#       finish             complete the installation of libtool libraries
-#       install            install libraries or executables
-#       link               create a library or an executable
-#       uninstall          remove libraries from an installed directory
+#         clean              remove files from the build directory
+#         compile            compile a source file into a libtool object
+#         execute            automatically set library path, then run a program
+#         finish             complete the installation of libtool libraries
+#         install            install libraries or executables
+#         link               create a library or an executable
+#         uninstall          remove libraries from an installed directory
 #
-# MODE-ARGS vary depending on the MODE.
+# MODE-ARGS vary depending on the MODE.  When passed as first option,
+# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that.
 # Try `$progname --help --mode=MODE' for a more detailed description of MODE.
 #
 # When reporting a bug, please describe a test case to reproduce it and
 # include the following information:
 #
-#       host-triplet:	$host
-#       shell:		$SHELL
-#       compiler:		$LTCC
-#       compiler flags:		$LTCFLAGS
-#       linker:		$LD (gnu? $with_gnu_ld)
-#       $progname:		(GNU libtool) 2.2.6b
-#       automake:		$automake_version
-#       autoconf:		$autoconf_version
+#         host-triplet:	$host
+#         shell:		$SHELL
+#         compiler:		$LTCC
+#         compiler flags:		$LTCFLAGS
+#         linker:		$LD (gnu? $with_gnu_ld)
+#         $progname:	(GNU libtool) 2.4
+#         automake:	$automake_version
+#         autoconf:	$autoconf_version
 #
 # Report bugs to <bug-libtool at gnu.org>.
+# GNU libtool home page: <http://www.gnu.org/software/libtool/>.
+# General help using GNU software: <http://www.gnu.org/gethelp/>.
 
-PROGRAM=ltmain.sh
+PROGRAM=libtool
 PACKAGE=libtool
-VERSION=2.2.6b
+VERSION=2.4
 TIMESTAMP=""
-package_revision=1.3017
+package_revision=1.3293
 
 # Be Bourne compatible
 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
@@ -91,10 +97,15 @@ fi
 BIN_SH=xpg4; export BIN_SH # for Tru64
 DUALCASE=1; export DUALCASE # for MKS sh
 
+# A function that is used when there is no print builtin or printf.
+func_fallback_echo ()
+{
+  eval 'cat <<_LTECHO_EOF
+$1
+_LTECHO_EOF'
+}
+
 # NLS nuisances: We save the old values to restore during execute mode.
-# Only set LANG and LC_ALL to C if already set.
-# These must not be set unconditionally because not all systems understand
-# e.g. LANG=C (notably SCO).
 lt_user_locale=
 lt_safe_locale=
 for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
@@ -107,24 +118,33 @@ do
 	  lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\"
 	fi"
 done
+LC_ALL=C
+LANGUAGE=C
+export LANGUAGE LC_ALL
 
 $lt_unset CDPATH
 
 
+# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
+# is ksh but when the shell is invoked as "sh" and the current value of
+# the _XPG environment variable is not equal to 1 (one), the special
+# positional parameter $0, within a function call, is the name of the
+# function.
+progpath="$0"
 
 
 
 : ${CP="cp -f"}
-: ${ECHO="echo"}
-: ${EGREP="/bin/grep -E"}
-: ${FGREP="/bin/grep -F"}
-: ${GREP="/bin/grep"}
+test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'}
+: ${EGREP="grep -E"}
+: ${FGREP="grep -F"}
+: ${GREP="grep"}
 : ${LN_S="ln -s"}
 : ${MAKE="make"}
 : ${MKDIR="mkdir"}
 : ${MV="mv -f"}
 : ${RM="rm -f"}
-: ${SED="/bin/sed"}
+: ${SED="sed"}
 : ${SHELL="${CONFIG_SHELL-/bin/sh}"}
 : ${Xsed="$SED -e 1s/^X//"}
 
@@ -144,6 +164,27 @@ IFS=" 	$lt_nl"
 dirname="s,/[^/]*$,,"
 basename="s,^.*/,,"
 
+# func_dirname file append nondir_replacement
+# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
+# otherwise set result to NONDIR_REPLACEMENT.
+func_dirname ()
+{
+    func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
+    if test "X$func_dirname_result" = "X${1}"; then
+      func_dirname_result="${3}"
+    else
+      func_dirname_result="$func_dirname_result${2}"
+    fi
+} # func_dirname may be replaced by extended shell implementation
+
+
+# func_basename file
+func_basename ()
+{
+    func_basename_result=`$ECHO "${1}" | $SED "$basename"`
+} # func_basename may be replaced by extended shell implementation
+
+
 # func_dirname_and_basename file append nondir_replacement
 # perform func_basename and func_dirname in a single function
 # call:
@@ -158,33 +199,183 @@ basename="s,^.*/,,"
 # those functions but instead duplicate the functionality here.
 func_dirname_and_basename ()
 {
-  # Extract subdirectory from the argument.
-  func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
-  if test "X$func_dirname_result" = "X${1}"; then
-    func_dirname_result="${3}"
-  else
-    func_dirname_result="$func_dirname_result${2}"
-  fi
-  func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
+    # Extract subdirectory from the argument.
+    func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"`
+    if test "X$func_dirname_result" = "X${1}"; then
+      func_dirname_result="${3}"
+    else
+      func_dirname_result="$func_dirname_result${2}"
+    fi
+    func_basename_result=`$ECHO "${1}" | $SED -e "$basename"`
+} # func_dirname_and_basename may be replaced by extended shell implementation
+
+
+# func_stripname prefix suffix name
+# strip PREFIX and SUFFIX off of NAME.
+# PREFIX and SUFFIX must not contain globbing or regex special
+# characters, hashes, percent signs, but SUFFIX may contain a leading
+# dot (in which case that matches only a dot).
+# func_strip_suffix prefix name
+func_stripname ()
+{
+    case ${2} in
+      .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
+      *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
+    esac
+} # func_stripname may be replaced by extended shell implementation
+
+
+# These SED scripts presuppose an absolute path with a trailing slash.
+pathcar='s,^/\([^/]*\).*$,\1,'
+pathcdr='s,^/[^/]*,,'
+removedotparts=':dotsl
+		s@/\./@/@g
+		t dotsl
+		s,/\.$,/,'
+collapseslashes='s@/\{1,\}@/@g'
+finalslash='s,/*$,/,'
+
+# func_normal_abspath PATH
+# Remove doubled-up and trailing slashes, "." path components,
+# and cancel out any ".." path components in PATH after making
+# it an absolute path.
+#             value returned in "$func_normal_abspath_result"
+func_normal_abspath ()
+{
+  # Start from root dir and reassemble the path.
+  func_normal_abspath_result=
+  func_normal_abspath_tpath=$1
+  func_normal_abspath_altnamespace=
+  case $func_normal_abspath_tpath in
+    "")
+      # Empty path, that just means $cwd.
+      func_stripname '' '/' "`pwd`"
+      func_normal_abspath_result=$func_stripname_result
+      return
+    ;;
+    # The next three entries are used to spot a run of precisely
+    # two leading slashes without using negated character classes;
+    # we take advantage of case's first-match behaviour.
+    ///*)
+      # Unusual form of absolute path, do nothing.
+    ;;
+    //*)
+      # Not necessarily an ordinary path; POSIX reserves leading '//'
+      # and for example Cygwin uses it to access remote file shares
+      # over CIFS/SMB, so we conserve a leading double slash if found.
+      func_normal_abspath_altnamespace=/
+    ;;
+    /*)
+      # Absolute path, do nothing.
+    ;;
+    *)
+      # Relative path, prepend $cwd.
+      func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath
+    ;;
+  esac
+  # Cancel out all the simple stuff to save iterations.  We also want
+  # the path to end with a slash for ease of parsing, so make sure
+  # there is one (and only one) here.
+  func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
+        -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"`
+  while :; do
+    # Processed it all yet?
+    if test "$func_normal_abspath_tpath" = / ; then
+      # If we ascended to the root using ".." the result may be empty now.
+      if test -z "$func_normal_abspath_result" ; then
+        func_normal_abspath_result=/
+      fi
+      break
+    fi
+    func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \
+        -e "$pathcar"`
+    func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
+        -e "$pathcdr"`
+    # Figure out what to do with it
+    case $func_normal_abspath_tcomponent in
+      "")
+        # Trailing empty path component, ignore it.
+      ;;
+      ..)
+        # Parent dir; strip last assembled component from result.
+        func_dirname "$func_normal_abspath_result"
+        func_normal_abspath_result=$func_dirname_result
+      ;;
+      *)
+        # Actual path component, append it.
+        func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent
+      ;;
+    esac
+  done
+  # Restore leading double-slash if one was found on entry.
+  func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result
 }
 
-# Generated shell functions inserted here.
+# func_relative_path SRCDIR DSTDIR
+# generates a relative path from SRCDIR to DSTDIR, with a trailing
+# slash if non-empty, suitable for immediately appending a filename
+# without needing to append a separator.
+#             value returned in "$func_relative_path_result"
+func_relative_path ()
+{
+  func_relative_path_result=
+  func_normal_abspath "$1"
+  func_relative_path_tlibdir=$func_normal_abspath_result
+  func_normal_abspath "$2"
+  func_relative_path_tbindir=$func_normal_abspath_result
+
+  # Ascend the tree starting from libdir
+  while :; do
+    # check if we have found a prefix of bindir
+    case $func_relative_path_tbindir in
+      $func_relative_path_tlibdir)
+        # found an exact match
+        func_relative_path_tcancelled=
+        break
+        ;;
+      $func_relative_path_tlibdir*)
+        # found a matching prefix
+        func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir"
+        func_relative_path_tcancelled=$func_stripname_result
+        if test -z "$func_relative_path_result"; then
+          func_relative_path_result=.
+        fi
+        break
+        ;;
+      *)
+        func_dirname $func_relative_path_tlibdir
+        func_relative_path_tlibdir=${func_dirname_result}
+        if test "x$func_relative_path_tlibdir" = x ; then
+          # Have to descend all the way to the root!
+          func_relative_path_result=../$func_relative_path_result
+          func_relative_path_tcancelled=$func_relative_path_tbindir
+          break
+        fi
+        func_relative_path_result=../$func_relative_path_result
+        ;;
+    esac
+  done
 
-# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
-# is ksh but when the shell is invoked as "sh" and the current value of
-# the _XPG environment variable is not equal to 1 (one), the special
-# positional parameter $0, within a function call, is the name of the
-# function.
-progpath="$0"
+  # Now calculate path; take care to avoid doubling-up slashes.
+  func_stripname '' '/' "$func_relative_path_result"
+  func_relative_path_result=$func_stripname_result
+  func_stripname '/' '/' "$func_relative_path_tcancelled"
+  if test "x$func_stripname_result" != x ; then
+    func_relative_path_result=${func_relative_path_result}/${func_stripname_result}
+  fi
+
+  # Normalisation. If bindir is libdir, return empty string,
+  # else relative path ending with a slash; either way, target
+  # file name can be directly appended.
+  if test ! -z "$func_relative_path_result"; then
+    func_stripname './' '' "$func_relative_path_result/"
+    func_relative_path_result=$func_stripname_result
+  fi
+}
 
 # The name of this program:
-# In the unlikely event $progname began with a '-', it would play havoc with
-# func_echo (imagine progname=-n), so we prepend ./ in that case:
 func_dirname_and_basename "$progpath"
 progname=$func_basename_result
-case $progname in
-  -*) progname=./$progname ;;
-esac
 
 # Make sure we have an absolute path for reexecution:
 case $progpath in
@@ -215,6 +406,15 @@ sed_quote_subst='s/\([`"$\\]\)/\\\1/g'
 # Same as above, but do not quote variable references.
 double_quote_subst='s/\(["`\\]\)/\\\1/g'
 
+# Sed substitution that turns a string into a regex matching for the
+# string literally.
+sed_make_literal_regex='s,[].[^$\\*\/],\\&,g'
+
+# Sed substitution that converts a w32 file name or path
+# which contains forward slashes, into one that contains
+# (escaped) backslashes.  A very naive implementation.
+lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
+
 # Re-`\' parameter expansions in output of double_quote_subst that were
 # `\'-ed in input to the same.  If an odd number of `\' preceded a '$'
 # in input to double_quote_subst, that '$' was protected from expansion.
@@ -243,7 +443,7 @@ opt_warning=:
 # name if it has been set yet.
 func_echo ()
 {
-    $ECHO "$progname${mode+: }$mode: $*"
+    $ECHO "$progname: ${opt_mode+$opt_mode: }$*"
 }
 
 # func_verbose arg...
@@ -258,18 +458,25 @@ func_verbose ()
     :
 }
 
+# func_echo_all arg...
+# Invoke $ECHO with all args, space-separated.
+func_echo_all ()
+{
+    $ECHO "$*"
+}
+
 # func_error arg...
 # Echo program name prefixed message to standard error.
 func_error ()
 {
-    $ECHO "$progname${mode+: }$mode: "${1+"$@"} 1>&2
+    $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2
 }
 
 # func_warning arg...
 # Echo program name prefixed warning message to standard error.
 func_warning ()
 {
-    $opt_warning && $ECHO "$progname${mode+: }$mode: warning: "${1+"$@"} 1>&2
+    $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2
 
     # bash bug again:
     :
@@ -326,9 +533,9 @@ func_mkdir_p ()
         case $my_directory_path in */*) ;; *) break ;; esac
 
         # ...otherwise throw away the child directory and loop
-        my_directory_path=`$ECHO "X$my_directory_path" | $Xsed -e "$dirname"`
+        my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"`
       done
-      my_dir_list=`$ECHO "X$my_dir_list" | $Xsed -e 's,:*$,,'`
+      my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'`
 
       save_mkdir_p_IFS="$IFS"; IFS=':'
       for my_dir in $my_dir_list; do
@@ -378,7 +585,7 @@ func_mktempdir ()
         func_fatal_error "cannot create temporary directory \`$my_tmpdir'"
     fi
 
-    $ECHO "X$my_tmpdir" | $Xsed
+    $ECHO "$my_tmpdir"
 }
 
 
@@ -392,7 +599,7 @@ func_quote_for_eval ()
 {
     case $1 in
       *[\\\`\"\$]*)
-	func_quote_for_eval_unquoted_result=`$ECHO "X$1" | $Xsed -e "$sed_quote_subst"` ;;
+	func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;;
       *)
         func_quote_for_eval_unquoted_result="$1" ;;
     esac
@@ -419,7 +626,7 @@ func_quote_for_expand ()
 {
     case $1 in
       *[\\\`\"]*)
-	my_arg=`$ECHO "X$1" | $Xsed \
+	my_arg=`$ECHO "$1" | $SED \
 	    -e "$double_quote_subst" -e "$sed_double_backslash"` ;;
       *)
         my_arg="$1" ;;
@@ -488,15 +695,39 @@ func_show_eval_locale ()
     fi
 }
 
-
-
+# func_tr_sh
+# Turn $1 into a string suitable for a shell variable name.
+# Result is stored in $func_tr_sh_result.  All characters
+# not in the set a-zA-Z0-9_ are replaced with '_'. Further,
+# if $1 begins with a digit, a '_' is prepended as well.
+func_tr_sh ()
+{
+  case $1 in
+  [0-9]* | *[!a-zA-Z0-9_]*)
+    func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'`
+    ;;
+  * )
+    func_tr_sh_result=$1
+    ;;
+  esac
+}
 
 
 # func_version
 # Echo version message to standard output and exit.
 func_version ()
 {
-    $SED -n '/^# '$PROGRAM' (GNU /,/# warranty; / {
+    $opt_debug
+
+    $SED -n '/(C)/!b go
+	:more
+	/\./!{
+	  N
+	  s/\n# / /
+	  b more
+	}
+	:go
+	/^# '$PROGRAM' (GNU /,/# warranty; / {
         s/^# //
 	s/^# *$//
         s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/
@@ -509,22 +740,28 @@ func_version ()
 # Echo short help message to standard output and exit.
 func_usage ()
 {
-    $SED -n '/^# Usage:/,/# -h/ {
+    $opt_debug
+
+    $SED -n '/^# Usage:/,/^#  *.*--help/ {
         s/^# //
 	s/^# *$//
 	s/\$progname/'$progname'/
 	p
     }' < "$progpath"
-    $ECHO
+    echo
     $ECHO "run \`$progname --help | more' for full usage"
     exit $?
 }
 
-# func_help
-# Echo long help message to standard output and exit.
+# func_help [NOEXIT]
+# Echo long help message to standard output and exit,
+# unless 'noexit' is passed as argument.
 func_help ()
 {
+    $opt_debug
+
     $SED -n '/^# Usage:/,/# Report bugs to/ {
+	:print
         s/^# //
 	s/^# *$//
 	s*\$progname*'$progname'*
@@ -537,8 +774,15 @@ func_help ()
 	s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/
 	s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/
 	p
-     }' < "$progpath"
-    exit $?
+	d
+     }
+     /^# .* home page:/b print
+     /^# General help using/b print
+     ' < "$progpath"
+    ret=$?
+    if test -z "$1"; then
+      exit $ret
+    fi
 }
 
 # func_missing_arg argname
@@ -546,63 +790,106 @@ func_help ()
 # exit_cmd.
 func_missing_arg ()
 {
-    func_error "missing argument for $1"
+    $opt_debug
+
+    func_error "missing argument for $1."
     exit_cmd=exit
 }
 
-exit_cmd=:
 
+# func_split_short_opt shortopt
+# Set func_split_short_opt_name and func_split_short_opt_arg shell
+# variables after splitting SHORTOPT after the 2nd character.
+func_split_short_opt ()
+{
+    my_sed_short_opt='1s/^\(..\).*$/\1/;q'
+    my_sed_short_rest='1s/^..\(.*\)$/\1/;q'
 
+    func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"`
+    func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"`
+} # func_split_short_opt may be replaced by extended shell implementation
+
+
+# func_split_long_opt longopt
+# Set func_split_long_opt_name and func_split_long_opt_arg shell
+# variables after splitting LONGOPT at the `=' sign.
+func_split_long_opt ()
+{
+    my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q'
+    my_sed_long_arg='1s/^--[^=]*=//'
+
+    func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"`
+    func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"`
+} # func_split_long_opt may be replaced by extended shell implementation
+
+exit_cmd=:
 
 
 
-# Check that we have a working $ECHO.
-if test "X$1" = X--no-reexec; then
-  # Discard the --no-reexec flag, and continue.
-  shift
-elif test "X$1" = X--fallback-echo; then
-  # Avoid inline document here, it may be left over
-  :
-elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t'; then
-  # Yippee, $ECHO works!
-  :
-else
-  # Restart under the correct shell, and then maybe $ECHO will work.
-  exec $SHELL "$progpath" --no-reexec ${1+"$@"}
-fi
 
-if test "X$1" = X--fallback-echo; then
-  # used as fallback echo
-  shift
-  cat <<EOF
-$*
-EOF
-  exit $EXIT_SUCCESS
-fi
 
 magic="%%%MAGIC variable%%%"
 magic_exe="%%%MAGIC EXE variable%%%"
 
 # Global variables.
-# $mode is unset
 nonopt=
-execute_dlfiles=
 preserve_args=
 lo2o="s/\\.lo\$/.${objext}/"
 o2lo="s/\\.${objext}\$/.lo/"
 extracted_archives=
 extracted_serial=0
 
-opt_dry_run=false
-opt_duplicate_deps=false
-opt_silent=false
-opt_debug=:
-
 # If this variable is set in any of the actions, the command in it
 # will be execed at the end.  This prevents here-documents from being
 # left over by shells.
 exec_cmd=
 
+# func_append var value
+# Append VALUE to the end of shell variable VAR.
+func_append ()
+{
+    eval "${1}=\$${1}\${2}"
+} # func_append may be replaced by extended shell implementation
+
+# func_append_quoted var value
+# Quote VALUE and append to the end of shell variable VAR, separated
+# by a space.
+func_append_quoted ()
+{
+    func_quote_for_eval "${2}"
+    eval "${1}=\$${1}\\ \$func_quote_for_eval_result"
+} # func_append_quoted may be replaced by extended shell implementation
+
+
+# func_arith arithmetic-term...
+func_arith ()
+{
+    func_arith_result=`expr "${@}"`
+} # func_arith may be replaced by extended shell implementation
+
+
+# func_len string
+# STRING may not start with a hyphen.
+func_len ()
+{
+    func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len`
+} # func_len may be replaced by extended shell implementation
+
+
+# func_lo2o object
+func_lo2o ()
+{
+    func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
+} # func_lo2o may be replaced by extended shell implementation
+
+
+# func_xform libobj-or-source
+func_xform ()
+{
+    func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
+} # func_xform may be replaced by extended shell implementation
+
+
 # func_fatal_configuration arg...
 # Echo program name prefixed message to standard error, followed by
 # a configuration failure hint, and exit.
@@ -636,16 +923,16 @@ func_config ()
 # Display the features supported by this script.
 func_features ()
 {
-    $ECHO "host: $host"
+    echo "host: $host"
     if test "$build_libtool_libs" = yes; then
-      $ECHO "enable shared libraries"
+      echo "enable shared libraries"
     else
-      $ECHO "disable shared libraries"
+      echo "disable shared libraries"
     fi
     if test "$build_old_libs" = yes; then
-      $ECHO "enable static libraries"
+      echo "enable static libraries"
     else
-      $ECHO "disable static libraries"
+      echo "disable static libraries"
     fi
 
     exit $?
@@ -692,117 +979,204 @@ func_enable_tag ()
   esac
 }
 
-# Parse options once, thoroughly.  This comes as soon as possible in
-# the script to make things like `libtool --version' happen quickly.
+# func_check_version_match
+# Ensure that we are using m4 macros, and libtool script from the same
+# release of libtool.
+func_check_version_match ()
 {
+  if test "$package_revision" != "$macro_revision"; then
+    if test "$VERSION" != "$macro_version"; then
+      if test -z "$macro_version"; then
+        cat >&2 <<_LT_EOF
+$progname: Version mismatch error.  This is $PACKAGE $VERSION, but the
+$progname: definition of this LT_INIT comes from an older release.
+$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
+$progname: and run autoconf again.
+_LT_EOF
+      else
+        cat >&2 <<_LT_EOF
+$progname: Version mismatch error.  This is $PACKAGE $VERSION, but the
+$progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
+$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
+$progname: and run autoconf again.
+_LT_EOF
+      fi
+    else
+      cat >&2 <<_LT_EOF
+$progname: Version mismatch error.  This is $PACKAGE $VERSION, revision $package_revision,
+$progname: but the definition of this LT_INIT comes from revision $macro_revision.
+$progname: You should recreate aclocal.m4 with macros from revision $package_revision
+$progname: of $PACKAGE $VERSION and run autoconf again.
+_LT_EOF
+    fi
 
-  # Shorthand for --mode=foo, only valid as the first argument
-  case $1 in
-  clean|clea|cle|cl)
-    shift; set dummy --mode clean ${1+"$@"}; shift
-    ;;
-  compile|compil|compi|comp|com|co|c)
-    shift; set dummy --mode compile ${1+"$@"}; shift
-    ;;
-  execute|execut|execu|exec|exe|ex|e)
-    shift; set dummy --mode execute ${1+"$@"}; shift
-    ;;
-  finish|finis|fini|fin|fi|f)
-    shift; set dummy --mode finish ${1+"$@"}; shift
-    ;;
-  install|instal|insta|inst|ins|in|i)
-    shift; set dummy --mode install ${1+"$@"}; shift
-    ;;
-  link|lin|li|l)
-    shift; set dummy --mode link ${1+"$@"}; shift
-    ;;
-  uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
-    shift; set dummy --mode uninstall ${1+"$@"}; shift
-    ;;
-  esac
+    exit $EXIT_MISMATCH
+  fi
+}
+
+
+# Shorthand for --mode=foo, only valid as the first argument
+case $1 in
+clean|clea|cle|cl)
+  shift; set dummy --mode clean ${1+"$@"}; shift
+  ;;
+compile|compil|compi|comp|com|co|c)
+  shift; set dummy --mode compile ${1+"$@"}; shift
+  ;;
+execute|execut|execu|exec|exe|ex|e)
+  shift; set dummy --mode execute ${1+"$@"}; shift
+  ;;
+finish|finis|fini|fin|fi|f)
+  shift; set dummy --mode finish ${1+"$@"}; shift
+  ;;
+install|instal|insta|inst|ins|in|i)
+  shift; set dummy --mode install ${1+"$@"}; shift
+  ;;
+link|lin|li|l)
+  shift; set dummy --mode link ${1+"$@"}; shift
+  ;;
+uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
+  shift; set dummy --mode uninstall ${1+"$@"}; shift
+  ;;
+esac
+
+
+
+# Option defaults:
+opt_debug=:
+opt_dry_run=false
+opt_config=false
+opt_preserve_dup_deps=false
+opt_features=false
+opt_finish=false
+opt_help=false
+opt_help_all=false
+opt_silent=:
+opt_verbose=:
+opt_silent=false
+opt_verbose=false
 
-  # Parse non-mode specific arguments:
-  while test "$#" -gt 0; do
+
+# Parse options once, thoroughly.  This comes as soon as possible in the
+# script to make things like `--version' happen as quickly as we can.
+{
+  # this just eases exit handling
+  while test $# -gt 0; do
     opt="$1"
     shift
-
     case $opt in
-      --config)		func_config					;;
-
-      --debug)		preserve_args="$preserve_args $opt"
+      --debug|-x)	opt_debug='set -x'
 			func_echo "enabling shell trace mode"
-			opt_debug='set -x'
 			$opt_debug
 			;;
-
-      -dlopen)		test "$#" -eq 0 && func_missing_arg "$opt" && break
-			execute_dlfiles="$execute_dlfiles $1"
-			shift
+      --dry-run|--dryrun|-n)
+			opt_dry_run=:
 			;;
-
-      --dry-run | -n)	opt_dry_run=:					;;
-      --features)       func_features					;;
-      --finish)		mode="finish"					;;
-
-      --mode)		test "$#" -eq 0 && func_missing_arg "$opt" && break
-			case $1 in
-			  # Valid mode arguments:
-			  clean)	;;
-			  compile)	;;
-			  execute)	;;
-			  finish)	;;
-			  install)	;;
-			  link)		;;
-			  relink)	;;
-			  uninstall)	;;
-
-			  # Catch anything else as an error
-			  *) func_error "invalid argument for $opt"
-			     exit_cmd=exit
-			     break
-			     ;;
-		        esac
-
-			mode="$1"
+      --config)
+			opt_config=:
+func_config
+			;;
+      --dlopen|-dlopen)
+			optarg="$1"
+			opt_dlopen="${opt_dlopen+$opt_dlopen
+}$optarg"
 			shift
 			;;
-
       --preserve-dup-deps)
-			opt_duplicate_deps=:				;;
-
-      --quiet|--silent)	preserve_args="$preserve_args $opt"
-			opt_silent=:
+			opt_preserve_dup_deps=:
 			;;
-
-      --verbose| -v)	preserve_args="$preserve_args $opt"
+      --features)
+			opt_features=:
+func_features
+			;;
+      --finish)
+			opt_finish=:
+set dummy --mode finish ${1+"$@"}; shift
+			;;
+      --help)
+			opt_help=:
+			;;
+      --help-all)
+			opt_help_all=:
+opt_help=': help-all'
+			;;
+      --mode)
+			test $# = 0 && func_missing_arg $opt && break
+			optarg="$1"
+			opt_mode="$optarg"
+case $optarg in
+  # Valid mode arguments:
+  clean|compile|execute|finish|install|link|relink|uninstall) ;;
+
+  # Catch anything else as an error
+  *) func_error "invalid argument for $opt"
+     exit_cmd=exit
+     break
+     ;;
+esac
+			shift
+			;;
+      --no-silent|--no-quiet)
 			opt_silent=false
+func_append preserve_args " $opt"
 			;;
-
-      --tag)		test "$#" -eq 0 && func_missing_arg "$opt" && break
-			preserve_args="$preserve_args $opt $1"
-			func_enable_tag "$1"	# tagname is set here
+      --no-verbose)
+			opt_verbose=false
+func_append preserve_args " $opt"
+			;;
+      --silent|--quiet)
+			opt_silent=:
+func_append preserve_args " $opt"
+        opt_verbose=false
+			;;
+      --verbose|-v)
+			opt_verbose=:
+func_append preserve_args " $opt"
+opt_silent=false
+			;;
+      --tag)
+			test $# = 0 && func_missing_arg $opt && break
+			optarg="$1"
+			opt_tag="$optarg"
+func_append preserve_args " $opt $optarg"
+func_enable_tag "$optarg"
 			shift
 			;;
 
+      -\?|-h)		func_usage				;;
+      --help)		func_help				;;
+      --version)	func_version				;;
+
       # Separate optargs to long options:
-      -dlopen=*|--mode=*|--tag=*)
-			func_opt_split "$opt"
-			set dummy "$func_opt_split_opt" "$func_opt_split_arg" ${1+"$@"}
+      --*=*)
+			func_split_long_opt "$opt"
+			set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"}
 			shift
 			;;
 
-      -\?|-h)		func_usage					;;
-      --help)		opt_help=:					;;
-      --version)	func_version					;;
-
-      -*)		func_fatal_help "unrecognized option \`$opt'"	;;
-
-      *)		nonopt="$opt"
-			break
+      # Separate non-argument short options:
+      -\?*|-h*|-n*|-v*)
+			func_split_short_opt "$opt"
+			set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"}
+			shift
 			;;
+
+      --)		break					;;
+      -*)		func_fatal_help "unrecognized option \`$opt'" ;;
+      *)		set dummy "$opt" ${1+"$@"};	shift; break  ;;
     esac
   done
 
+  # Validate options:
+
+  # save first non-option argument
+  if test "$#" -gt 0; then
+    nonopt="$opt"
+    shift
+  fi
+
+  # preserve --debug
+  test "$opt_debug" = : || func_append preserve_args " --debug"
 
   case $host in
     *cygwin* | *mingw* | *pw32* | *cegcc*)
@@ -810,82 +1184,44 @@ func_enable_tag ()
       opt_duplicate_compiler_generated_deps=:
       ;;
     *)
-      opt_duplicate_compiler_generated_deps=$opt_duplicate_deps
+      opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps
       ;;
   esac
 
-  # Having warned about all mis-specified options, bail out if
-  # anything was wrong.
-  $exit_cmd $EXIT_FAILURE
-}
+  $opt_help || {
+    # Sanity checks first:
+    func_check_version_match
 
-# func_check_version_match
-# Ensure that we are using m4 macros, and libtool script from the same
-# release of libtool.
-func_check_version_match ()
-{
-  if test "$package_revision" != "$macro_revision"; then
-    if test "$VERSION" != "$macro_version"; then
-      if test -z "$macro_version"; then
-        cat >&2 <<_LT_EOF
-$progname: Version mismatch error.  This is $PACKAGE $VERSION, but the
-$progname: definition of this LT_INIT comes from an older release.
-$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
-$progname: and run autoconf again.
-_LT_EOF
-      else
-        cat >&2 <<_LT_EOF
-$progname: Version mismatch error.  This is $PACKAGE $VERSION, but the
-$progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
-$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
-$progname: and run autoconf again.
-_LT_EOF
-      fi
-    else
-      cat >&2 <<_LT_EOF
-$progname: Version mismatch error.  This is $PACKAGE $VERSION, revision $package_revision,
-$progname: but the definition of this LT_INIT comes from revision $macro_revision.
-$progname: You should recreate aclocal.m4 with macros from revision $package_revision
-$progname: of $PACKAGE $VERSION and run autoconf again.
-_LT_EOF
+    if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
+      func_fatal_configuration "not configured to build any kind of library"
     fi
 
-    exit $EXIT_MISMATCH
-  fi
-}
-
-
-## ----------- ##
-##    Main.    ##
-## ----------- ##
-
-$opt_help || {
-  # Sanity checks first:
-  func_check_version_match
+    # Darwin sucks
+    eval std_shrext=\"$shrext_cmds\"
 
-  if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
-    func_fatal_configuration "not configured to build any kind of library"
-  fi
+    # Only execute mode is allowed to have -dlopen flags.
+    if test -n "$opt_dlopen" && test "$opt_mode" != execute; then
+      func_error "unrecognized option \`-dlopen'"
+      $ECHO "$help" 1>&2
+      exit $EXIT_FAILURE
+    fi
 
-  test -z "$mode" && func_fatal_error "error: you must specify a MODE."
+    # Change the help message to a mode-specific one.
+    generic_help="$help"
+    help="Try \`$progname --help --mode=$opt_mode' for more information."
+  }
 
 
-  # Darwin sucks
-  eval std_shrext=\"$shrext_cmds\"
+  # Bail if the options were screwed
+  $exit_cmd $EXIT_FAILURE
+}
 
 
-  # Only execute mode is allowed to have -dlopen flags.
-  if test -n "$execute_dlfiles" && test "$mode" != execute; then
-    func_error "unrecognized option \`-dlopen'"
-    $ECHO "$help" 1>&2
-    exit $EXIT_FAILURE
-  fi
 
-  # Change the help message to a mode-specific one.
-  generic_help="$help"
-  help="Try \`$progname --help --mode=$mode' for more information."
-}
 
+## ----------- ##
+##    Main.    ##
+## ----------- ##
 
 # func_lalib_p file
 # True iff FILE is a libtool `.la' library or `.lo' object file.
@@ -950,12 +1286,9 @@ func_ltwrapper_executable_p ()
 # temporary ltwrapper_script.
 func_ltwrapper_scriptname ()
 {
-    func_ltwrapper_scriptname_result=""
-    if func_ltwrapper_executable_p "$1"; then
-	func_dirname_and_basename "$1" "" "."
-	func_stripname '' '.exe' "$func_basename_result"
-	func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper"
-    fi
+    func_dirname_and_basename "$1" "" "."
+    func_stripname '' '.exe' "$func_basename_result"
+    func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper"
 }
 
 # func_ltwrapper_p file
@@ -1001,6 +1334,37 @@ func_source ()
 }
 
 
+# func_resolve_sysroot PATH
+# Replace a leading = in PATH with a sysroot.  Store the result into
+# func_resolve_sysroot_result
+func_resolve_sysroot ()
+{
+  func_resolve_sysroot_result=$1
+  case $func_resolve_sysroot_result in
+  =*)
+    func_stripname '=' '' "$func_resolve_sysroot_result"
+    func_resolve_sysroot_result=$lt_sysroot$func_stripname_result
+    ;;
+  esac
+}
+
+# func_replace_sysroot PATH
+# If PATH begins with the sysroot, replace it with = and
+# store the result into func_replace_sysroot_result.
+func_replace_sysroot ()
+{
+  case "$lt_sysroot:$1" in
+  ?*:"$lt_sysroot"*)
+    func_stripname "$lt_sysroot" '' "$1"
+    func_replace_sysroot_result="=$func_stripname_result"
+    ;;
+  *)
+    # Including no sysroot.
+    func_replace_sysroot_result=$1
+    ;;
+  esac
+}
+
 # func_infer_tag arg
 # Infer tagged configuration to use if any are available and
 # if one wasn't chosen via the "--tag" command line option.
@@ -1013,13 +1377,15 @@ func_infer_tag ()
     if test -n "$available_tags" && test -z "$tagname"; then
       CC_quoted=
       for arg in $CC; do
-        func_quote_for_eval "$arg"
-	CC_quoted="$CC_quoted $func_quote_for_eval_result"
+	func_append_quoted CC_quoted "$arg"
       done
+      CC_expanded=`func_echo_all $CC`
+      CC_quoted_expanded=`func_echo_all $CC_quoted`
       case $@ in
       # Blanks in the command may have been stripped by the calling shell,
       # but not from the CC environment variable when configure was run.
-      " $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*) ;;
+      " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \
+      " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;;
       # Blanks at the start of $base_compile will cause this to fail
       # if we don't check for them as well.
       *)
@@ -1030,11 +1396,13 @@ func_infer_tag ()
 	    CC_quoted=
 	    for arg in $CC; do
 	      # Double-quote args containing other shell metacharacters.
-	      func_quote_for_eval "$arg"
-	      CC_quoted="$CC_quoted $func_quote_for_eval_result"
+	      func_append_quoted CC_quoted "$arg"
 	    done
+	    CC_expanded=`func_echo_all $CC`
+	    CC_quoted_expanded=`func_echo_all $CC_quoted`
 	    case "$@ " in
-	      " $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*)
+	    " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \
+	    " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*)
 	      # The compiler in the base compile command matches
 	      # the one in the tagged configuration.
 	      # Assume this is the tagged configuration we want.
@@ -1097,6 +1465,486 @@ EOF
     }
 }
 
+
+##################################################
+# FILE NAME AND PATH CONVERSION HELPER FUNCTIONS #
+##################################################
+
+# func_convert_core_file_wine_to_w32 ARG
+# Helper function used by file name conversion functions when $build is *nix,
+# and $host is mingw, cygwin, or some other w32 environment. Relies on a
+# correctly configured wine environment available, with the winepath program
+# in $build's $PATH.
+#
+# ARG is the $build file name to be converted to w32 format.
+# Result is available in $func_convert_core_file_wine_to_w32_result, and will
+# be empty on error (or when ARG is empty)
+func_convert_core_file_wine_to_w32 ()
+{
+  $opt_debug
+  func_convert_core_file_wine_to_w32_result="$1"
+  if test -n "$1"; then
+    # Unfortunately, winepath does not exit with a non-zero error code, so we
+    # are forced to check the contents of stdout. On the other hand, if the
+    # command is not found, the shell will set an exit code of 127 and print
+    # *an error message* to stdout. So we must check for both error code of
+    # zero AND non-empty stdout, which explains the odd construction:
+    func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null`
+    if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then
+      func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" |
+        $SED -e "$lt_sed_naive_backslashify"`
+    else
+      func_convert_core_file_wine_to_w32_result=
+    fi
+  fi
+}
+# end: func_convert_core_file_wine_to_w32
+
+
+# func_convert_core_path_wine_to_w32 ARG
+# Helper function used by path conversion functions when $build is *nix, and
+# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly
+# configured wine environment available, with the winepath program in $build's
+# $PATH. Assumes ARG has no leading or trailing path separator characters.
+#
+# ARG is path to be converted from $build format to win32.
+# Result is available in $func_convert_core_path_wine_to_w32_result.
+# Unconvertible file (directory) names in ARG are skipped; if no directory names
+# are convertible, then the result may be empty.
+func_convert_core_path_wine_to_w32 ()
+{
+  $opt_debug
+  # unfortunately, winepath doesn't convert paths, only file names
+  func_convert_core_path_wine_to_w32_result=""
+  if test -n "$1"; then
+    oldIFS=$IFS
+    IFS=:
+    for func_convert_core_path_wine_to_w32_f in $1; do
+      IFS=$oldIFS
+      func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f"
+      if test -n "$func_convert_core_file_wine_to_w32_result" ; then
+        if test -z "$func_convert_core_path_wine_to_w32_result"; then
+          func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result"
+        else
+          func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result"
+        fi
+      fi
+    done
+    IFS=$oldIFS
+  fi
+}
+# end: func_convert_core_path_wine_to_w32
+
+
+# func_cygpath ARGS...
+# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when
+# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2)
+# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or
+# (2), returns the Cygwin file name or path in func_cygpath_result (input
+# file name or path is assumed to be in w32 format, as previously converted
+# from $build's *nix or MSYS format). In case (3), returns the w32 file name
+# or path in func_cygpath_result (input file name or path is assumed to be in
+# Cygwin format). Returns an empty string on error.
+#
+# ARGS are passed to cygpath, with the last one being the file name or path to
+# be converted.
+#
+# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH
+# environment variable; do not put it in $PATH.
+func_cygpath ()
+{
+  $opt_debug
+  if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then
+    func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null`
+    if test "$?" -ne 0; then
+      # on failure, ensure result is empty
+      func_cygpath_result=
+    fi
+  else
+    func_cygpath_result=
+    func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'"
+  fi
+}
+#end: func_cygpath
+
+
+# func_convert_core_msys_to_w32 ARG
+# Convert file name or path ARG from MSYS format to w32 format.  Return
+# result in func_convert_core_msys_to_w32_result.
+func_convert_core_msys_to_w32 ()
+{
+  $opt_debug
+  # awkward: cmd appends spaces to result
+  func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null |
+    $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"`
+}
+#end: func_convert_core_msys_to_w32
+
+
+# func_convert_file_check ARG1 ARG2
+# Verify that ARG1 (a file name in $build format) was converted to $host
+# format in ARG2. Otherwise, emit an error message, but continue (resetting
+# func_to_host_file_result to ARG1).
+func_convert_file_check ()
+{
+  $opt_debug
+  if test -z "$2" && test -n "$1" ; then
+    func_error "Could not determine host file name corresponding to"
+    func_error "  \`$1'"
+    func_error "Continuing, but uninstalled executables may not work."
+    # Fallback:
+    func_to_host_file_result="$1"
+  fi
+}
+# end func_convert_file_check
+
+
+# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH
+# Verify that FROM_PATH (a path in $build format) was converted to $host
+# format in TO_PATH. Otherwise, emit an error message, but continue, resetting
+# func_to_host_file_result to a simplistic fallback value (see below).
+func_convert_path_check ()
+{
+  $opt_debug
+  if test -z "$4" && test -n "$3"; then
+    func_error "Could not determine the host path corresponding to"
+    func_error "  \`$3'"
+    func_error "Continuing, but uninstalled executables may not work."
+    # Fallback.  This is a deliberately simplistic "conversion" and
+    # should not be "improved".  See libtool.info.
+    if test "x$1" != "x$2"; then
+      lt_replace_pathsep_chars="s|$1|$2|g"
+      func_to_host_path_result=`echo "$3" |
+        $SED -e "$lt_replace_pathsep_chars"`
+    else
+      func_to_host_path_result="$3"
+    fi
+  fi
+}
+# end func_convert_path_check
+
+
+# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG
+# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT
+# and appending REPL if ORIG matches BACKPAT.
+func_convert_path_front_back_pathsep ()
+{
+  $opt_debug
+  case $4 in
+  $1 ) func_to_host_path_result="$3$func_to_host_path_result"
+    ;;
+  esac
+  case $4 in
+  $2 ) func_append func_to_host_path_result "$3"
+    ;;
+  esac
+}
+# end func_convert_path_front_back_pathsep
+
+
+##################################################
+# $build to $host FILE NAME CONVERSION FUNCTIONS #
+##################################################
+# invoked via `$to_host_file_cmd ARG'
+#
+# In each case, ARG is the path to be converted from $build to $host format.
+# Result will be available in $func_to_host_file_result.
+
+
+# func_to_host_file ARG
+# Converts the file name ARG from $build format to $host format. Return result
+# in func_to_host_file_result.
+func_to_host_file ()
+{
+  $opt_debug
+  $to_host_file_cmd "$1"
+}
+# end func_to_host_file
+
+
+# func_to_tool_file ARG LAZY
+# converts the file name ARG from $build format to toolchain format. Return
+# result in func_to_tool_file_result.  If the conversion in use is listed
+# in (the comma separated) LAZY, no conversion takes place.
+func_to_tool_file ()
+{
+  $opt_debug
+  case ,$2, in
+    *,"$to_tool_file_cmd",*)
+      func_to_tool_file_result=$1
+      ;;
+    *)
+      $to_tool_file_cmd "$1"
+      func_to_tool_file_result=$func_to_host_file_result
+      ;;
+  esac
+}
+# end func_to_tool_file
+
+
+# func_convert_file_noop ARG
+# Copy ARG to func_to_host_file_result.
+func_convert_file_noop ()
+{
+  func_to_host_file_result="$1"
+}
+# end func_convert_file_noop
+
+
+# func_convert_file_msys_to_w32 ARG
+# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic
+# conversion to w32 is not available inside the cwrapper.  Returns result in
+# func_to_host_file_result.
+func_convert_file_msys_to_w32 ()
+{
+  $opt_debug
+  func_to_host_file_result="$1"
+  if test -n "$1"; then
+    func_convert_core_msys_to_w32 "$1"
+    func_to_host_file_result="$func_convert_core_msys_to_w32_result"
+  fi
+  func_convert_file_check "$1" "$func_to_host_file_result"
+}
+# end func_convert_file_msys_to_w32
+
+
+# func_convert_file_cygwin_to_w32 ARG
+# Convert file name ARG from Cygwin to w32 format.  Returns result in
+# func_to_host_file_result.
+func_convert_file_cygwin_to_w32 ()
+{
+  $opt_debug
+  func_to_host_file_result="$1"
+  if test -n "$1"; then
+    # because $build is cygwin, we call "the" cygpath in $PATH; no need to use
+    # LT_CYGPATH in this case.
+    func_to_host_file_result=`cygpath -m "$1"`
+  fi
+  func_convert_file_check "$1" "$func_to_host_file_result"
+}
+# end func_convert_file_cygwin_to_w32
+
+
+# func_convert_file_nix_to_w32 ARG
+# Convert file name ARG from *nix to w32 format.  Requires a wine environment
+# and a working winepath. Returns result in func_to_host_file_result.
+func_convert_file_nix_to_w32 ()
+{
+  $opt_debug
+  func_to_host_file_result="$1"
+  if test -n "$1"; then
+    func_convert_core_file_wine_to_w32 "$1"
+    func_to_host_file_result="$func_convert_core_file_wine_to_w32_result"
+  fi
+  func_convert_file_check "$1" "$func_to_host_file_result"
+}
+# end func_convert_file_nix_to_w32
+
+
+# func_convert_file_msys_to_cygwin ARG
+# Convert file name ARG from MSYS to Cygwin format.  Requires LT_CYGPATH set.
+# Returns result in func_to_host_file_result.
+func_convert_file_msys_to_cygwin ()
+{
+  $opt_debug
+  func_to_host_file_result="$1"
+  if test -n "$1"; then
+    func_convert_core_msys_to_w32 "$1"
+    func_cygpath -u "$func_convert_core_msys_to_w32_result"
+    func_to_host_file_result="$func_cygpath_result"
+  fi
+  func_convert_file_check "$1" "$func_to_host_file_result"
+}
+# end func_convert_file_msys_to_cygwin
+
+
+# func_convert_file_nix_to_cygwin ARG
+# Convert file name ARG from *nix to Cygwin format.  Requires Cygwin installed
+# in a wine environment, working winepath, and LT_CYGPATH set.  Returns result
+# in func_to_host_file_result.
+func_convert_file_nix_to_cygwin ()
+{
+  $opt_debug
+  func_to_host_file_result="$1"
+  if test -n "$1"; then
+    # convert from *nix to w32, then use cygpath to convert from w32 to cygwin.
+    func_convert_core_file_wine_to_w32 "$1"
+    func_cygpath -u "$func_convert_core_file_wine_to_w32_result"
+    func_to_host_file_result="$func_cygpath_result"
+  fi
+  func_convert_file_check "$1" "$func_to_host_file_result"
+}
+# end func_convert_file_nix_to_cygwin
+
+
+#############################################
+# $build to $host PATH CONVERSION FUNCTIONS #
+#############################################
+# invoked via `$to_host_path_cmd ARG'
+#
+# In each case, ARG is the path to be converted from $build to $host format.
+# The result will be available in $func_to_host_path_result.
+#
+# Path separators are also converted from $build format to $host format.  If
+# ARG begins or ends with a path separator character, it is preserved (but
+# converted to $host format) on output.
+#
+# All path conversion functions are named using the following convention:
+#   file name conversion function    : func_convert_file_X_to_Y ()
+#   path conversion function         : func_convert_path_X_to_Y ()
+# where, for any given $build/$host combination the 'X_to_Y' value is the
+# same.  If conversion functions are added for new $build/$host combinations,
+# the two new functions must follow this pattern, or func_init_to_host_path_cmd
+# will break.
+
+
+# func_init_to_host_path_cmd
+# Ensures that function "pointer" variable $to_host_path_cmd is set to the
+# appropriate value, based on the value of $to_host_file_cmd.
+to_host_path_cmd=
+func_init_to_host_path_cmd ()
+{
+  $opt_debug
+  if test -z "$to_host_path_cmd"; then
+    func_stripname 'func_convert_file_' '' "$to_host_file_cmd"
+    to_host_path_cmd="func_convert_path_${func_stripname_result}"
+  fi
+}
+
+
+# func_to_host_path ARG
+# Converts the path ARG from $build format to $host format. Return result
+# in func_to_host_path_result.
+func_to_host_path ()
+{
+  $opt_debug
+  func_init_to_host_path_cmd
+  $to_host_path_cmd "$1"
+}
+# end func_to_host_path
+
+
+# func_convert_path_noop ARG
+# Copy ARG to func_to_host_path_result.
+func_convert_path_noop ()
+{
+  func_to_host_path_result="$1"
+}
+# end func_convert_path_noop
+
+
+# func_convert_path_msys_to_w32 ARG
+# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic
+# conversion to w32 is not available inside the cwrapper.  Returns result in
+# func_to_host_path_result.
+func_convert_path_msys_to_w32 ()
+{
+  $opt_debug
+  func_to_host_path_result="$1"
+  if test -n "$1"; then
+    # Remove leading and trailing path separator characters from ARG.  MSYS
+    # behavior is inconsistent here; cygpath turns them into '.;' and ';.';
+    # and winepath ignores them completely.
+    func_stripname : : "$1"
+    func_to_host_path_tmp1=$func_stripname_result
+    func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
+    func_to_host_path_result="$func_convert_core_msys_to_w32_result"
+    func_convert_path_check : ";" \
+      "$func_to_host_path_tmp1" "$func_to_host_path_result"
+    func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
+  fi
+}
+# end func_convert_path_msys_to_w32
+
+
+# func_convert_path_cygwin_to_w32 ARG
+# Convert path ARG from Cygwin to w32 format.  Returns result in
+# func_to_host_file_result.
+func_convert_path_cygwin_to_w32 ()
+{
+  $opt_debug
+  func_to_host_path_result="$1"
+  if test -n "$1"; then
+    # See func_convert_path_msys_to_w32:
+    func_stripname : : "$1"
+    func_to_host_path_tmp1=$func_stripname_result
+    func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"`
+    func_convert_path_check : ";" \
+      "$func_to_host_path_tmp1" "$func_to_host_path_result"
+    func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
+  fi
+}
+# end func_convert_path_cygwin_to_w32
+
+
+# func_convert_path_nix_to_w32 ARG
+# Convert path ARG from *nix to w32 format.  Requires a wine environment and
+# a working winepath.  Returns result in func_to_host_file_result.
+func_convert_path_nix_to_w32 ()
+{
+  $opt_debug
+  func_to_host_path_result="$1"
+  if test -n "$1"; then
+    # See func_convert_path_msys_to_w32:
+    func_stripname : : "$1"
+    func_to_host_path_tmp1=$func_stripname_result
+    func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
+    func_to_host_path_result="$func_convert_core_path_wine_to_w32_result"
+    func_convert_path_check : ";" \
+      "$func_to_host_path_tmp1" "$func_to_host_path_result"
+    func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
+  fi
+}
+# end func_convert_path_nix_to_w32
+
+
+# func_convert_path_msys_to_cygwin ARG
+# Convert path ARG from MSYS to Cygwin format.  Requires LT_CYGPATH set.
+# Returns result in func_to_host_file_result.
+func_convert_path_msys_to_cygwin ()
+{
+  $opt_debug
+  func_to_host_path_result="$1"
+  if test -n "$1"; then
+    # See func_convert_path_msys_to_w32:
+    func_stripname : : "$1"
+    func_to_host_path_tmp1=$func_stripname_result
+    func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
+    func_cygpath -u -p "$func_convert_core_msys_to_w32_result"
+    func_to_host_path_result="$func_cygpath_result"
+    func_convert_path_check : : \
+      "$func_to_host_path_tmp1" "$func_to_host_path_result"
+    func_convert_path_front_back_pathsep ":*" "*:" : "$1"
+  fi
+}
+# end func_convert_path_msys_to_cygwin
+
+
+# func_convert_path_nix_to_cygwin ARG
+# Convert path ARG from *nix to Cygwin format.  Requires Cygwin installed in a
+# a wine environment, working winepath, and LT_CYGPATH set.  Returns result in
+# func_to_host_file_result.
+func_convert_path_nix_to_cygwin ()
+{
+  $opt_debug
+  func_to_host_path_result="$1"
+  if test -n "$1"; then
+    # Remove leading and trailing path separator characters from
+    # ARG. msys behavior is inconsistent here, cygpath turns them
+    # into '.;' and ';.', and winepath ignores them completely.
+    func_stripname : : "$1"
+    func_to_host_path_tmp1=$func_stripname_result
+    func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
+    func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result"
+    func_to_host_path_result="$func_cygpath_result"
+    func_convert_path_check : : \
+      "$func_to_host_path_tmp1" "$func_to_host_path_result"
+    func_convert_path_front_back_pathsep ":*" "*:" : "$1"
+  fi
+}
+# end func_convert_path_nix_to_cygwin
+
+
 # func_mode_compile arg...
 func_mode_compile ()
 {
@@ -1137,12 +1985,12 @@ func_mode_compile ()
 	  ;;
 
 	-pie | -fpie | -fPIE)
-          pie_flag="$pie_flag $arg"
+          func_append pie_flag " $arg"
 	  continue
 	  ;;
 
 	-shared | -static | -prefer-pic | -prefer-non-pic)
-	  later="$later $arg"
+	  func_append later " $arg"
 	  continue
 	  ;;
 
@@ -1163,15 +2011,14 @@ func_mode_compile ()
 	  save_ifs="$IFS"; IFS=','
 	  for arg in $args; do
 	    IFS="$save_ifs"
-	    func_quote_for_eval "$arg"
-	    lastarg="$lastarg $func_quote_for_eval_result"
+	    func_append_quoted lastarg "$arg"
 	  done
 	  IFS="$save_ifs"
 	  func_stripname ' ' '' "$lastarg"
 	  lastarg=$func_stripname_result
 
 	  # Add the arguments to base_compile.
-	  base_compile="$base_compile $lastarg"
+	  func_append base_compile " $lastarg"
 	  continue
 	  ;;
 
@@ -1187,8 +2034,7 @@ func_mode_compile ()
       esac    #  case $arg_mode
 
       # Aesthetically quote the previous argument.
-      func_quote_for_eval "$lastarg"
-      base_compile="$base_compile $func_quote_for_eval_result"
+      func_append_quoted base_compile "$lastarg"
     done # for arg
 
     case $arg_mode in
@@ -1213,7 +2059,7 @@ func_mode_compile ()
     *.[cCFSifmso] | \
     *.ada | *.adb | *.ads | *.asm | \
     *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \
-    *.[fF][09]? | *.for | *.java | *.obj | *.sx)
+    *.[fF][09]? | *.for | *.java | *.obj | *.sx | *.cu | *.cup)
       func_xform "$libobj"
       libobj=$func_xform_result
       ;;
@@ -1288,7 +2134,7 @@ func_mode_compile ()
     # Calculate the filename of the output object if compiler does
     # not support -o with -c
     if test "$compiler_c_o" = no; then
-      output_obj=`$ECHO "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext}
+      output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext}
       lockfile="$output_obj.lock"
     else
       output_obj=
@@ -1319,17 +2165,16 @@ compiler."
 	$opt_dry_run || $RM $removelist
 	exit $EXIT_FAILURE
       fi
-      removelist="$removelist $output_obj"
+      func_append removelist " $output_obj"
       $ECHO "$srcfile" > "$lockfile"
     fi
 
     $opt_dry_run || $RM $removelist
-    removelist="$removelist $lockfile"
+    func_append removelist " $lockfile"
     trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15
 
-    if test -n "$fix_srcfile_path"; then
-      eval srcfile=\"$fix_srcfile_path\"
-    fi
+    func_to_tool_file "$srcfile" func_convert_file_msys_to_w32
+    srcfile=$func_to_tool_file_result
     func_quote_for_eval "$srcfile"
     qsrcfile=$func_quote_for_eval_result
 
@@ -1349,7 +2194,7 @@ compiler."
 
       if test -z "$output_obj"; then
 	# Place PIC objects in $objdir
-	command="$command -o $lobj"
+	func_append command " -o $lobj"
       fi
 
       func_show_eval_locale "$command"	\
@@ -1396,11 +2241,11 @@ compiler."
 	command="$base_compile $qsrcfile $pic_flag"
       fi
       if test "$compiler_c_o" = yes; then
-	command="$command -o $obj"
+	func_append command " -o $obj"
       fi
 
       # Suppress compiler output if we already did a PIC compilation.
-      command="$command$suppress_output"
+      func_append command "$suppress_output"
       func_show_eval_locale "$command" \
         '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE'
 
@@ -1445,13 +2290,13 @@ compiler."
 }
 
 $opt_help || {
-test "$mode" = compile && func_mode_compile ${1+"$@"}
+  test "$opt_mode" = compile && func_mode_compile ${1+"$@"}
 }
 
 func_mode_help ()
 {
     # We need to display help for each of the modes.
-    case $mode in
+    case $opt_mode in
       "")
         # Generic help is extracted from the usage comments
         # at the start of this file.
@@ -1482,10 +2327,11 @@ This mode accepts the following additional options:
 
   -o OUTPUT-FILE    set the output file name to OUTPUT-FILE
   -no-suppress      do not suppress compiler output for multiple passes
-  -prefer-pic       try to building PIC objects only
-  -prefer-non-pic   try to building non-PIC objects only
+  -prefer-pic       try to build PIC objects only
+  -prefer-non-pic   try to build non-PIC objects only
   -shared           do not build a \`.o' file suitable for static linking
   -static           only build a \`.o' file suitable for static linking
+  -Wc,FLAG          pass FLAG directly to the compiler
 
 COMPILE-COMMAND is a command to be used in creating a \`standard' object file
 from the given SOURCEFILE.
@@ -1538,7 +2384,7 @@ either the \`install' or \`cp' program.
 
 The following components of INSTALL-COMMAND are treated specially:
 
-  -inst-prefix PREFIX-DIR  Use PREFIX-DIR as a staging area for installation
+  -inst-prefix-dir PREFIX-DIR  Use PREFIX-DIR as a staging area for installation
 
 The rest of the components are interpreted as arguments to that command (only
 BSD-compatible install options are recognized)."
@@ -1558,6 +2404,8 @@ The following components of LINK-COMMAND are treated specially:
 
   -all-static       do not do any dynamic linking at all
   -avoid-version    do not add a version suffix if possible
+  -bindir BINDIR    specify path to binaries directory (for systems where
+                    libraries must be found in the PATH setting at runtime)
   -dlopen FILE      \`-dlpreopen' FILE if it cannot be dlopened at runtime
   -dlpreopen FILE   link in FILE and add its symbols to lt_preloaded_symbols
   -export-dynamic   allow symbols from OUTPUT-FILE to be resolved with dlsym(3)
@@ -1586,6 +2434,11 @@ The following components of LINK-COMMAND are treated specially:
   -version-info CURRENT[:REVISION[:AGE]]
                     specify library version info [each variable defaults to 0]
   -weak LIBNAME     declare that the target provides the LIBNAME interface
+  -Wc,FLAG
+  -Xcompiler FLAG   pass linker-specific FLAG directly to the compiler
+  -Wl,FLAG
+  -Xlinker FLAG     pass linker-specific FLAG directly to the linker
+  -XCClinker FLAG   pass link-specific FLAG to the compiler driver (CC)
 
 All other options (arguments beginning with \`-') are ignored.
 
@@ -1619,18 +2472,44 @@ Otherwise, only FILE itself is deleted using RM."
         ;;
 
       *)
-        func_fatal_help "invalid operation mode \`$mode'"
+        func_fatal_help "invalid operation mode \`$opt_mode'"
         ;;
     esac
 
-    $ECHO
+    echo
     $ECHO "Try \`$progname --help' for more information about other modes."
-
-    exit $?
 }
 
-  # Now that we've collected a possible --mode arg, show help if necessary
-  $opt_help && func_mode_help
+# Now that we've collected a possible --mode arg, show help if necessary
+if $opt_help; then
+  if test "$opt_help" = :; then
+    func_mode_help
+  else
+    {
+      func_help noexit
+      for opt_mode in compile link execute install finish uninstall clean; do
+	func_mode_help
+      done
+    } | sed -n '1p; 2,$s/^Usage:/  or: /p'
+    {
+      func_help noexit
+      for opt_mode in compile link execute install finish uninstall clean; do
+	echo
+	func_mode_help
+      done
+    } |
+    sed '1d
+      /^When reporting/,/^Report/{
+	H
+	d
+      }
+      $x
+      /information about other modes/d
+      /more detailed .*MODE/d
+      s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/'
+  fi
+  exit $?
+fi
 
 
 # func_mode_execute arg...
@@ -1643,13 +2522,16 @@ func_mode_execute ()
       func_fatal_help "you must specify a COMMAND"
 
     # Handle -dlopen flags immediately.
-    for file in $execute_dlfiles; do
+    for file in $opt_dlopen; do
       test -f "$file" \
 	|| func_fatal_help "\`$file' is not a file"
 
       dir=
       case $file in
       *.la)
+	func_resolve_sysroot "$file"
+	file=$func_resolve_sysroot_result
+
 	# Check to see that this really is a libtool archive.
 	func_lalib_unsafe_p "$file" \
 	  || func_fatal_help "\`$lib' is not a valid libtool archive"
@@ -1671,7 +2553,7 @@ func_mode_execute ()
 	dir="$func_dirname_result"
 
 	if test -f "$dir/$objdir/$dlname"; then
-	  dir="$dir/$objdir"
+	  func_append dir "/$objdir"
 	else
 	  if test ! -f "$dir/$dlname"; then
 	    func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'"
@@ -1712,7 +2594,7 @@ func_mode_execute ()
     for file
     do
       case $file in
-      -*) ;;
+      -* | *.la | *.lo ) ;;
       *)
 	# Do a test to see if this is really a libtool program.
 	if func_ltwrapper_script_p "$file"; then
@@ -1728,8 +2610,7 @@ func_mode_execute ()
 	;;
       esac
       # Quote arguments (to preserve shell metacharacters).
-      func_quote_for_eval "$file"
-      args="$args $func_quote_for_eval_result"
+      func_append_quoted args "$file"
     done
 
     if test "X$opt_dry_run" = Xfalse; then
@@ -1754,29 +2635,66 @@ func_mode_execute ()
       # Display what would be done.
       if test -n "$shlibpath_var"; then
 	eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\""
-	$ECHO "export $shlibpath_var"
+	echo "export $shlibpath_var"
       fi
       $ECHO "$cmd$args"
       exit $EXIT_SUCCESS
     fi
 }
 
-test "$mode" = execute && func_mode_execute ${1+"$@"}
+test "$opt_mode" = execute && func_mode_execute ${1+"$@"}
+
+
+# func_mode_finish arg...
+func_mode_finish ()
+{
+    $opt_debug
+    libs=
+    libdirs=
+    admincmds=
+
+    for opt in "$nonopt" ${1+"$@"}
+    do
+      if test -d "$opt"; then
+	func_append libdirs " $opt"
+
+      elif test -f "$opt"; then
+	if func_lalib_unsafe_p "$opt"; then
+	  func_append libs " $opt"
+	else
+	  func_warning "\`$opt' is not a valid libtool archive"
+	fi
+
+      else
+	func_fatal_error "invalid argument \`$opt'"
+      fi
+    done
 
+    if test -n "$libs"; then
+      if test -n "$lt_sysroot"; then
+        sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"`
+        sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;"
+      else
+        sysroot_cmd=
+      fi
 
-# func_mode_finish arg...
-func_mode_finish ()
-{
-    $opt_debug
-    libdirs="$nonopt"
-    admincmds=
+      # Remove sysroot references
+      if $opt_dry_run; then
+        for lib in $libs; do
+          echo "removing references to $lt_sysroot and \`=' prefixes from $lib"
+        done
+      else
+        tmpdir=`func_mktempdir`
+        for lib in $libs; do
+	  sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \
+	    > $tmpdir/tmp-la
+	  mv -f $tmpdir/tmp-la $lib
+	done
+        ${RM}r "$tmpdir"
+      fi
+    fi
 
     if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
-      for dir
-      do
-	libdirs="$libdirs $dir"
-      done
-
       for libdir in $libdirs; do
 	if test -n "$finish_cmds"; then
 	  # Do each command in the finish commands.
@@ -1786,7 +2704,7 @@ func_mode_finish ()
 	if test -n "$finish_eval"; then
 	  # Do the single finish_eval.
 	  eval cmds=\"$finish_eval\"
-	  $opt_dry_run || eval "$cmds" || admincmds="$admincmds
+	  $opt_dry_run || eval "$cmds" || func_append admincmds "
        $cmds"
 	fi
       done
@@ -1795,53 +2713,55 @@ func_mode_finish ()
     # Exit here if they wanted silent mode.
     $opt_silent && exit $EXIT_SUCCESS
 
-    $ECHO "X----------------------------------------------------------------------" | $Xsed
-    $ECHO "Libraries have been installed in:"
-    for libdir in $libdirs; do
-      $ECHO "   $libdir"
-    done
-    $ECHO
-    $ECHO "If you ever happen to want to link against installed libraries"
-    $ECHO "in a given directory, LIBDIR, you must either use libtool, and"
-    $ECHO "specify the full pathname of the library, or use the \`-LLIBDIR'"
-    $ECHO "flag during linking and do at least one of the following:"
-    if test -n "$shlibpath_var"; then
-      $ECHO "   - add LIBDIR to the \`$shlibpath_var' environment variable"
-      $ECHO "     during execution"
-    fi
-    if test -n "$runpath_var"; then
-      $ECHO "   - add LIBDIR to the \`$runpath_var' environment variable"
-      $ECHO "     during linking"
-    fi
-    if test -n "$hardcode_libdir_flag_spec"; then
-      libdir=LIBDIR
-      eval flag=\"$hardcode_libdir_flag_spec\"
+    if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
+      echo "----------------------------------------------------------------------"
+      echo "Libraries have been installed in:"
+      for libdir in $libdirs; do
+	$ECHO "   $libdir"
+      done
+      echo
+      echo "If you ever happen to want to link against installed libraries"
+      echo "in a given directory, LIBDIR, you must either use libtool, and"
+      echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
+      echo "flag during linking and do at least one of the following:"
+      if test -n "$shlibpath_var"; then
+	echo "   - add LIBDIR to the \`$shlibpath_var' environment variable"
+	echo "     during execution"
+      fi
+      if test -n "$runpath_var"; then
+	echo "   - add LIBDIR to the \`$runpath_var' environment variable"
+	echo "     during linking"
+      fi
+      if test -n "$hardcode_libdir_flag_spec"; then
+	libdir=LIBDIR
+	eval flag=\"$hardcode_libdir_flag_spec\"
 
-      $ECHO "   - use the \`$flag' linker flag"
-    fi
-    if test -n "$admincmds"; then
-      $ECHO "   - have your system administrator run these commands:$admincmds"
-    fi
-    if test -f /etc/ld.so.conf; then
-      $ECHO "   - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
-    fi
-    $ECHO
+	$ECHO "   - use the \`$flag' linker flag"
+      fi
+      if test -n "$admincmds"; then
+	$ECHO "   - have your system administrator run these commands:$admincmds"
+      fi
+      if test -f /etc/ld.so.conf; then
+	echo "   - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
+      fi
+      echo
 
-    $ECHO "See any operating system documentation about shared libraries for"
-    case $host in
-      solaris2.[6789]|solaris2.1[0-9])
-        $ECHO "more information, such as the ld(1), crle(1) and ld.so(8) manual"
-	$ECHO "pages."
-	;;
-      *)
-        $ECHO "more information, such as the ld(1) and ld.so(8) manual pages."
-        ;;
-    esac
-    $ECHO "X----------------------------------------------------------------------" | $Xsed
+      echo "See any operating system documentation about shared libraries for"
+      case $host in
+	solaris2.[6789]|solaris2.1[0-9])
+	  echo "more information, such as the ld(1), crle(1) and ld.so(8) manual"
+	  echo "pages."
+	  ;;
+	*)
+	  echo "more information, such as the ld(1) and ld.so(8) manual pages."
+	  ;;
+      esac
+      echo "----------------------------------------------------------------------"
+    fi
     exit $EXIT_SUCCESS
 }
 
-test "$mode" = finish && func_mode_finish ${1+"$@"}
+test "$opt_mode" = finish && func_mode_finish ${1+"$@"}
 
 
 # func_mode_install arg...
@@ -1852,7 +2772,7 @@ func_mode_install ()
     # install_prog (especially on Windows NT).
     if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh ||
        # Allow the use of GNU shtool's install command.
-       $ECHO "X$nonopt" | $GREP shtool >/dev/null; then
+       case $nonopt in *shtool*) :;; *) false;; esac; then
       # Aesthetically quote it.
       func_quote_for_eval "$nonopt"
       install_prog="$func_quote_for_eval_result "
@@ -1866,7 +2786,12 @@ func_mode_install ()
     # The real first argument should be the name of the installation program.
     # Aesthetically quote it.
     func_quote_for_eval "$arg"
-    install_prog="$install_prog$func_quote_for_eval_result"
+    func_append install_prog "$func_quote_for_eval_result"
+    install_shared_prog=$install_prog
+    case " $install_prog " in
+      *[\\\ /]cp\ *) install_cp=: ;;
+      *) install_cp=false ;;
+    esac
 
     # We need to accept at least all the BSD install flags.
     dest=
@@ -1876,10 +2801,12 @@ func_mode_install ()
     install_type=
     isdir=no
     stripme=
+    no_mode=:
     for arg
     do
+      arg2=
       if test -n "$dest"; then
-	files="$files $dest"
+	func_append files " $dest"
 	dest=$arg
 	continue
       fi
@@ -1887,10 +2814,9 @@ func_mode_install ()
       case $arg in
       -d) isdir=yes ;;
       -f)
-	case " $install_prog " in
-	*[\\\ /]cp\ *) ;;
-	*) prev=$arg ;;
-	esac
+	if $install_cp; then :; else
+	  prev=$arg
+	fi
 	;;
       -g | -m | -o)
 	prev=$arg
@@ -1904,6 +2830,10 @@ func_mode_install ()
       *)
 	# If the previous option needed an argument, then skip it.
 	if test -n "$prev"; then
+	  if test "x$prev" = x-m && test -n "$install_override_mode"; then
+	    arg2=$install_override_mode
+	    no_mode=false
+	  fi
 	  prev=
 	else
 	  dest=$arg
@@ -1914,7 +2844,11 @@ func_mode_install ()
 
       # Aesthetically quote the argument.
       func_quote_for_eval "$arg"
-      install_prog="$install_prog $func_quote_for_eval_result"
+      func_append install_prog " $func_quote_for_eval_result"
+      if test -n "$arg2"; then
+	func_quote_for_eval "$arg2"
+      fi
+      func_append install_shared_prog " $func_quote_for_eval_result"
     done
 
     test -z "$install_prog" && \
@@ -1923,6 +2857,13 @@ func_mode_install ()
     test -n "$prev" && \
       func_fatal_help "the \`$prev' option requires an argument"
 
+    if test -n "$install_override_mode" && $no_mode; then
+      if $install_cp; then :; else
+	func_quote_for_eval "$install_override_mode"
+	func_append install_shared_prog " -m $func_quote_for_eval_result"
+      fi
+    fi
+
     if test -z "$files"; then
       if test -z "$dest"; then
 	func_fatal_help "no file or destination specified"
@@ -1977,10 +2918,13 @@ func_mode_install ()
       case $file in
       *.$libext)
 	# Do the static libraries later.
-	staticlibs="$staticlibs $file"
+	func_append staticlibs " $file"
 	;;
 
       *.la)
+	func_resolve_sysroot "$file"
+	file=$func_resolve_sysroot_result
+
 	# Check to see that this really is a libtool archive.
 	func_lalib_unsafe_p "$file" \
 	  || func_fatal_help "\`$file' is not a valid libtool archive"
@@ -1994,23 +2938,23 @@ func_mode_install ()
 	if test "X$destdir" = "X$libdir"; then
 	  case "$current_libdirs " in
 	  *" $libdir "*) ;;
-	  *) current_libdirs="$current_libdirs $libdir" ;;
+	  *) func_append current_libdirs " $libdir" ;;
 	  esac
 	else
 	  # Note the libdir as a future libdir.
 	  case "$future_libdirs " in
 	  *" $libdir "*) ;;
-	  *) future_libdirs="$future_libdirs $libdir" ;;
+	  *) func_append future_libdirs " $libdir" ;;
 	  esac
 	fi
 
 	func_dirname "$file" "/" ""
 	dir="$func_dirname_result"
-	dir="$dir$objdir"
+	func_append dir "$objdir"
 
 	if test -n "$relink_command"; then
 	  # Determine the prefix the user has applied to our future dir.
-	  inst_prefix_dir=`$ECHO "X$destdir" | $Xsed -e "s%$libdir\$%%"`
+	  inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"`
 
 	  # Don't allow the user to place us outside of our expected
 	  # location b/c this prevents finding dependent libraries that
@@ -2023,9 +2967,9 @@ func_mode_install ()
 
 	  if test -n "$inst_prefix_dir"; then
 	    # Stick the inst_prefix_dir data into the link command.
-	    relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"`
+	    relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"`
 	  else
-	    relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%%"`
+	    relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"`
 	  fi
 
 	  func_warning "relinking \`$file'"
@@ -2043,7 +2987,7 @@ func_mode_install ()
 	  test -n "$relink_command" && srcname="$realname"T
 
 	  # Install the shared library and build the symlinks.
-	  func_show_eval "$install_prog $dir/$srcname $destdir/$realname" \
+	  func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
 	      'exit $?'
 	  tstripme="$stripme"
 	  case $host_os in
@@ -2083,7 +3027,7 @@ func_mode_install ()
 	func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
 
 	# Maybe install the static library, too.
-	test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library"
+	test -n "$old_library" && func_append staticlibs " $dir/$old_library"
 	;;
 
       *.lo)
@@ -2183,7 +3127,7 @@ func_mode_install ()
 	    if test -f "$lib"; then
 	      func_source "$lib"
 	    fi
-	    libfile="$libdir/"`$ECHO "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test
+	    libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test
 	    if test -n "$libdir" && test ! -f "$libfile"; then
 	      func_warning "\`$lib' has not been installed in \`$libdir'"
 	      finalize=no
@@ -2202,7 +3146,7 @@ func_mode_install ()
 		file="$func_basename_result"
 	        outputname="$tmpdir/$file"
 	        # Replace the output file specification.
-	        relink_command=`$ECHO "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'`
+	        relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'`
 
 	        $opt_silent || {
 	          func_quote_for_expand "$relink_command"
@@ -2221,7 +3165,7 @@ func_mode_install ()
 	    }
 	  else
 	    # Install the binary that we compiled earlier.
-	    file=`$ECHO "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"`
+	    file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"`
 	  fi
 	fi
 
@@ -2280,7 +3224,7 @@ func_mode_install ()
     fi
 }
 
-test "$mode" = install && func_mode_install ${1+"$@"}
+test "$opt_mode" = install && func_mode_install ${1+"$@"}
 
 
 # func_generate_dlsyms outputname originator pic_p
@@ -2323,6 +3267,22 @@ func_generate_dlsyms ()
 extern \"C\" {
 #endif
 
+#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4))
+#pragma GCC diagnostic ignored \"-Wstrict-prototypes\"
+#endif
+
+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
+/* DATA imports from DLLs on WIN32 con't be const, because runtime
+   relocations are performed -- see ld's documentation on pseudo-relocs.  */
+# define LT_DLSYM_CONST
+#elif defined(__osf__)
+/* This system does not cope well with relocations in const data.  */
+# define LT_DLSYM_CONST
+#else
+# define LT_DLSYM_CONST const
+#endif
+
 /* External symbol declarations for the compiler. */\
 "
 
@@ -2332,10 +3292,11 @@ extern \"C\" {
 	  $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist"
 
 	  # Add our own program objects to the symbol list.
-	  progfiles=`$ECHO "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
+	  progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP`
 	  for progfile in $progfiles; do
-	    func_verbose "extracting global C symbols from \`$progfile'"
-	    $opt_dry_run || eval "$NM $progfile | $global_symbol_pipe >> '$nlist'"
+	    func_to_tool_file "$progfile" func_convert_file_msys_to_w32
+	    func_verbose "extracting global C symbols from \`$func_to_tool_file_result'"
+	    $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'"
 	  done
 
 	  if test -n "$exclude_expsyms"; then
@@ -2371,7 +3332,7 @@ extern \"C\" {
 	      eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
 	      eval '$MV "$nlist"T "$nlist"'
 	      case $host in
-	        *cygwin | *mingw* | *cegcc* )
+	        *cygwin* | *mingw* | *cegcc* )
 	          eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
 	          eval 'cat "$nlist" >> "$output_objdir/$outputname.def"'
 	          ;;
@@ -2384,10 +3345,52 @@ extern \"C\" {
 	  func_verbose "extracting global C symbols from \`$dlprefile'"
 	  func_basename "$dlprefile"
 	  name="$func_basename_result"
-	  $opt_dry_run || {
-	    eval '$ECHO ": $name " >> "$nlist"'
-	    eval "$NM $dlprefile 2>/dev/null | $global_symbol_pipe >> '$nlist'"
-	  }
+          case $host in
+	    *cygwin* | *mingw* | *cegcc* )
+	      # if an import library, we need to obtain dlname
+	      if func_win32_import_lib_p "$dlprefile"; then
+	        func_tr_sh "$dlprefile"
+	        eval "curr_lafile=\$libfile_$func_tr_sh_result"
+	        dlprefile_dlbasename=""
+	        if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then
+	          # Use subshell, to avoid clobbering current variable values
+	          dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"`
+	          if test -n "$dlprefile_dlname" ; then
+	            func_basename "$dlprefile_dlname"
+	            dlprefile_dlbasename="$func_basename_result"
+	          else
+	            # no lafile. user explicitly requested -dlpreopen <import library>.
+	            $sharedlib_from_linklib_cmd "$dlprefile"
+	            dlprefile_dlbasename=$sharedlib_from_linklib_result
+	          fi
+	        fi
+	        $opt_dry_run || {
+	          if test -n "$dlprefile_dlbasename" ; then
+	            eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"'
+	          else
+	            func_warning "Could not compute DLL name from $name"
+	            eval '$ECHO ": $name " >> "$nlist"'
+	          fi
+	          func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
+	          eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe |
+	            $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'"
+	        }
+	      else # not an import lib
+	        $opt_dry_run || {
+	          eval '$ECHO ": $name " >> "$nlist"'
+	          func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
+	          eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
+	        }
+	      fi
+	    ;;
+	    *)
+	      $opt_dry_run || {
+	        eval '$ECHO ": $name " >> "$nlist"'
+	        func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
+	        eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
+	      }
+	    ;;
+          esac
 	done
 
 	$opt_dry_run || {
@@ -2415,36 +3418,19 @@ extern \"C\" {
 	  if test -f "$nlist"S; then
 	    eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"'
 	  else
-	    $ECHO '/* NONE */' >> "$output_objdir/$my_dlsyms"
+	    echo '/* NONE */' >> "$output_objdir/$my_dlsyms"
 	  fi
 
-	  $ECHO >> "$output_objdir/$my_dlsyms" "\
+	  echo >> "$output_objdir/$my_dlsyms" "\
 
 /* The mapping between symbol names and symbols.  */
 typedef struct {
   const char *name;
   void *address;
 } lt_dlsymlist;
-"
-	  case $host in
-	  *cygwin* | *mingw* | *cegcc* )
-	    $ECHO >> "$output_objdir/$my_dlsyms" "\
-/* DATA imports from DLLs on WIN32 con't be const, because
-   runtime relocations are performed -- see ld's documentation
-   on pseudo-relocs.  */"
-	    lt_dlsym_const= ;;
-	  *osf5*)
-	    echo >> "$output_objdir/$my_dlsyms" "\
-/* This system does not cope well with relocations in const data */"
-	    lt_dlsym_const= ;;
-	  *)
-	    lt_dlsym_const=const ;;
-	  esac
-
-	  $ECHO >> "$output_objdir/$my_dlsyms" "\
-extern $lt_dlsym_const lt_dlsymlist
+extern LT_DLSYM_CONST lt_dlsymlist
 lt_${my_prefix}_LTX_preloaded_symbols[];
-$lt_dlsym_const lt_dlsymlist
+LT_DLSYM_CONST lt_dlsymlist
 lt_${my_prefix}_LTX_preloaded_symbols[] =
 {\
   { \"$my_originator\", (void *) 0 },"
@@ -2457,7 +3443,7 @@ lt_${my_prefix}_LTX_preloaded_symbols[] =
 	    eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms"
 	    ;;
 	  esac
-	  $ECHO >> "$output_objdir/$my_dlsyms" "\
+	  echo >> "$output_objdir/$my_dlsyms" "\
   {0, (void *) 0}
 };
 
@@ -2500,7 +3486,7 @@ static const void *lt_preloaded_setup() {
 	for arg in $LTCFLAGS; do
 	  case $arg in
 	  -pie | -fpie | -fPIE) ;;
-	  *) symtab_cflags="$symtab_cflags $arg" ;;
+	  *) func_append symtab_cflags " $arg" ;;
 	  esac
 	done
 
@@ -2515,16 +3501,16 @@ static const void *lt_preloaded_setup() {
 	case $host in
 	*cygwin* | *mingw* | *cegcc* )
 	  if test -f "$output_objdir/$my_outputname.def"; then
-	    compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
-	    finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
+	    compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
+	    finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
 	  else
-	    compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
-	    finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
+	    compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"`
+	    finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"`
 	  fi
 	  ;;
 	*)
-	  compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
-	  finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
+	  compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"`
+	  finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"`
 	  ;;
 	esac
 	;;
@@ -2538,8 +3524,8 @@ static const void *lt_preloaded_setup() {
       # really was required.
 
       # Nullify the symbol file.
-      compile_command=`$ECHO "X$compile_command" | $Xsed -e "s% @SYMFILE@%%"`
-      finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s% @SYMFILE@%%"`
+      compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"`
+      finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"`
     fi
 }
 
@@ -2549,6 +3535,7 @@ static const void *lt_preloaded_setup() {
 # Need a lot of goo to handle *both* DLLs and import libs
 # Has to be a shell function in order to 'eat' the argument
 # that is supplied when $file_magic_command is called.
+# Despite the name, also deal with 64 bit binaries.
 func_win32_libid ()
 {
   $opt_debug
@@ -2559,9 +3546,11 @@ func_win32_libid ()
     win32_libid_type="x86 archive import"
     ;;
   *ar\ archive*) # could be an import, or static
+    # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD.
     if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
-       $EGREP 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then
-      win32_nmres=`eval $NM -f posix -A $1 |
+       $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then
+      func_to_tool_file "$1" func_convert_file_msys_to_w32
+      win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" |
 	$SED -n -e '
 	    1,100{
 		/ I /{
@@ -2590,6 +3579,131 @@ func_win32_libid ()
   $ECHO "$win32_libid_type"
 }
 
+# func_cygming_dll_for_implib ARG
+#
+# Platform-specific function to extract the
+# name of the DLL associated with the specified
+# import library ARG.
+# Invoked by eval'ing the libtool variable
+#    $sharedlib_from_linklib_cmd
+# Result is available in the variable
+#    $sharedlib_from_linklib_result
+func_cygming_dll_for_implib ()
+{
+  $opt_debug
+  sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"`
+}
+
+# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs
+#
+# The is the core of a fallback implementation of a
+# platform-specific function to extract the name of the
+# DLL associated with the specified import library LIBNAME.
+#
+# SECTION_NAME is either .idata$6 or .idata$7, depending
+# on the platform and compiler that created the implib.
+#
+# Echos the name of the DLL associated with the
+# specified import library.
+func_cygming_dll_for_implib_fallback_core ()
+{
+  $opt_debug
+  match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"`
+  $OBJDUMP -s --section "$1" "$2" 2>/dev/null |
+    $SED '/^Contents of section '"$match_literal"':/{
+      # Place marker at beginning of archive member dllname section
+      s/.*/====MARK====/
+      p
+      d
+    }
+    # These lines can sometimes be longer than 43 characters, but
+    # are always uninteresting
+    /:[	 ]*file format pe[i]\{,1\}-/d
+    /^In archive [^:]*:/d
+    # Ensure marker is printed
+    /^====MARK====/p
+    # Remove all lines with less than 43 characters
+    /^.\{43\}/!d
+    # From remaining lines, remove first 43 characters
+    s/^.\{43\}//' |
+    $SED -n '
+      # Join marker and all lines until next marker into a single line
+      /^====MARK====/ b para
+      H
+      $ b para
+      b
+      :para
+      x
+      s/\n//g
+      # Remove the marker
+      s/^====MARK====//
+      # Remove trailing dots and whitespace
+      s/[\. \t]*$//
+      # Print
+      /./p' |
+    # we now have a list, one entry per line, of the stringified
+    # contents of the appropriate section of all members of the
+    # archive which possess that section. Heuristic: eliminate
+    # all those which have a first or second character that is
+    # a '.' (that is, objdump's representation of an unprintable
+    # character.) This should work for all archives with less than
+    # 0x302f exports -- but will fail for DLLs whose name actually
+    # begins with a literal '.' or a single character followed by
+    # a '.'.
+    #
+    # Of those that remain, print the first one.
+    $SED -e '/^\./d;/^.\./d;q'
+}
+
+# func_cygming_gnu_implib_p ARG
+# This predicate returns with zero status (TRUE) if
+# ARG is a GNU/binutils-style import library. Returns
+# with nonzero status (FALSE) otherwise.
+func_cygming_gnu_implib_p ()
+{
+  $opt_debug
+  func_to_tool_file "$1" func_convert_file_msys_to_w32
+  func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'`
+  test -n "$func_cygming_gnu_implib_tmp"
+}
+
+# func_cygming_ms_implib_p ARG
+# This predicate returns with zero status (TRUE) if
+# ARG is an MS-style import library. Returns
+# with nonzero status (FALSE) otherwise.
+func_cygming_ms_implib_p ()
+{
+  $opt_debug
+  func_to_tool_file "$1" func_convert_file_msys_to_w32
+  func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'`
+  test -n "$func_cygming_ms_implib_tmp"
+}
+
+# func_cygming_dll_for_implib_fallback ARG
+# Platform-specific function to extract the
+# name of the DLL associated with the specified
+# import library ARG.
+#
+# This fallback implementation is for use when $DLLTOOL
+# does not support the --identify-strict option.
+# Invoked by eval'ing the libtool variable
+#    $sharedlib_from_linklib_cmd
+# Result is available in the variable
+#    $sharedlib_from_linklib_result
+func_cygming_dll_for_implib_fallback ()
+{
+  $opt_debug
+  if func_cygming_gnu_implib_p "$1" ; then
+    # binutils import library
+    sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"`
+  elif func_cygming_ms_implib_p "$1" ; then
+    # ms-generated import library
+    sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"`
+  else
+    # unknown
+    sharedlib_from_linklib_result=""
+  fi
+}
 
 
 # func_extract_an_archive dir oldlib
@@ -2598,7 +3712,18 @@ func_extract_an_archive ()
     $opt_debug
     f_ex_an_ar_dir="$1"; shift
     f_ex_an_ar_oldlib="$1"
-    func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" 'exit $?'
+    if test "$lock_old_archive_extraction" = yes; then
+      lockfile=$f_ex_an_ar_oldlib.lock
+      until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
+	func_echo "Waiting for $lockfile to be removed"
+	sleep 2
+      done
+    fi
+    func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \
+		   'stat=$?; rm -f "$lockfile"; exit $stat'
+    if test "$lock_old_archive_extraction" = yes; then
+      $opt_dry_run || rm -f "$lockfile"
+    fi
     if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then
      :
     else
@@ -2669,7 +3794,7 @@ func_extract_archives ()
 	    darwin_file=
 	    darwin_files=
 	    for darwin_file in $darwin_filelist; do
-	      darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP`
+	      darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP`
 	      $LIPO -create -output "$darwin_file" $darwin_files
 	    done # $darwin_filelist
 	    $RM -rf unfat-$$
@@ -2684,25 +3809,30 @@ func_extract_archives ()
         func_extract_an_archive "$my_xdir" "$my_xabs"
 	;;
       esac
-      my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP`
+      my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP`
     done
 
     func_extract_archives_result="$my_oldobjs"
 }
 
 
-
-# func_emit_wrapper_part1 [arg=no]
+# func_emit_wrapper [arg=no]
+#
+# Emit a libtool wrapper script on stdout.
+# Don't directly open a file because we may want to
+# incorporate the script contents within a cygwin/mingw
+# wrapper executable.  Must ONLY be called from within
+# func_mode_link because it depends on a number of variables
+# set therein.
 #
-# Emit the first part of a libtool wrapper script on stdout.
-# For more information, see the description associated with
-# func_emit_wrapper(), below.
-func_emit_wrapper_part1 ()
+# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR
+# variable will take.  If 'yes', then the emitted script
+# will assume that the directory in which it is stored is
+# the $objdir directory.  This is a cygwin/mingw-specific
+# behavior.
+func_emit_wrapper ()
 {
-	func_emit_wrapper_part1_arg1=no
-	if test -n "$1" ; then
-	  func_emit_wrapper_part1_arg1=$1
-	fi
+	func_emit_wrapper_arg1=${1-no}
 
 	$ECHO "\
 #! $SHELL
@@ -2718,7 +3848,6 @@ func_emit_wrapper_part1 ()
 
 # Sed substitution that helps us do robust quoting.  It backslashifies
 # metacharacters that are still active within double-quoted strings.
-Xsed='${SED} -e 1s/^X//'
 sed_quote_subst='$sed_quote_subst'
 
 # Be Bourne compatible
@@ -2749,31 +3878,132 @@ if test \"\$libtool_install_magic\" = \"$magic\"; then
 else
   # When we are sourced in execute mode, \$file and \$ECHO are already set.
   if test \"\$libtool_execute_magic\" != \"$magic\"; then
-    ECHO=\"$qecho\"
-    file=\"\$0\"
-    # Make sure echo works.
-    if test \"X\$1\" = X--no-reexec; then
-      # Discard the --no-reexec flag, and continue.
-      shift
-    elif test \"X\`{ \$ECHO '\t'; } 2>/dev/null\`\" = 'X\t'; then
-      # Yippee, \$ECHO works!
-      :
-    else
-      # Restart under the correct shell, and then maybe \$ECHO will work.
-      exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"}
-    fi
-  fi\
+    file=\"\$0\""
+
+    qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"`
+    $ECHO "\
+
+# A function that is used when there is no print builtin or printf.
+func_fallback_echo ()
+{
+  eval 'cat <<_LTECHO_EOF
+\$1
+_LTECHO_EOF'
+}
+    ECHO=\"$qECHO\"
+  fi
+
+# Very basic option parsing. These options are (a) specific to
+# the libtool wrapper, (b) are identical between the wrapper
+# /script/ and the wrapper /executable/ which is used only on
+# windows platforms, and (c) all begin with the string "--lt-"
+# (application programs are unlikely to have options which match
+# this pattern).
+#
+# There are only two supported options: --lt-debug and
+# --lt-dump-script. There is, deliberately, no --lt-help.
+#
+# The first argument to this parsing function should be the
+# script's $0 value, followed by "$@".
+lt_option_debug=
+func_parse_lt_options ()
+{
+  lt_script_arg0=\$0
+  shift
+  for lt_opt
+  do
+    case \"\$lt_opt\" in
+    --lt-debug) lt_option_debug=1 ;;
+    --lt-dump-script)
+        lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\`
+        test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=.
+        lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\`
+        cat \"\$lt_dump_D/\$lt_dump_F\"
+        exit 0
+      ;;
+    --lt-*)
+        \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2
+        exit 1
+      ;;
+    esac
+  done
+
+  # Print the debug banner immediately:
+  if test -n \"\$lt_option_debug\"; then
+    echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2
+  fi
+}
+
+# Used when --lt-debug. Prints its arguments to stdout
+# (redirection is the responsibility of the caller)
+func_lt_dump_args ()
+{
+  lt_dump_args_N=1;
+  for lt_arg
+  do
+    \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\"
+    lt_dump_args_N=\`expr \$lt_dump_args_N + 1\`
+  done
+}
+
+# Core function for launching the target application
+func_exec_program_core ()
+{
 "
-	$ECHO "\
+  case $host in
+  # Backslashes separate directories on plain windows
+  *-*-mingw | *-*-os2* | *-cegcc*)
+    $ECHO "\
+      if test -n \"\$lt_option_debug\"; then
+        \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2
+        func_lt_dump_args \${1+\"\$@\"} 1>&2
+      fi
+      exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
+"
+    ;;
+
+  *)
+    $ECHO "\
+      if test -n \"\$lt_option_debug\"; then
+        \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2
+        func_lt_dump_args \${1+\"\$@\"} 1>&2
+      fi
+      exec \"\$progdir/\$program\" \${1+\"\$@\"}
+"
+    ;;
+  esac
+  $ECHO "\
+      \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
+      exit 1
+}
+
+# A function to encapsulate launching the target application
+# Strips options in the --lt-* namespace from \$@ and
+# launches target application with the remaining arguments.
+func_exec_program ()
+{
+  for lt_wr_arg
+  do
+    case \$lt_wr_arg in
+    --lt-*) ;;
+    *) set x \"\$@\" \"\$lt_wr_arg\"; shift;;
+    esac
+    shift
+  done
+  func_exec_program_core \${1+\"\$@\"}
+}
+
+  # Parse options
+  func_parse_lt_options \"\$0\" \${1+\"\$@\"}
 
   # Find the directory that this script lives in.
-  thisdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\`
+  thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\`
   test \"x\$thisdir\" = \"x\$file\" && thisdir=.
 
   # Follow symbolic links until we get to the real thisdir.
-  file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\`
+  file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\`
   while test -n \"\$file\"; do
-    destdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\`
+    destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\`
 
     # If there was a directory component, then change thisdir.
     if test \"x\$destdir\" != \"x\$file\"; then
@@ -2783,30 +4013,13 @@ else
       esac
     fi
 
-    file=\`\$ECHO \"X\$file\" | \$Xsed -e 's%^.*/%%'\`
-    file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\`
+    file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\`
+    file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\`
   done
-"
-}
-# end: func_emit_wrapper_part1
-
-# func_emit_wrapper_part2 [arg=no]
-#
-# Emit the second part of a libtool wrapper script on stdout.
-# For more information, see the description associated with
-# func_emit_wrapper(), below.
-func_emit_wrapper_part2 ()
-{
-	func_emit_wrapper_part2_arg1=no
-	if test -n "$1" ; then
-	  func_emit_wrapper_part2_arg1=$1
-	fi
-
-	$ECHO "\
 
   # Usually 'no', except on cygwin/mingw when embedded into
   # the cwrapper.
-  WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_part2_arg1
+  WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1
   if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then
     # special case for '.'
     if test \"\$thisdir\" = \".\"; then
@@ -2814,7 +4027,7 @@ func_emit_wrapper_part2 ()
     fi
     # remove .libs from thisdir
     case \"\$thisdir\" in
-    *[\\\\/]$objdir ) thisdir=\`\$ECHO \"X\$thisdir\" | \$Xsed -e 's%[\\\\/][^\\\\/]*$%%'\` ;;
+    *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;;
     $objdir )   thisdir=. ;;
     esac
   fi
@@ -2869,6 +4082,18 @@ func_emit_wrapper_part2 ()
 
   if test -f \"\$progdir/\$program\"; then"
 
+	# fixup the dll searchpath if we need to.
+	#
+	# Fix the DLL searchpath if we need to.  Do this before prepending
+	# to shlibpath, because on Windows, both are PATH and uninstalled
+	# libraries must come first.
+	if test -n "$dllsearchpath"; then
+	  $ECHO "\
+    # Add the dll search path components to the executable PATH
+    PATH=$dllsearchpath:\$PATH
+"
+	fi
+
 	# Export our shlibpath_var if we have one.
 	if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
 	  $ECHO "\
@@ -2877,253 +4102,28 @@ func_emit_wrapper_part2 ()
 
     # Some systems cannot cope with colon-terminated $shlibpath_var
     # The second colon is a workaround for a bug in BeOS R4 sed
-    $shlibpath_var=\`\$ECHO \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\`
+    $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\`
 
     export $shlibpath_var
 "
 	fi
 
-	# fixup the dll searchpath if we need to.
-	if test -n "$dllsearchpath"; then
-	  $ECHO "\
-    # Add the dll search path components to the executable PATH
-    PATH=$dllsearchpath:\$PATH
-"
-	fi
-
 	$ECHO "\
     if test \"\$libtool_execute_magic\" != \"$magic\"; then
       # Run the actual program with our arguments.
-"
-	case $host in
-	# Backslashes separate directories on plain windows
-	*-*-mingw | *-*-os2* | *-cegcc*)
-	  $ECHO "\
-      exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
-"
-	  ;;
-
-	*)
-	  $ECHO "\
-      exec \"\$progdir/\$program\" \${1+\"\$@\"}
-"
-	  ;;
-	esac
-	$ECHO "\
-      \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
-      exit 1
+      func_exec_program \${1+\"\$@\"}
     fi
   else
     # The program doesn't exist.
     \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2
     \$ECHO \"This script is just a wrapper for \$program.\" 1>&2
-    $ECHO \"See the $PACKAGE documentation for more information.\" 1>&2
+    \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2
     exit 1
   fi
 fi\
 "
 }
-# end: func_emit_wrapper_part2
-
-
-# func_emit_wrapper [arg=no]
-#
-# Emit a libtool wrapper script on stdout.
-# Don't directly open a file because we may want to
-# incorporate the script contents within a cygwin/mingw
-# wrapper executable.  Must ONLY be called from within
-# func_mode_link because it depends on a number of variables
-# set therein.
-#
-# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR
-# variable will take.  If 'yes', then the emitted script
-# will assume that the directory in which it is stored is
-# the $objdir directory.  This is a cygwin/mingw-specific
-# behavior.
-func_emit_wrapper ()
-{
-	func_emit_wrapper_arg1=no
-	if test -n "$1" ; then
-	  func_emit_wrapper_arg1=$1
-	fi
-
-	# split this up so that func_emit_cwrapperexe_src
-	# can call each part independently.
-	func_emit_wrapper_part1 "${func_emit_wrapper_arg1}"
-	func_emit_wrapper_part2 "${func_emit_wrapper_arg1}"
-}
-
-
-# func_to_host_path arg
-#
-# Convert paths to host format when used with build tools.
-# Intended for use with "native" mingw (where libtool itself
-# is running under the msys shell), or in the following cross-
-# build environments:
-#    $build          $host
-#    mingw (msys)    mingw  [e.g. native]
-#    cygwin          mingw
-#    *nix + wine     mingw
-# where wine is equipped with the `winepath' executable.
-# In the native mingw case, the (msys) shell automatically
-# converts paths for any non-msys applications it launches,
-# but that facility isn't available from inside the cwrapper.
-# Similar accommodations are necessary for $host mingw and
-# $build cygwin.  Calling this function does no harm for other
-# $host/$build combinations not listed above.
-#
-# ARG is the path (on $build) that should be converted to
-# the proper representation for $host. The result is stored
-# in $func_to_host_path_result.
-func_to_host_path ()
-{
-  func_to_host_path_result="$1"
-  if test -n "$1" ; then
-    case $host in
-      *mingw* )
-        lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
-        case $build in
-          *mingw* ) # actually, msys
-            # awkward: cmd appends spaces to result
-            lt_sed_strip_trailing_spaces="s/[ ]*\$//"
-            func_to_host_path_tmp1=`( cmd //c echo "$1" |\
-              $SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""`
-            func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
-              $SED -e "$lt_sed_naive_backslashify"`
-            ;;
-          *cygwin* )
-            func_to_host_path_tmp1=`cygpath -w "$1"`
-            func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
-              $SED -e "$lt_sed_naive_backslashify"`
-            ;;
-          * )
-            # Unfortunately, winepath does not exit with a non-zero
-            # error code, so we are forced to check the contents of
-            # stdout. On the other hand, if the command is not
-            # found, the shell will set an exit code of 127 and print
-            # *an error message* to stdout. So we must check for both
-            # error code of zero AND non-empty stdout, which explains
-            # the odd construction:
-            func_to_host_path_tmp1=`winepath -w "$1" 2>/dev/null`
-            if test "$?" -eq 0 && test -n "${func_to_host_path_tmp1}"; then
-              func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
-                $SED -e "$lt_sed_naive_backslashify"`
-            else
-              # Allow warning below.
-              func_to_host_path_result=""
-            fi
-            ;;
-        esac
-        if test -z "$func_to_host_path_result" ; then
-          func_error "Could not determine host path corresponding to"
-          func_error "  '$1'"
-          func_error "Continuing, but uninstalled executables may not work."
-          # Fallback:
-          func_to_host_path_result="$1"
-        fi
-        ;;
-    esac
-  fi
-}
-# end: func_to_host_path
 
-# func_to_host_pathlist arg
-#
-# Convert pathlists to host format when used with build tools.
-# See func_to_host_path(), above. This function supports the
-# following $build/$host combinations (but does no harm for
-# combinations not listed here):
-#    $build          $host
-#    mingw (msys)    mingw  [e.g. native]
-#    cygwin          mingw
-#    *nix + wine     mingw
-#
-# Path separators are also converted from $build format to
-# $host format. If ARG begins or ends with a path separator
-# character, it is preserved (but converted to $host format)
-# on output.
-#
-# ARG is a pathlist (on $build) that should be converted to
-# the proper representation on $host. The result is stored
-# in $func_to_host_pathlist_result.
-func_to_host_pathlist ()
-{
-  func_to_host_pathlist_result="$1"
-  if test -n "$1" ; then
-    case $host in
-      *mingw* )
-        lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
-        # Remove leading and trailing path separator characters from
-        # ARG. msys behavior is inconsistent here, cygpath turns them
-        # into '.;' and ';.', and winepath ignores them completely.
-        func_to_host_pathlist_tmp2="$1"
-        # Once set for this call, this variable should not be
-        # reassigned. It is used in tha fallback case.
-        func_to_host_pathlist_tmp1=`echo "$func_to_host_pathlist_tmp2" |\
-          $SED -e 's|^:*||' -e 's|:*$||'`
-        case $build in
-          *mingw* ) # Actually, msys.
-            # Awkward: cmd appends spaces to result.
-            lt_sed_strip_trailing_spaces="s/[ ]*\$//"
-            func_to_host_pathlist_tmp2=`( cmd //c echo "$func_to_host_pathlist_tmp1" |\
-              $SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""`
-            func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\
-              $SED -e "$lt_sed_naive_backslashify"`
-            ;;
-          *cygwin* )
-            func_to_host_pathlist_tmp2=`cygpath -w -p "$func_to_host_pathlist_tmp1"`
-            func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\
-              $SED -e "$lt_sed_naive_backslashify"`
-            ;;
-          * )
-            # unfortunately, winepath doesn't convert pathlists
-            func_to_host_pathlist_result=""
-            func_to_host_pathlist_oldIFS=$IFS
-            IFS=:
-            for func_to_host_pathlist_f in $func_to_host_pathlist_tmp1 ; do
-              IFS=$func_to_host_pathlist_oldIFS
-              if test -n "$func_to_host_pathlist_f" ; then
-                func_to_host_path "$func_to_host_pathlist_f"
-                if test -n "$func_to_host_path_result" ; then
-                  if test -z "$func_to_host_pathlist_result" ; then
-                    func_to_host_pathlist_result="$func_to_host_path_result"
-                  else
-                    func_to_host_pathlist_result="$func_to_host_pathlist_result;$func_to_host_path_result"
-                  fi
-                fi
-              fi
-              IFS=:
-            done
-            IFS=$func_to_host_pathlist_oldIFS
-            ;;
-        esac
-        if test -z "$func_to_host_pathlist_result" ; then
-          func_error "Could not determine the host path(s) corresponding to"
-          func_error "  '$1'"
-          func_error "Continuing, but uninstalled executables may not work."
-          # Fallback. This may break if $1 contains DOS-style drive
-          # specifications. The fix is not to complicate the expression
-          # below, but for the user to provide a working wine installation
-          # with winepath so that path translation in the cross-to-mingw
-          # case works properly.
-          lt_replace_pathsep_nix_to_dos="s|:|;|g"
-          func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp1" |\
-            $SED -e "$lt_replace_pathsep_nix_to_dos"`
-        fi
-        # Now, add the leading and trailing path separators back
-        case "$1" in
-          :* ) func_to_host_pathlist_result=";$func_to_host_pathlist_result"
-            ;;
-        esac
-        case "$1" in
-          *: ) func_to_host_pathlist_result="$func_to_host_pathlist_result;"
-            ;;
-        esac
-        ;;
-    esac
-  fi
-}
-# end: func_to_host_pathlist
 
 # func_emit_cwrapperexe_src
 # emit the source code for a wrapper executable on stdout
@@ -3141,31 +4141,23 @@ func_emit_cwrapperexe_src ()
 
    This wrapper executable should never be moved out of the build directory.
    If it is, it will not operate correctly.
-
-   Currently, it simply execs the wrapper *script* "$SHELL $output",
-   but could eventually absorb all of the scripts functionality and
-   exec $objdir/$outputname directly.
 */
 EOF
 	    cat <<"EOF"
+#ifdef _MSC_VER
+# define _CRT_SECURE_NO_DEPRECATE 1
+#endif
 #include <stdio.h>
 #include <stdlib.h>
 #ifdef _MSC_VER
 # include <direct.h>
 # include <process.h>
 # include <io.h>
-# define setmode _setmode
 #else
 # include <unistd.h>
 # include <stdint.h>
 # ifdef __CYGWIN__
 #  include <io.h>
-#  define HAVE_SETENV
-#  ifdef __STRICT_ANSI__
-char *realpath (const char *, char *);
-int putenv (char *);
-int setenv (const char *, const char *, int);
-#  endif
 # endif
 #endif
 #include <malloc.h>
@@ -3177,6 +4169,44 @@ int setenv (const char *, const char *, int);
 #include <fcntl.h>
 #include <sys/stat.h>
 
+/* declarations of non-ANSI functions */
+#if defined(__MINGW32__)
+# ifdef __STRICT_ANSI__
+int _putenv (const char *);
+# endif
+#elif defined(__CYGWIN__)
+# ifdef __STRICT_ANSI__
+char *realpath (const char *, char *);
+int putenv (char *);
+int setenv (const char *, const char *, int);
+# endif
+/* #elif defined (other platforms) ... */
+#endif
+
+/* portability defines, excluding path handling macros */
+#if defined(_MSC_VER)
+# define setmode _setmode
+# define stat    _stat
+# define chmod   _chmod
+# define getcwd  _getcwd
+# define putenv  _putenv
+# define S_IXUSR _S_IEXEC
+# ifndef _INTPTR_T_DEFINED
+#  define _INTPTR_T_DEFINED
+#  define intptr_t int
+# endif
+#elif defined(__MINGW32__)
+# define setmode _setmode
+# define stat    _stat
+# define chmod   _chmod
+# define getcwd  _getcwd
+# define putenv  _putenv
+#elif defined(__CYGWIN__)
+# define HAVE_SETENV
+# define FOPEN_WB "wb"
+/* #elif defined (other platforms) ... */
+#endif
+
 #if defined(PATH_MAX)
 # define LT_PATHMAX PATH_MAX
 #elif defined(MAXPATHLEN)
@@ -3192,14 +4222,7 @@ int setenv (const char *, const char *, int);
 # define S_IXGRP 0
 #endif
 
-#ifdef _MSC_VER
-# define S_IXUSR _S_IEXEC
-# define stat _stat
-# ifndef _INTPTR_T_DEFINED
-#  define intptr_t int
-# endif
-#endif
-
+/* path handling portability macros */
 #ifndef DIR_SEPARATOR
 # define DIR_SEPARATOR '/'
 # define PATH_SEPARATOR ':'
@@ -3230,10 +4253,6 @@ int setenv (const char *, const char *, int);
 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2)
 #endif /* PATH_SEPARATOR_2 */
 
-#ifdef __CYGWIN__
-# define FOPEN_WB "wb"
-#endif
-
 #ifndef FOPEN_WB
 # define FOPEN_WB "w"
 #endif
@@ -3246,22 +4265,13 @@ int setenv (const char *, const char *, int);
   if (stale) { free ((void *) stale); stale = 0; } \
 } while (0)
 
-#undef LTWRAPPER_DEBUGPRINTF
-#if defined DEBUGWRAPPER
-# define LTWRAPPER_DEBUGPRINTF(args) ltwrapper_debugprintf args
-static void
-ltwrapper_debugprintf (const char *fmt, ...)
-{
-    va_list args;
-    va_start (args, fmt);
-    (void) vfprintf (stderr, fmt, args);
-    va_end (args);
-}
+#if defined(LT_DEBUGWRAPPER)
+static int lt_debug = 1;
 #else
-# define LTWRAPPER_DEBUGPRINTF(args)
+static int lt_debug = 0;
 #endif
 
-const char *program_name = NULL;
+const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */
 
 void *xmalloc (size_t num);
 char *xstrdup (const char *string);
@@ -3271,41 +4281,27 @@ char *chase_symlinks (const char *pathspec);
 int make_executable (const char *path);
 int check_executable (const char *path);
 char *strendzap (char *str, const char *pat);
-void lt_fatal (const char *message, ...);
+void lt_debugprintf (const char *file, int line, const char *fmt, ...);
+void lt_fatal (const char *file, int line, const char *message, ...);
+static const char *nonnull (const char *s);
+static const char *nonempty (const char *s);
 void lt_setenv (const char *name, const char *value);
 char *lt_extend_str (const char *orig_value, const char *add, int to_end);
-void lt_opt_process_env_set (const char *arg);
-void lt_opt_process_env_prepend (const char *arg);
-void lt_opt_process_env_append (const char *arg);
-int lt_split_name_value (const char *arg, char** name, char** value);
 void lt_update_exe_path (const char *name, const char *value);
 void lt_update_lib_path (const char *name, const char *value);
-
-static const char *script_text_part1 =
-EOF
-
-	    func_emit_wrapper_part1 yes |
-	        $SED -e 's/\([\\"]\)/\\\1/g' \
-	             -e 's/^/  "/' -e 's/$/\\n"/'
-	    echo ";"
-	    cat <<EOF
-
-static const char *script_text_part2 =
+char **prepare_spawn (char **argv);
+void lt_dump_script (FILE *f);
 EOF
-	    func_emit_wrapper_part2 yes |
-	        $SED -e 's/\([\\"]\)/\\\1/g' \
-	             -e 's/^/  "/' -e 's/$/\\n"/'
-	    echo ";"
 
 	    cat <<EOF
-const char * MAGIC_EXE = "$magic_exe";
+volatile const char * MAGIC_EXE = "$magic_exe";
 const char * LIB_PATH_VARNAME = "$shlibpath_var";
 EOF
 
 	    if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
-              func_to_host_pathlist "$temp_rpath"
+              func_to_host_path "$temp_rpath"
 	      cat <<EOF
-const char * LIB_PATH_VALUE   = "$func_to_host_pathlist_result";
+const char * LIB_PATH_VALUE   = "$func_to_host_path_result";
 EOF
 	    else
 	      cat <<"EOF"
@@ -3314,10 +4310,10 @@ EOF
 	    fi
 
 	    if test -n "$dllsearchpath"; then
-              func_to_host_pathlist "$dllsearchpath:"
+              func_to_host_path "$dllsearchpath:"
 	      cat <<EOF
 const char * EXE_PATH_VARNAME = "PATH";
-const char * EXE_PATH_VALUE   = "$func_to_host_pathlist_result";
+const char * EXE_PATH_VALUE   = "$func_to_host_path_result";
 EOF
 	    else
 	      cat <<"EOF"
@@ -3340,24 +4336,10 @@ EOF
 	    cat <<"EOF"
 
 #define LTWRAPPER_OPTION_PREFIX         "--lt-"
-#define LTWRAPPER_OPTION_PREFIX_LENGTH  5
 
-static const size_t opt_prefix_len         = LTWRAPPER_OPTION_PREFIX_LENGTH;
 static const char *ltwrapper_option_prefix = LTWRAPPER_OPTION_PREFIX;
-
 static const char *dumpscript_opt       = LTWRAPPER_OPTION_PREFIX "dump-script";
-
-static const size_t env_set_opt_len     = LTWRAPPER_OPTION_PREFIX_LENGTH + 7;
-static const char *env_set_opt          = LTWRAPPER_OPTION_PREFIX "env-set";
-  /* argument is putenv-style "foo=bar", value of foo is set to bar */
-
-static const size_t env_prepend_opt_len = LTWRAPPER_OPTION_PREFIX_LENGTH + 11;
-static const char *env_prepend_opt      = LTWRAPPER_OPTION_PREFIX "env-prepend";
-  /* argument is putenv-style "foo=bar", new value of foo is bar${foo} */
-
-static const size_t env_append_opt_len  = LTWRAPPER_OPTION_PREFIX_LENGTH + 10;
-static const char *env_append_opt       = LTWRAPPER_OPTION_PREFIX "env-append";
-  /* argument is putenv-style "foo=bar", new value of foo is ${foo}bar */
+static const char *debug_opt            = LTWRAPPER_OPTION_PREFIX "debug";
 
 int
 main (int argc, char *argv[])
@@ -3374,10 +4356,13 @@ main (int argc, char *argv[])
   int i;
 
   program_name = (char *) xstrdup (base_name (argv[0]));
-  LTWRAPPER_DEBUGPRINTF (("(main) argv[0]      : %s\n", argv[0]));
-  LTWRAPPER_DEBUGPRINTF (("(main) program_name : %s\n", program_name));
+  newargz = XMALLOC (char *, argc + 1);
 
-  /* very simple arg parsing; don't want to rely on getopt */
+  /* very simple arg parsing; don't want to rely on getopt
+   * also, copy all non cwrapper options to newargz, except
+   * argz[0], which is handled differently
+   */
+  newargc=0;
   for (i = 1; i < argc; i++)
     {
       if (strcmp (argv[i], dumpscript_opt) == 0)
@@ -3391,25 +4376,57 @@ EOF
 	      esac
 
 	    cat <<"EOF"
-	  printf ("%s", script_text_part1);
-	  printf ("%s", script_text_part2);
+	  lt_dump_script (stdout);
 	  return 0;
 	}
+      if (strcmp (argv[i], debug_opt) == 0)
+	{
+          lt_debug = 1;
+          continue;
+	}
+      if (strcmp (argv[i], ltwrapper_option_prefix) == 0)
+        {
+          /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
+             namespace, but it is not one of the ones we know about and
+             have already dealt with, above (inluding dump-script), then
+             report an error. Otherwise, targets might begin to believe
+             they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
+             namespace. The first time any user complains about this, we'll
+             need to make LTWRAPPER_OPTION_PREFIX a configure-time option
+             or a configure.ac-settable value.
+           */
+          lt_fatal (__FILE__, __LINE__,
+		    "unrecognized %s option: '%s'",
+                    ltwrapper_option_prefix, argv[i]);
+        }
+      /* otherwise ... */
+      newargz[++newargc] = xstrdup (argv[i]);
     }
+  newargz[++newargc] = NULL;
+
+EOF
+	    cat <<EOF
+  /* The GNU banner must be the first non-error debug message */
+  lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\n");
+EOF
+	    cat <<"EOF"
+  lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]);
+  lt_debugprintf (__FILE__, __LINE__, "(main) program_name: %s\n", program_name);
 
-  newargz = XMALLOC (char *, argc + 1);
   tmp_pathspec = find_executable (argv[0]);
   if (tmp_pathspec == NULL)
-    lt_fatal ("Couldn't find %s", argv[0]);
-  LTWRAPPER_DEBUGPRINTF (("(main) found exe (before symlink chase) at : %s\n",
-			  tmp_pathspec));
+    lt_fatal (__FILE__, __LINE__, "couldn't find %s", argv[0]);
+  lt_debugprintf (__FILE__, __LINE__,
+                  "(main) found exe (before symlink chase) at: %s\n",
+		  tmp_pathspec);
 
   actual_cwrapper_path = chase_symlinks (tmp_pathspec);
-  LTWRAPPER_DEBUGPRINTF (("(main) found exe (after symlink chase) at : %s\n",
-			  actual_cwrapper_path));
+  lt_debugprintf (__FILE__, __LINE__,
+                  "(main) found exe (after symlink chase) at: %s\n",
+		  actual_cwrapper_path);
   XFREE (tmp_pathspec);
 
-  actual_cwrapper_name = xstrdup( base_name (actual_cwrapper_path));
+  actual_cwrapper_name = xstrdup (base_name (actual_cwrapper_path));
   strendzap (actual_cwrapper_path, actual_cwrapper_name);
 
   /* wrapper name transforms */
@@ -3427,8 +4444,9 @@ EOF
   target_name = tmp_pathspec;
   tmp_pathspec = 0;
 
-  LTWRAPPER_DEBUGPRINTF (("(main) libtool target name: %s\n",
-			  target_name));
+  lt_debugprintf (__FILE__, __LINE__,
+		  "(main) libtool target name: %s\n",
+		  target_name);
 EOF
 
 	    cat <<EOF
@@ -3478,80 +4496,19 @@ EOF
 
   lt_setenv ("BIN_SH", "xpg4"); /* for Tru64 */
   lt_setenv ("DUALCASE", "1");  /* for MSK sh */
-  lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE);
+  /* Update the DLL searchpath.  EXE_PATH_VALUE ($dllsearchpath) must
+     be prepended before (that is, appear after) LIB_PATH_VALUE ($temp_rpath)
+     because on Windows, both *_VARNAMEs are PATH but uninstalled
+     libraries must come first. */
   lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE);
+  lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE);
 
-  newargc=0;
-  for (i = 1; i < argc; i++)
-    {
-      if (strncmp (argv[i], env_set_opt, env_set_opt_len) == 0)
-        {
-          if (argv[i][env_set_opt_len] == '=')
-            {
-              const char *p = argv[i] + env_set_opt_len + 1;
-              lt_opt_process_env_set (p);
-            }
-          else if (argv[i][env_set_opt_len] == '\0' && i + 1 < argc)
-            {
-              lt_opt_process_env_set (argv[++i]); /* don't copy */
-            }
-          else
-            lt_fatal ("%s missing required argument", env_set_opt);
-          continue;
-        }
-      if (strncmp (argv[i], env_prepend_opt, env_prepend_opt_len) == 0)
-        {
-          if (argv[i][env_prepend_opt_len] == '=')
-            {
-              const char *p = argv[i] + env_prepend_opt_len + 1;
-              lt_opt_process_env_prepend (p);
-            }
-          else if (argv[i][env_prepend_opt_len] == '\0' && i + 1 < argc)
-            {
-              lt_opt_process_env_prepend (argv[++i]); /* don't copy */
-            }
-          else
-            lt_fatal ("%s missing required argument", env_prepend_opt);
-          continue;
-        }
-      if (strncmp (argv[i], env_append_opt, env_append_opt_len) == 0)
-        {
-          if (argv[i][env_append_opt_len] == '=')
-            {
-              const char *p = argv[i] + env_append_opt_len + 1;
-              lt_opt_process_env_append (p);
-            }
-          else if (argv[i][env_append_opt_len] == '\0' && i + 1 < argc)
-            {
-              lt_opt_process_env_append (argv[++i]); /* don't copy */
-            }
-          else
-            lt_fatal ("%s missing required argument", env_append_opt);
-          continue;
-        }
-      if (strncmp (argv[i], ltwrapper_option_prefix, opt_prefix_len) == 0)
-        {
-          /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
-             namespace, but it is not one of the ones we know about and
-             have already dealt with, above (inluding dump-script), then
-             report an error. Otherwise, targets might begin to believe
-             they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
-             namespace. The first time any user complains about this, we'll
-             need to make LTWRAPPER_OPTION_PREFIX a configure-time option
-             or a configure.ac-settable value.
-           */
-          lt_fatal ("Unrecognized option in %s namespace: '%s'",
-                    ltwrapper_option_prefix, argv[i]);
-        }
-      /* otherwise ... */
-      newargz[++newargc] = xstrdup (argv[i]);
-    }
-  newargz[++newargc] = NULL;
-
-  LTWRAPPER_DEBUGPRINTF     (("(main) lt_argv_zero : %s\n", (lt_argv_zero ? lt_argv_zero : "<NULL>")));
+  lt_debugprintf (__FILE__, __LINE__, "(main) lt_argv_zero: %s\n",
+		  nonnull (lt_argv_zero));
   for (i = 0; i < newargc; i++)
     {
-      LTWRAPPER_DEBUGPRINTF (("(main) newargz[%d]   : %s\n", i, (newargz[i] ? newargz[i] : "<NULL>")));
+      lt_debugprintf (__FILE__, __LINE__, "(main) newargz[%d]: %s\n",
+		      i, nonnull (newargz[i]));
     }
 
 EOF
@@ -3560,11 +4517,14 @@ EOF
 	      mingw*)
 		cat <<"EOF"
   /* execv doesn't actually work on mingw as expected on unix */
+  newargz = prepare_spawn (newargz);
   rval = _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz);
   if (rval == -1)
     {
       /* failed to start process */
-      LTWRAPPER_DEBUGPRINTF (("(main) failed to launch target \"%s\": errno = %d\n", lt_argv_zero, errno));
+      lt_debugprintf (__FILE__, __LINE__,
+		      "(main) failed to launch target \"%s\": %s\n",
+		      lt_argv_zero, nonnull (strerror (errno)));
       return 127;
     }
   return rval;
@@ -3586,7 +4546,7 @@ xmalloc (size_t num)
 {
   void *p = (void *) malloc (num);
   if (!p)
-    lt_fatal ("Memory exhausted");
+    lt_fatal (__FILE__, __LINE__, "memory exhausted");
 
   return p;
 }
@@ -3620,8 +4580,8 @@ check_executable (const char *path)
 {
   struct stat st;
 
-  LTWRAPPER_DEBUGPRINTF (("(check_executable)  : %s\n",
-			  path ? (*path ? path : "EMPTY!") : "NULL!"));
+  lt_debugprintf (__FILE__, __LINE__, "(check_executable): %s\n",
+                  nonempty (path));
   if ((!path) || (!*path))
     return 0;
 
@@ -3638,8 +4598,8 @@ make_executable (const char *path)
   int rval = 0;
   struct stat st;
 
-  LTWRAPPER_DEBUGPRINTF (("(make_executable)   : %s\n",
-			  path ? (*path ? path : "EMPTY!") : "NULL!"));
+  lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n",
+                  nonempty (path));
   if ((!path) || (!*path))
     return 0;
 
@@ -3665,8 +4625,8 @@ find_executable (const char *wrapper)
   int tmp_len;
   char *concat_name;
 
-  LTWRAPPER_DEBUGPRINTF (("(find_executable)   : %s\n",
-			  wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"));
+  lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n",
+                  nonempty (wrapper));
 
   if ((wrapper == NULL) || (*wrapper == '\0'))
     return NULL;
@@ -3719,7 +4679,8 @@ find_executable (const char *wrapper)
 		{
 		  /* empty path: current directory */
 		  if (getcwd (tmp, LT_PATHMAX) == NULL)
-		    lt_fatal ("getcwd failed");
+		    lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
+                              nonnull (strerror (errno)));
 		  tmp_len = strlen (tmp);
 		  concat_name =
 		    XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
@@ -3744,7 +4705,8 @@ find_executable (const char *wrapper)
     }
   /* Relative path | not found in path: prepend cwd */
   if (getcwd (tmp, LT_PATHMAX) == NULL)
-    lt_fatal ("getcwd failed");
+    lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
+              nonnull (strerror (errno)));
   tmp_len = strlen (tmp);
   concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
   memcpy (concat_name, tmp, tmp_len);
@@ -3770,8 +4732,9 @@ chase_symlinks (const char *pathspec)
   int has_symlinks = 0;
   while (strlen (tmp_pathspec) && !has_symlinks)
     {
-      LTWRAPPER_DEBUGPRINTF (("checking path component for symlinks: %s\n",
-			      tmp_pathspec));
+      lt_debugprintf (__FILE__, __LINE__,
+		      "checking path component for symlinks: %s\n",
+		      tmp_pathspec);
       if (lstat (tmp_pathspec, &s) == 0)
 	{
 	  if (S_ISLNK (s.st_mode) != 0)
@@ -3793,8 +4756,9 @@ chase_symlinks (const char *pathspec)
 	}
       else
 	{
-	  char *errstr = strerror (errno);
-	  lt_fatal ("Error accessing file %s (%s)", tmp_pathspec, errstr);
+	  lt_fatal (__FILE__, __LINE__,
+		    "error accessing file \"%s\": %s",
+		    tmp_pathspec, nonnull (strerror (errno)));
 	}
     }
   XFREE (tmp_pathspec);
@@ -3807,7 +4771,8 @@ chase_symlinks (const char *pathspec)
   tmp_pathspec = realpath (pathspec, buf);
   if (tmp_pathspec == 0)
     {
-      lt_fatal ("Could not follow symlinks for %s", pathspec);
+      lt_fatal (__FILE__, __LINE__,
+		"could not follow symlinks for %s", pathspec);
     }
   return xstrdup (tmp_pathspec);
 #endif
@@ -3833,11 +4798,25 @@ strendzap (char *str, const char *pat)
   return str;
 }
 
+void
+lt_debugprintf (const char *file, int line, const char *fmt, ...)
+{
+  va_list args;
+  if (lt_debug)
+    {
+      (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line);
+      va_start (args, fmt);
+      (void) vfprintf (stderr, fmt, args);
+      va_end (args);
+    }
+}
+
 static void
-lt_error_core (int exit_status, const char *mode,
+lt_error_core (int exit_status, const char *file,
+	       int line, const char *mode,
 	       const char *message, va_list ap)
 {
-  fprintf (stderr, "%s: %s: ", program_name, mode);
+  fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode);
   vfprintf (stderr, message, ap);
   fprintf (stderr, ".\n");
 
@@ -3846,20 +4825,32 @@ lt_error_core (int exit_status, const char *mode,
 }
 
 void
-lt_fatal (const char *message, ...)
+lt_fatal (const char *file, int line, const char *message, ...)
 {
   va_list ap;
   va_start (ap, message);
-  lt_error_core (EXIT_FAILURE, "FATAL", message, ap);
+  lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap);
   va_end (ap);
 }
 
+static const char *
+nonnull (const char *s)
+{
+  return s ? s : "(null)";
+}
+
+static const char *
+nonempty (const char *s)
+{
+  return (s && !*s) ? "(empty)" : nonnull (s);
+}
+
 void
 lt_setenv (const char *name, const char *value)
 {
-  LTWRAPPER_DEBUGPRINTF (("(lt_setenv) setting '%s' to '%s'\n",
-                          (name ? name : "<NULL>"),
-                          (value ? value : "<NULL>")));
+  lt_debugprintf (__FILE__, __LINE__,
+		  "(lt_setenv) setting '%s' to '%s'\n",
+                  nonnull (name), nonnull (value));
   {
 #ifdef HAVE_SETENV
     /* always make a copy, for consistency with !HAVE_SETENV */
@@ -3904,95 +4895,12 @@ lt_extend_str (const char *orig_value, const char *add, int to_end)
   return new_value;
 }
 
-int
-lt_split_name_value (const char *arg, char** name, char** value)
-{
-  const char *p;
-  int len;
-  if (!arg || !*arg)
-    return 1;
-
-  p = strchr (arg, (int)'=');
-
-  if (!p)
-    return 1;
-
-  *value = xstrdup (++p);
-
-  len = strlen (arg) - strlen (*value);
-  *name = XMALLOC (char, len);
-  strncpy (*name, arg, len-1);
-  (*name)[len - 1] = '\0';
-
-  return 0;
-}
-
-void
-lt_opt_process_env_set (const char *arg)
-{
-  char *name = NULL;
-  char *value = NULL;
-
-  if (lt_split_name_value (arg, &name, &value) != 0)
-    {
-      XFREE (name);
-      XFREE (value);
-      lt_fatal ("bad argument for %s: '%s'", env_set_opt, arg);
-    }
-
-  lt_setenv (name, value);
-  XFREE (name);
-  XFREE (value);
-}
-
-void
-lt_opt_process_env_prepend (const char *arg)
-{
-  char *name = NULL;
-  char *value = NULL;
-  char *new_value = NULL;
-
-  if (lt_split_name_value (arg, &name, &value) != 0)
-    {
-      XFREE (name);
-      XFREE (value);
-      lt_fatal ("bad argument for %s: '%s'", env_prepend_opt, arg);
-    }
-
-  new_value = lt_extend_str (getenv (name), value, 0);
-  lt_setenv (name, new_value);
-  XFREE (new_value);
-  XFREE (name);
-  XFREE (value);
-}
-
-void
-lt_opt_process_env_append (const char *arg)
-{
-  char *name = NULL;
-  char *value = NULL;
-  char *new_value = NULL;
-
-  if (lt_split_name_value (arg, &name, &value) != 0)
-    {
-      XFREE (name);
-      XFREE (value);
-      lt_fatal ("bad argument for %s: '%s'", env_append_opt, arg);
-    }
-
-  new_value = lt_extend_str (getenv (name), value, 1);
-  lt_setenv (name, new_value);
-  XFREE (new_value);
-  XFREE (name);
-  XFREE (value);
-}
-
 void
 lt_update_exe_path (const char *name, const char *value)
 {
-  LTWRAPPER_DEBUGPRINTF (("(lt_update_exe_path) modifying '%s' by prepending '%s'\n",
-                          (name ? name : "<NULL>"),
-                          (value ? value : "<NULL>")));
+  lt_debugprintf (__FILE__, __LINE__,
+		  "(lt_update_exe_path) modifying '%s' by prepending '%s'\n",
+                  nonnull (name), nonnull (value));
 
   if (name && *name && value && *value)
     {
@@ -4011,9 +4919,9 @@ lt_update_exe_path (const char *name, const char *value)
 void
 lt_update_lib_path (const char *name, const char *value)
 {
-  LTWRAPPER_DEBUGPRINTF (("(lt_update_lib_path) modifying '%s' by prepending '%s'\n",
-                          (name ? name : "<NULL>"),
-                          (value ? value : "<NULL>")));
+  lt_debugprintf (__FILE__, __LINE__,
+		  "(lt_update_lib_path) modifying '%s' by prepending '%s'\n",
+                  nonnull (name), nonnull (value));
 
   if (name && *name && value && *value)
     {
@@ -4023,11 +4931,152 @@ lt_update_lib_path (const char *name, const char *value)
     }
 }
 
+EOF
+	    case $host_os in
+	      mingw*)
+		cat <<"EOF"
+
+/* Prepares an argument vector before calling spawn().
+   Note that spawn() does not by itself call the command interpreter
+     (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") :
+      ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
+         GetVersionEx(&v);
+         v.dwPlatformId == VER_PLATFORM_WIN32_NT;
+      }) ? "cmd.exe" : "command.com").
+   Instead it simply concatenates the arguments, separated by ' ', and calls
+   CreateProcess().  We must quote the arguments since Win32 CreateProcess()
+   interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a
+   special way:
+   - Space and tab are interpreted as delimiters. They are not treated as
+     delimiters if they are surrounded by double quotes: "...".
+   - Unescaped double quotes are removed from the input. Their only effect is
+     that within double quotes, space and tab are treated like normal
+     characters.
+   - Backslashes not followed by double quotes are not special.
+   - But 2*n+1 backslashes followed by a double quote become
+     n backslashes followed by a double quote (n >= 0):
+       \" -> "
+       \\\" -> \"
+       \\\\\" -> \\"
+ */
+#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
+#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
+char **
+prepare_spawn (char **argv)
+{
+  size_t argc;
+  char **new_argv;
+  size_t i;
+
+  /* Count number of arguments.  */
+  for (argc = 0; argv[argc] != NULL; argc++)
+    ;
+
+  /* Allocate new argument vector.  */
+  new_argv = XMALLOC (char *, argc + 1);
+
+  /* Put quoted arguments into the new argument vector.  */
+  for (i = 0; i < argc; i++)
+    {
+      const char *string = argv[i];
+
+      if (string[0] == '\0')
+	new_argv[i] = xstrdup ("\"\"");
+      else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL)
+	{
+	  int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL);
+	  size_t length;
+	  unsigned int backslashes;
+	  const char *s;
+	  char *quoted_string;
+	  char *p;
+
+	  length = 0;
+	  backslashes = 0;
+	  if (quote_around)
+	    length++;
+	  for (s = string; *s != '\0'; s++)
+	    {
+	      char c = *s;
+	      if (c == '"')
+		length += backslashes + 1;
+	      length++;
+	      if (c == '\\')
+		backslashes++;
+	      else
+		backslashes = 0;
+	    }
+	  if (quote_around)
+	    length += backslashes + 1;
+
+	  quoted_string = XMALLOC (char, length + 1);
+
+	  p = quoted_string;
+	  backslashes = 0;
+	  if (quote_around)
+	    *p++ = '"';
+	  for (s = string; *s != '\0'; s++)
+	    {
+	      char c = *s;
+	      if (c == '"')
+		{
+		  unsigned int j;
+		  for (j = backslashes + 1; j > 0; j--)
+		    *p++ = '\\';
+		}
+	      *p++ = c;
+	      if (c == '\\')
+		backslashes++;
+	      else
+		backslashes = 0;
+	    }
+	  if (quote_around)
+	    {
+	      unsigned int j;
+	      for (j = backslashes; j > 0; j--)
+		*p++ = '\\';
+	      *p++ = '"';
+	    }
+	  *p = '\0';
+
+	  new_argv[i] = quoted_string;
+	}
+      else
+	new_argv[i] = (char *) string;
+    }
+  new_argv[argc] = NULL;
+
+  return new_argv;
+}
+EOF
+		;;
+	    esac
+
+            cat <<"EOF"
+void lt_dump_script (FILE* f)
+{
+EOF
+	    func_emit_wrapper yes |
+              $SED -e 's/\([\\"]\)/\\\1/g' \
+	           -e 's/^/  fputs ("/' -e 's/$/\\n", f);/'
 
+            cat <<"EOF"
+}
 EOF
 }
 # end: func_emit_cwrapperexe_src
 
+# func_win32_import_lib_p ARG
+# True if ARG is an import lib, as indicated by $file_magic_cmd
+func_win32_import_lib_p ()
+{
+    $opt_debug
+    case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in
+    *import*) : ;;
+    *) false ;;
+    esac
+}
+
 # func_mode_link arg...
 func_mode_link ()
 {
@@ -4072,6 +5121,7 @@ func_mode_link ()
     new_inherited_linker_flags=
 
     avoid_version=no
+    bindir=
     dlfiles=
     dlprefiles=
     dlself=no
@@ -4164,6 +5214,11 @@ func_mode_link ()
 	esac
 
 	case $prev in
+	bindir)
+	  bindir="$arg"
+	  prev=
+	  continue
+	  ;;
 	dlfiles|dlprefiles)
 	  if test "$preload" = no; then
 	    # Add the symbol object into the linking commands.
@@ -4195,9 +5250,9 @@ func_mode_link ()
 	    ;;
 	  *)
 	    if test "$prev" = dlfiles; then
-	      dlfiles="$dlfiles $arg"
+	      func_append dlfiles " $arg"
 	    else
-	      dlprefiles="$dlprefiles $arg"
+	      func_append dlprefiles " $arg"
 	    fi
 	    prev=
 	    continue
@@ -4221,7 +5276,7 @@ func_mode_link ()
 	    *-*-darwin*)
 	      case "$deplibs " in
 		*" $qarg.ltframework "*) ;;
-		*) deplibs="$deplibs $qarg.ltframework" # this is fixed later
+		*) func_append deplibs " $qarg.ltframework" # this is fixed later
 		   ;;
 	      esac
 	      ;;
@@ -4240,7 +5295,7 @@ func_mode_link ()
 	    moreargs=
 	    for fil in `cat "$save_arg"`
 	    do
-#	      moreargs="$moreargs $fil"
+#	      func_append moreargs " $fil"
 	      arg=$fil
 	      # A libtool-controlled object.
 
@@ -4269,7 +5324,7 @@ func_mode_link ()
 
 		  if test "$prev" = dlfiles; then
 		    if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
-		      dlfiles="$dlfiles $pic_object"
+		      func_append dlfiles " $pic_object"
 		      prev=
 		      continue
 		    else
@@ -4281,7 +5336,7 @@ func_mode_link ()
 		  # CHECK ME:  I think I busted this.  -Ossama
 		  if test "$prev" = dlprefiles; then
 		    # Preload the old-style object.
-		    dlprefiles="$dlprefiles $pic_object"
+		    func_append dlprefiles " $pic_object"
 		    prev=
 		  fi
 
@@ -4351,12 +5406,12 @@ func_mode_link ()
 	  if test "$prev" = rpath; then
 	    case "$rpath " in
 	    *" $arg "*) ;;
-	    *) rpath="$rpath $arg" ;;
+	    *) func_append rpath " $arg" ;;
 	    esac
 	  else
 	    case "$xrpath " in
 	    *" $arg "*) ;;
-	    *) xrpath="$xrpath $arg" ;;
+	    *) func_append xrpath " $arg" ;;
 	    esac
 	  fi
 	  prev=
@@ -4368,28 +5423,28 @@ func_mode_link ()
 	  continue
 	  ;;
 	weak)
-	  weak_libs="$weak_libs $arg"
+	  func_append weak_libs " $arg"
 	  prev=
 	  continue
 	  ;;
 	xcclinker)
-	  linker_flags="$linker_flags $qarg"
-	  compiler_flags="$compiler_flags $qarg"
+	  func_append linker_flags " $qarg"
+	  func_append compiler_flags " $qarg"
 	  prev=
 	  func_append compile_command " $qarg"
 	  func_append finalize_command " $qarg"
 	  continue
 	  ;;
 	xcompiler)
-	  compiler_flags="$compiler_flags $qarg"
+	  func_append compiler_flags " $qarg"
 	  prev=
 	  func_append compile_command " $qarg"
 	  func_append finalize_command " $qarg"
 	  continue
 	  ;;
 	xlinker)
-	  linker_flags="$linker_flags $qarg"
-	  compiler_flags="$compiler_flags $wl$qarg"
+	  func_append linker_flags " $qarg"
+	  func_append compiler_flags " $wl$qarg"
 	  prev=
 	  func_append compile_command " $wl$qarg"
 	  func_append finalize_command " $wl$qarg"
@@ -4425,6 +5480,11 @@ func_mode_link ()
 	continue
 	;;
 
+      -bindir)
+	prev=bindir
+	continue
+	;;
+
       -dlopen)
 	prev=dlfiles
 	continue
@@ -4475,15 +5535,16 @@ func_mode_link ()
 	;;
 
       -L*)
-	func_stripname '-L' '' "$arg"
-	dir=$func_stripname_result
-	if test -z "$dir"; then
+	func_stripname "-L" '' "$arg"
+	if test -z "$func_stripname_result"; then
 	  if test "$#" -gt 0; then
 	    func_fatal_error "require no space between \`-L' and \`$1'"
 	  else
 	    func_fatal_error "need path for \`-L' option"
 	  fi
 	fi
+	func_resolve_sysroot "$func_stripname_result"
+	dir=$func_resolve_sysroot_result
 	# We need an absolute path.
 	case $dir in
 	[\\/]* | [A-Za-z]:[\\/]*) ;;
@@ -4495,24 +5556,30 @@ func_mode_link ()
 	  ;;
 	esac
 	case "$deplibs " in
-	*" -L$dir "*) ;;
+	*" -L$dir "* | *" $arg "*)
+	  # Will only happen for absolute or sysroot arguments
+	  ;;
 	*)
-	  deplibs="$deplibs -L$dir"
-	  lib_search_path="$lib_search_path $dir"
+	  # Preserve sysroot, but never include relative directories
+	  case $dir in
+	    [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;;
+	    *) func_append deplibs " -L$dir" ;;
+	  esac
+	  func_append lib_search_path " $dir"
 	  ;;
 	esac
 	case $host in
 	*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
-	  testbindir=`$ECHO "X$dir" | $Xsed -e 's*/lib$*/bin*'`
+	  testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'`
 	  case :$dllsearchpath: in
 	  *":$dir:"*) ;;
 	  ::) dllsearchpath=$dir;;
-	  *) dllsearchpath="$dllsearchpath:$dir";;
+	  *) func_append dllsearchpath ":$dir";;
 	  esac
 	  case :$dllsearchpath: in
 	  *":$testbindir:"*) ;;
 	  ::) dllsearchpath=$testbindir;;
-	  *) dllsearchpath="$dllsearchpath:$testbindir";;
+	  *) func_append dllsearchpath ":$testbindir";;
 	  esac
 	  ;;
 	esac
@@ -4522,7 +5589,7 @@ func_mode_link ()
       -l*)
 	if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
 	  case $host in
-	  *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc*)
+	  *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*)
 	    # These systems don't actually have a C or math library (as such)
 	    continue
 	    ;;
@@ -4536,7 +5603,7 @@ func_mode_link ()
 	    ;;
 	  *-*-rhapsody* | *-*-darwin1.[012])
 	    # Rhapsody C and math libraries are in the System framework
-	    deplibs="$deplibs System.ltframework"
+	    func_append deplibs " System.ltframework"
 	    continue
 	    ;;
 	  *-*-sco3.2v5* | *-*-sco5v6*)
@@ -4556,7 +5623,7 @@ func_mode_link ()
 	   ;;
 	 esac
 	fi
-	deplibs="$deplibs $arg"
+	func_append deplibs " $arg"
 	continue
 	;;
 
@@ -4568,8 +5635,8 @@ func_mode_link ()
       # Tru64 UNIX uses -model [arg] to determine the layout of C++
       # classes, name mangling, and exception handling.
       # Darwin uses the -arch flag to determine output architecture.
-      -model|-arch|-isysroot)
-	compiler_flags="$compiler_flags $arg"
+      -model|-arch|-isysroot|--sysroot)
+	func_append compiler_flags " $arg"
 	func_append compile_command " $arg"
 	func_append finalize_command " $arg"
 	prev=xcompiler
@@ -4577,12 +5644,12 @@ func_mode_link ()
 	;;
 
       -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
-	compiler_flags="$compiler_flags $arg"
+	func_append compiler_flags " $arg"
 	func_append compile_command " $arg"
 	func_append finalize_command " $arg"
 	case "$new_inherited_linker_flags " in
 	    *" $arg "*) ;;
-	    * ) new_inherited_linker_flags="$new_inherited_linker_flags $arg" ;;
+	    * ) func_append new_inherited_linker_flags " $arg" ;;
 	esac
 	continue
 	;;
@@ -4649,13 +5716,17 @@ func_mode_link ()
 	# We need an absolute path.
 	case $dir in
 	[\\/]* | [A-Za-z]:[\\/]*) ;;
+	=*)
+	  func_stripname '=' '' "$dir"
+	  dir=$lt_sysroot$func_stripname_result
+	  ;;
 	*)
 	  func_fatal_error "only absolute run-paths are allowed"
 	  ;;
 	esac
 	case "$xrpath " in
 	*" $dir "*) ;;
-	*) xrpath="$xrpath $dir" ;;
+	*) func_append xrpath " $dir" ;;
 	esac
 	continue
 	;;
@@ -4708,8 +5779,8 @@ func_mode_link ()
 	for flag in $args; do
 	  IFS="$save_ifs"
           func_quote_for_eval "$flag"
-	  arg="$arg $wl$func_quote_for_eval_result"
-	  compiler_flags="$compiler_flags $func_quote_for_eval_result"
+	  func_append arg " $func_quote_for_eval_result"
+	  func_append compiler_flags " $func_quote_for_eval_result"
 	done
 	IFS="$save_ifs"
 	func_stripname ' ' '' "$arg"
@@ -4724,9 +5795,9 @@ func_mode_link ()
 	for flag in $args; do
 	  IFS="$save_ifs"
           func_quote_for_eval "$flag"
-	  arg="$arg $wl$func_quote_for_eval_result"
-	  compiler_flags="$compiler_flags $wl$func_quote_for_eval_result"
-	  linker_flags="$linker_flags $func_quote_for_eval_result"
+	  func_append arg " $wl$func_quote_for_eval_result"
+	  func_append compiler_flags " $wl$func_quote_for_eval_result"
+	  func_append linker_flags " $func_quote_for_eval_result"
 	done
 	IFS="$save_ifs"
 	func_stripname ' ' '' "$arg"
@@ -4754,23 +5825,27 @@ func_mode_link ()
 	arg="$func_quote_for_eval_result"
 	;;
 
-      # -64, -mips[0-9] enable 64-bit mode on the SGI compiler
-      # -r[0-9][0-9]* specifies the processor on the SGI compiler
-      # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler
-      # +DA*, +DD* enable 64-bit mode on the HP compiler
-      # -q* pass through compiler args for the IBM compiler
-      # -m*, -t[45]*, -txscale* pass through architecture-specific
-      # compiler args for GCC
-      # -F/path gives path to uninstalled frameworks, gcc on darwin
-      # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC
-      # @file GCC response files
+      # Flags to be passed through unchanged, with rationale:
+      # -64, -mips[0-9]      enable 64-bit mode for the SGI compiler
+      # -r[0-9][0-9]*        specify processor for the SGI compiler
+      # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler
+      # +DA*, +DD*           enable 64-bit mode for the HP compiler
+      # -q*                  compiler args for the IBM compiler
+      # -m*, -t[45]*, -txscale* architecture-specific flags for GCC
+      # -F/path              path to uninstalled frameworks, gcc on darwin
+      # -p, -pg, --coverage, -fprofile-*  profiling flags for GCC
+      # @file                GCC response files
+      # -tp=*                Portland pgcc target processor selection
+      # --sysroot=*          for sysroot support
+      # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
       -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
-      -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*)
+      -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
+      -O*|-flto*|-fwhopr*|-fuse-linker-plugin)
         func_quote_for_eval "$arg"
 	arg="$func_quote_for_eval_result"
         func_append compile_command " $arg"
         func_append finalize_command " $arg"
-        compiler_flags="$compiler_flags $arg"
+        func_append compiler_flags " $arg"
         continue
         ;;
 
@@ -4782,7 +5857,7 @@ func_mode_link ()
 
       *.$objext)
 	# A standard object.
-	objs="$objs $arg"
+	func_append objs " $arg"
 	;;
 
       *.lo)
@@ -4813,7 +5888,7 @@ func_mode_link ()
 
 	    if test "$prev" = dlfiles; then
 	      if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
-		dlfiles="$dlfiles $pic_object"
+		func_append dlfiles " $pic_object"
 		prev=
 		continue
 	      else
@@ -4825,7 +5900,7 @@ func_mode_link ()
 	    # CHECK ME:  I think I busted this.  -Ossama
 	    if test "$prev" = dlprefiles; then
 	      # Preload the old-style object.
-	      dlprefiles="$dlprefiles $pic_object"
+	      func_append dlprefiles " $pic_object"
 	      prev=
 	    fi
 
@@ -4870,24 +5945,25 @@ func_mode_link ()
 
       *.$libext)
 	# An archive.
-	deplibs="$deplibs $arg"
-	old_deplibs="$old_deplibs $arg"
+	func_append deplibs " $arg"
+	func_append old_deplibs " $arg"
 	continue
 	;;
 
       *.la)
 	# A libtool-controlled library.
 
+	func_resolve_sysroot "$arg"
 	if test "$prev" = dlfiles; then
 	  # This library was specified with -dlopen.
-	  dlfiles="$dlfiles $arg"
+	  func_append dlfiles " $func_resolve_sysroot_result"
 	  prev=
 	elif test "$prev" = dlprefiles; then
 	  # The library was specified with -dlpreopen.
-	  dlprefiles="$dlprefiles $arg"
+	  func_append dlprefiles " $func_resolve_sysroot_result"
 	  prev=
 	else
-	  deplibs="$deplibs $arg"
+	  func_append deplibs " $func_resolve_sysroot_result"
 	fi
 	continue
 	;;
@@ -4925,7 +6001,7 @@ func_mode_link ()
 
     if test -n "$shlibpath_var"; then
       # get the directories listed in $shlibpath_var
-      eval shlib_search_path=\`\$ECHO \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\`
+      eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\`
     else
       shlib_search_path=
     fi
@@ -4934,6 +6010,8 @@ func_mode_link ()
 
     func_dirname "$output" "/" ""
     output_objdir="$func_dirname_result$objdir"
+    func_to_tool_file "$output_objdir/"
+    tool_output_objdir=$func_to_tool_file_result
     # Create the object directory.
     func_mkdir_p "$output_objdir"
 
@@ -4954,12 +6032,12 @@ func_mode_link ()
     # Find all interdependent deplibs by searching for libraries
     # that are linked more than once (e.g. -la -lb -la)
     for deplib in $deplibs; do
-      if $opt_duplicate_deps ; then
+      if $opt_preserve_dup_deps ; then
 	case "$libs " in
-	*" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
+	*" $deplib "*) func_append specialdeplibs " $deplib" ;;
 	esac
       fi
-      libs="$libs $deplib"
+      func_append libs " $deplib"
     done
 
     if test "$linkmode" = lib; then
@@ -4972,9 +6050,9 @@ func_mode_link ()
       if $opt_duplicate_compiler_generated_deps; then
 	for pre_post_dep in $predeps $postdeps; do
 	  case "$pre_post_deps " in
-	  *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;;
+	  *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;;
 	  esac
-	  pre_post_deps="$pre_post_deps $pre_post_dep"
+	  func_append pre_post_deps " $pre_post_dep"
 	done
       fi
       pre_post_deps=
@@ -5041,17 +6119,19 @@ func_mode_link ()
 	for lib in $dlprefiles; do
 	  # Ignore non-libtool-libs
 	  dependency_libs=
+	  func_resolve_sysroot "$lib"
 	  case $lib in
-	  *.la)	func_source "$lib" ;;
+	  *.la)	func_source "$func_resolve_sysroot_result" ;;
 	  esac
 
 	  # Collect preopened libtool deplibs, except any this library
 	  # has declared as weak libs
 	  for deplib in $dependency_libs; do
-            deplib_base=`$ECHO "X$deplib" | $Xsed -e "$basename"`
+	    func_basename "$deplib"
+            deplib_base=$func_basename_result
 	    case " $weak_libs " in
 	    *" $deplib_base "*) ;;
-	    *) deplibs="$deplibs $deplib" ;;
+	    *) func_append deplibs " $deplib" ;;
 	    esac
 	  done
 	done
@@ -5072,11 +6152,11 @@ func_mode_link ()
 	    compile_deplibs="$deplib $compile_deplibs"
 	    finalize_deplibs="$deplib $finalize_deplibs"
 	  else
-	    compiler_flags="$compiler_flags $deplib"
+	    func_append compiler_flags " $deplib"
 	    if test "$linkmode" = lib ; then
 		case "$new_inherited_linker_flags " in
 		    *" $deplib "*) ;;
-		    * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;;
+		    * ) func_append new_inherited_linker_flags " $deplib" ;;
 		esac
 	    fi
 	  fi
@@ -5161,7 +6241,7 @@ func_mode_link ()
 	    if test "$linkmode" = lib ; then
 		case "$new_inherited_linker_flags " in
 		    *" $deplib "*) ;;
-		    * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;;
+		    * ) func_append new_inherited_linker_flags " $deplib" ;;
 		esac
 	    fi
 	  fi
@@ -5174,7 +6254,8 @@ func_mode_link ()
 	    test "$pass" = conv && continue
 	    newdependency_libs="$deplib $newdependency_libs"
 	    func_stripname '-L' '' "$deplib"
-	    newlib_search_path="$newlib_search_path $func_stripname_result"
+	    func_resolve_sysroot "$func_stripname_result"
+	    func_append newlib_search_path " $func_resolve_sysroot_result"
 	    ;;
 	  prog)
 	    if test "$pass" = conv; then
@@ -5188,7 +6269,8 @@ func_mode_link ()
 	      finalize_deplibs="$deplib $finalize_deplibs"
 	    fi
 	    func_stripname '-L' '' "$deplib"
-	    newlib_search_path="$newlib_search_path $func_stripname_result"
+	    func_resolve_sysroot "$func_stripname_result"
+	    func_append newlib_search_path " $func_resolve_sysroot_result"
 	    ;;
 	  *)
 	    func_warning "\`-L' is ignored for archives/objects"
@@ -5199,17 +6281,21 @@ func_mode_link ()
 	-R*)
 	  if test "$pass" = link; then
 	    func_stripname '-R' '' "$deplib"
-	    dir=$func_stripname_result
+	    func_resolve_sysroot "$func_stripname_result"
+	    dir=$func_resolve_sysroot_result
 	    # Make sure the xrpath contains only unique directories.
 	    case "$xrpath " in
 	    *" $dir "*) ;;
-	    *) xrpath="$xrpath $dir" ;;
+	    *) func_append xrpath " $dir" ;;
 	    esac
 	  fi
 	  deplibs="$deplib $deplibs"
 	  continue
 	  ;;
-	*.la) lib="$deplib" ;;
+	*.la)
+	  func_resolve_sysroot "$deplib"
+	  lib=$func_resolve_sysroot_result
+	  ;;
 	*.$libext)
 	  if test "$pass" = conv; then
 	    deplibs="$deplib $deplibs"
@@ -5227,7 +6313,7 @@ func_mode_link ()
 		match_pattern*)
 		  set dummy $deplibs_check_method; shift
 		  match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
-		  if eval "\$ECHO \"X$deplib\"" 2>/dev/null | $Xsed -e 10q \
+		  if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \
 		    | $EGREP "$match_pattern_regex" > /dev/null; then
 		    valid_a_lib=yes
 		  fi
@@ -5237,15 +6323,15 @@ func_mode_link ()
 		;;
 	      esac
 	      if test "$valid_a_lib" != yes; then
-		$ECHO
+		echo
 		$ECHO "*** Warning: Trying to link with static lib archive $deplib."
-		$ECHO "*** I have the capability to make that library automatically link in when"
-		$ECHO "*** you link to this library.  But I can only do this if you have a"
-		$ECHO "*** shared version of the library, which you do not appear to have"
-		$ECHO "*** because the file extensions .$libext of this argument makes me believe"
-		$ECHO "*** that it is just a static archive that I should not use here."
+		echo "*** I have the capability to make that library automatically link in when"
+		echo "*** you link to this library.  But I can only do this if you have a"
+		echo "*** shared version of the library, which you do not appear to have"
+		echo "*** because the file extensions .$libext of this argument makes me believe"
+		echo "*** that it is just a static archive that I should not use here."
 	      else
-		$ECHO
+		echo
 		$ECHO "*** Warning: Linking the shared library $output against the"
 		$ECHO "*** static library $deplib is not portable!"
 		deplibs="$deplib $deplibs"
@@ -5272,11 +6358,11 @@ func_mode_link ()
 	    if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then
 	      # If there is no dlopen support or we're linking statically,
 	      # we need to preload.
-	      newdlprefiles="$newdlprefiles $deplib"
+	      func_append newdlprefiles " $deplib"
 	      compile_deplibs="$deplib $compile_deplibs"
 	      finalize_deplibs="$deplib $finalize_deplibs"
 	    else
-	      newdlfiles="$newdlfiles $deplib"
+	      func_append newdlfiles " $deplib"
 	    fi
 	  fi
 	  continue
@@ -5318,20 +6404,20 @@ func_mode_link ()
 
 	# Convert "-framework foo" to "foo.ltframework"
 	if test -n "$inherited_linker_flags"; then
-	  tmp_inherited_linker_flags=`$ECHO "X$inherited_linker_flags" | $Xsed -e 's/-framework \([^ $]*\)/\1.ltframework/g'`
+	  tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'`
 	  for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do
 	    case " $new_inherited_linker_flags " in
 	      *" $tmp_inherited_linker_flag "*) ;;
-	      *) new_inherited_linker_flags="$new_inherited_linker_flags $tmp_inherited_linker_flag";;
+	      *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";;
 	    esac
 	  done
 	fi
-	dependency_libs=`$ECHO "X $dependency_libs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
+	dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
 	if test "$linkmode,$pass" = "lib,link" ||
 	   test "$linkmode,$pass" = "prog,scan" ||
 	   { test "$linkmode" != prog && test "$linkmode" != lib; }; then
-	  test -n "$dlopen" && dlfiles="$dlfiles $dlopen"
-	  test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen"
+	  test -n "$dlopen" && func_append dlfiles " $dlopen"
+	  test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen"
 	fi
 
 	if test "$pass" = conv; then
@@ -5342,20 +6428,20 @@ func_mode_link ()
 	      func_fatal_error "cannot find name of link library for \`$lib'"
 	    fi
 	    # It is a libtool convenience library, so add in its objects.
-	    convenience="$convenience $ladir/$objdir/$old_library"
-	    old_convenience="$old_convenience $ladir/$objdir/$old_library"
+	    func_append convenience " $ladir/$objdir/$old_library"
+	    func_append old_convenience " $ladir/$objdir/$old_library"
 	  elif test "$linkmode" != prog && test "$linkmode" != lib; then
 	    func_fatal_error "\`$lib' is not a convenience library"
 	  fi
 	  tmp_libs=
 	  for deplib in $dependency_libs; do
 	    deplibs="$deplib $deplibs"
-	    if $opt_duplicate_deps ; then
+	    if $opt_preserve_dup_deps ; then
 	      case "$tmp_libs " in
-	      *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
+	      *" $deplib "*) func_append specialdeplibs " $deplib" ;;
 	      esac
 	    fi
-	    tmp_libs="$tmp_libs $deplib"
+	    func_append tmp_libs " $deplib"
 	  done
 	  continue
 	fi # $pass = conv
@@ -5363,9 +6449,15 @@ func_mode_link ()
 
 	# Get the name of the library we link against.
 	linklib=
-	for l in $old_library $library_names; do
-	  linklib="$l"
-	done
+	if test -n "$old_library" &&
+	   { test "$prefer_static_libs" = yes ||
+	     test "$prefer_static_libs,$installed" = "built,no"; }; then
+	  linklib=$old_library
+	else
+	  for l in $old_library $library_names; do
+	    linklib="$l"
+	  done
+	fi
 	if test -z "$linklib"; then
 	  func_fatal_error "cannot find name of link library for \`$lib'"
 	fi
@@ -5382,9 +6474,9 @@ func_mode_link ()
 	    # statically, we need to preload.  We also need to preload any
 	    # dependent libraries so libltdl's deplib preloader doesn't
 	    # bomb out in the load deplibs phase.
-	    dlprefiles="$dlprefiles $lib $dependency_libs"
+	    func_append dlprefiles " $lib $dependency_libs"
 	  else
-	    newdlfiles="$newdlfiles $lib"
+	    func_append newdlfiles " $lib"
 	  fi
 	  continue
 	fi # $pass = dlopen
@@ -5406,14 +6498,14 @@ func_mode_link ()
 
 	# Find the relevant object directory and library name.
 	if test "X$installed" = Xyes; then
-	  if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
+	  if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
 	    func_warning "library \`$lib' was moved."
 	    dir="$ladir"
 	    absdir="$abs_ladir"
 	    libdir="$abs_ladir"
 	  else
-	    dir="$libdir"
-	    absdir="$libdir"
+	    dir="$lt_sysroot$libdir"
+	    absdir="$lt_sysroot$libdir"
 	  fi
 	  test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes
 	else
@@ -5421,12 +6513,12 @@ func_mode_link ()
 	    dir="$ladir"
 	    absdir="$abs_ladir"
 	    # Remove this search path later
-	    notinst_path="$notinst_path $abs_ladir"
+	    func_append notinst_path " $abs_ladir"
 	  else
 	    dir="$ladir/$objdir"
 	    absdir="$abs_ladir/$objdir"
 	    # Remove this search path later
-	    notinst_path="$notinst_path $abs_ladir"
+	    func_append notinst_path " $abs_ladir"
 	  fi
 	fi # $installed = yes
 	func_stripname 'lib' '.la' "$laname"
@@ -5437,20 +6529,46 @@ func_mode_link ()
 	  if test -z "$libdir" && test "$linkmode" = prog; then
 	    func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'"
 	  fi
-	  # Prefer using a static library (so that no silly _DYNAMIC symbols
-	  # are required to link).
-	  if test -n "$old_library"; then
-	    newdlprefiles="$newdlprefiles $dir/$old_library"
-	    # Keep a list of preopened convenience libraries to check
-	    # that they are being used correctly in the link pass.
-	    test -z "$libdir" && \
-		dlpreconveniencelibs="$dlpreconveniencelibs $dir/$old_library"
-	  # Otherwise, use the dlname, so that lt_dlopen finds it.
-	  elif test -n "$dlname"; then
-	    newdlprefiles="$newdlprefiles $dir/$dlname"
-	  else
-	    newdlprefiles="$newdlprefiles $dir/$linklib"
-	  fi
+	  case "$host" in
+	    # special handling for platforms with PE-DLLs.
+	    *cygwin* | *mingw* | *cegcc* )
+	      # Linker will automatically link against shared library if both
+	      # static and shared are present.  Therefore, ensure we extract
+	      # symbols from the import library if a shared library is present
+	      # (otherwise, the dlopen module name will be incorrect).  We do
+	      # this by putting the import library name into $newdlprefiles.
+	      # We recover the dlopen module name by 'saving' the la file
+	      # name in a special purpose variable, and (later) extracting the
+	      # dlname from the la file.
+	      if test -n "$dlname"; then
+	        func_tr_sh "$dir/$linklib"
+	        eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname"
+	        func_append newdlprefiles " $dir/$linklib"
+	      else
+	        func_append newdlprefiles " $dir/$old_library"
+	        # Keep a list of preopened convenience libraries to check
+	        # that they are being used correctly in the link pass.
+	        test -z "$libdir" && \
+	          func_append dlpreconveniencelibs " $dir/$old_library"
+	      fi
+	    ;;
+	    * )
+	      # Prefer using a static library (so that no silly _DYNAMIC symbols
+	      # are required to link).
+	      if test -n "$old_library"; then
+	        func_append newdlprefiles " $dir/$old_library"
+	        # Keep a list of preopened convenience libraries to check
+	        # that they are being used correctly in the link pass.
+	        test -z "$libdir" && \
+	          func_append dlpreconveniencelibs " $dir/$old_library"
+	      # Otherwise, use the dlname, so that lt_dlopen finds it.
+	      elif test -n "$dlname"; then
+	        func_append newdlprefiles " $dir/$dlname"
+	      else
+	        func_append newdlprefiles " $dir/$linklib"
+	      fi
+	    ;;
+	  esac
 	fi # $pass = dlpreopen
 
 	if test -z "$libdir"; then
@@ -5468,7 +6586,7 @@ func_mode_link ()
 
 
 	if test "$linkmode" = prog && test "$pass" != link; then
-	  newlib_search_path="$newlib_search_path $ladir"
+	  func_append newlib_search_path " $ladir"
 	  deplibs="$lib $deplibs"
 
 	  linkalldeplibs=no
@@ -5481,7 +6599,8 @@ func_mode_link ()
 	  for deplib in $dependency_libs; do
 	    case $deplib in
 	    -L*) func_stripname '-L' '' "$deplib"
-	         newlib_search_path="$newlib_search_path $func_stripname_result"
+	         func_resolve_sysroot "$func_stripname_result"
+	         func_append newlib_search_path " $func_resolve_sysroot_result"
 		 ;;
 	    esac
 	    # Need to link against all dependency_libs?
@@ -5492,12 +6611,12 @@ func_mode_link ()
 	      # or/and link against static libraries
 	      newdependency_libs="$deplib $newdependency_libs"
 	    fi
-	    if $opt_duplicate_deps ; then
+	    if $opt_preserve_dup_deps ; then
 	      case "$tmp_libs " in
-	      *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
+	      *" $deplib "*) func_append specialdeplibs " $deplib" ;;
 	      esac
 	    fi
-	    tmp_libs="$tmp_libs $deplib"
+	    func_append tmp_libs " $deplib"
 	  done # for deplib
 	  continue
 	fi # $linkmode = prog...
@@ -5512,7 +6631,7 @@ func_mode_link ()
 	      # Make sure the rpath contains only unique directories.
 	      case "$temp_rpath:" in
 	      *"$absdir:"*) ;;
-	      *) temp_rpath="$temp_rpath$absdir:" ;;
+	      *) func_append temp_rpath "$absdir:" ;;
 	      esac
 	    fi
 
@@ -5524,7 +6643,7 @@ func_mode_link ()
 	    *)
 	      case "$compile_rpath " in
 	      *" $absdir "*) ;;
-	      *) compile_rpath="$compile_rpath $absdir"
+	      *) func_append compile_rpath " $absdir" ;;
 	      esac
 	      ;;
 	    esac
@@ -5533,7 +6652,7 @@ func_mode_link ()
 	    *)
 	      case "$finalize_rpath " in
 	      *" $libdir "*) ;;
-	      *) finalize_rpath="$finalize_rpath $libdir"
+	      *) func_append finalize_rpath " $libdir" ;;
 	      esac
 	      ;;
 	    esac
@@ -5558,12 +6677,12 @@ func_mode_link ()
 	  case $host in
 	  *cygwin* | *mingw* | *cegcc*)
 	      # No point in relinking DLLs because paths are not encoded
-	      notinst_deplibs="$notinst_deplibs $lib"
+	      func_append notinst_deplibs " $lib"
 	      need_relink=no
 	    ;;
 	  *)
 	    if test "$installed" = no; then
-	      notinst_deplibs="$notinst_deplibs $lib"
+	      func_append notinst_deplibs " $lib"
 	      need_relink=yes
 	    fi
 	    ;;
@@ -5580,7 +6699,7 @@ func_mode_link ()
 	    fi
 	  done
 	  if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then
-	    $ECHO
+	    echo
 	    if test "$linkmode" = prog; then
 	      $ECHO "*** Warning: Linking the executable $output against the loadable module"
 	    else
@@ -5598,7 +6717,7 @@ func_mode_link ()
 	    *)
 	      case "$compile_rpath " in
 	      *" $absdir "*) ;;
-	      *) compile_rpath="$compile_rpath $absdir"
+	      *) func_append compile_rpath " $absdir" ;;
 	      esac
 	      ;;
 	    esac
@@ -5607,7 +6726,7 @@ func_mode_link ()
 	    *)
 	      case "$finalize_rpath " in
 	      *" $libdir "*) ;;
-	      *) finalize_rpath="$finalize_rpath $libdir"
+	      *) func_append finalize_rpath " $libdir" ;;
 	      esac
 	      ;;
 	    esac
@@ -5661,7 +6780,7 @@ func_mode_link ()
 	    linklib=$newlib
 	  fi # test -n "$old_archive_from_expsyms_cmds"
 
-	  if test "$linkmode" = prog || test "$mode" != relink; then
+	  if test "$linkmode" = prog || test "$opt_mode" != relink; then
 	    add_shlibpath=
 	    add_dir=
 	    add=
@@ -5683,9 +6802,9 @@ func_mode_link ()
 		      if test "X$dlopenmodule" != "X$lib"; then
 			$ECHO "*** Warning: lib $linklib is a module, not a shared library"
 			if test -z "$old_library" ; then
-			  $ECHO
-			  $ECHO "*** And there doesn't seem to be a static archive available"
-			  $ECHO "*** The link will probably fail, sorry"
+			  echo
+			  echo "*** And there doesn't seem to be a static archive available"
+			  echo "*** The link will probably fail, sorry"
 			else
 			  add="$dir/$old_library"
 			fi
@@ -5717,7 +6836,7 @@ func_mode_link ()
 		if test -n "$inst_prefix_dir"; then
 		  case $libdir in
 		    [\\/]*)
-		      add_dir="$add_dir -L$inst_prefix_dir$libdir"
+		      func_append add_dir " -L$inst_prefix_dir$libdir"
 		      ;;
 		  esac
 		fi
@@ -5739,7 +6858,7 @@ func_mode_link ()
 	    if test -n "$add_shlibpath"; then
 	      case :$compile_shlibpath: in
 	      *":$add_shlibpath:"*) ;;
-	      *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;;
+	      *) func_append compile_shlibpath "$add_shlibpath:" ;;
 	      esac
 	    fi
 	    if test "$linkmode" = prog; then
@@ -5753,13 +6872,13 @@ func_mode_link ()
 		 test "$hardcode_shlibpath_var" = yes; then
 		case :$finalize_shlibpath: in
 		*":$libdir:"*) ;;
-		*) finalize_shlibpath="$finalize_shlibpath$libdir:" ;;
+		*) func_append finalize_shlibpath "$libdir:" ;;
 		esac
 	      fi
 	    fi
 	  fi
 
-	  if test "$linkmode" = prog || test "$mode" = relink; then
+	  if test "$linkmode" = prog || test "$opt_mode" = relink; then
 	    add_shlibpath=
 	    add_dir=
 	    add=
@@ -5773,7 +6892,7 @@ func_mode_link ()
 	    elif test "$hardcode_shlibpath_var" = yes; then
 	      case :$finalize_shlibpath: in
 	      *":$libdir:"*) ;;
-	      *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;;
+	      *) func_append finalize_shlibpath "$libdir:" ;;
 	      esac
 	      add="-l$name"
 	    elif test "$hardcode_automatic" = yes; then
@@ -5790,7 +6909,7 @@ func_mode_link ()
 	      if test -n "$inst_prefix_dir"; then
 		case $libdir in
 		  [\\/]*)
-		    add_dir="$add_dir -L$inst_prefix_dir$libdir"
+		    func_append add_dir " -L$inst_prefix_dir$libdir"
 		    ;;
 		esac
 	      fi
@@ -5825,21 +6944,21 @@ func_mode_link ()
 
 	    # Just print a warning and add the library to dependency_libs so
 	    # that the program can be linked against the static library.
-	    $ECHO
+	    echo
 	    $ECHO "*** Warning: This system can not link to static lib archive $lib."
-	    $ECHO "*** I have the capability to make that library automatically link in when"
-	    $ECHO "*** you link to this library.  But I can only do this if you have a"
-	    $ECHO "*** shared version of the library, which you do not appear to have."
+	    echo "*** I have the capability to make that library automatically link in when"
+	    echo "*** you link to this library.  But I can only do this if you have a"
+	    echo "*** shared version of the library, which you do not appear to have."
 	    if test "$module" = yes; then
-	      $ECHO "*** But as you try to build a module library, libtool will still create "
-	      $ECHO "*** a static module, that should work as long as the dlopening application"
-	      $ECHO "*** is linked with the -dlopen flag to resolve symbols at runtime."
+	      echo "*** But as you try to build a module library, libtool will still create "
+	      echo "*** a static module, that should work as long as the dlopening application"
+	      echo "*** is linked with the -dlopen flag to resolve symbols at runtime."
 	      if test -z "$global_symbol_pipe"; then
-		$ECHO
-		$ECHO "*** However, this would only work if libtool was able to extract symbol"
-		$ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could"
-		$ECHO "*** not find such a program.  So, this module is probably useless."
-		$ECHO "*** \`nm' from GNU binutils and a full rebuild may help."
+		echo
+		echo "*** However, this would only work if libtool was able to extract symbol"
+		echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
+		echo "*** not find such a program.  So, this module is probably useless."
+		echo "*** \`nm' from GNU binutils and a full rebuild may help."
 	      fi
 	      if test "$build_old_libs" = no; then
 		build_libtool_libs=module
@@ -5867,37 +6986,46 @@ func_mode_link ()
 	           temp_xrpath=$func_stripname_result
 		   case " $xrpath " in
 		   *" $temp_xrpath "*) ;;
-		   *) xrpath="$xrpath $temp_xrpath";;
+		   *) func_append xrpath " $temp_xrpath";;
 		   esac;;
-	      *) temp_deplibs="$temp_deplibs $libdir";;
+	      *) func_append temp_deplibs " $libdir";;
 	      esac
 	    done
 	    dependency_libs="$temp_deplibs"
 	  fi
 
-	  newlib_search_path="$newlib_search_path $absdir"
+	  func_append newlib_search_path " $absdir"
 	  # Link against this library
 	  test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs"
 	  # ... and its dependency_libs
 	  tmp_libs=
 	  for deplib in $dependency_libs; do
 	    newdependency_libs="$deplib $newdependency_libs"
-	    if $opt_duplicate_deps ; then
+	    case $deplib in
+              -L*) func_stripname '-L' '' "$deplib"
+                   func_resolve_sysroot "$func_stripname_result";;
+              *) func_resolve_sysroot "$deplib" ;;
+            esac
+	    if $opt_preserve_dup_deps ; then
 	      case "$tmp_libs " in
-	      *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
+	      *" $func_resolve_sysroot_result "*)
+                func_append specialdeplibs " $func_resolve_sysroot_result" ;;
 	      esac
 	    fi
-	    tmp_libs="$tmp_libs $deplib"
+	    func_append tmp_libs " $func_resolve_sysroot_result"
 	  done
 
 	  if test "$link_all_deplibs" != no; then
 	    # Add the search paths of all dependency libraries
 	    for deplib in $dependency_libs; do
+	      path=
 	      case $deplib in
 	      -L*) path="$deplib" ;;
 	      *.la)
+	        func_resolve_sysroot "$deplib"
+	        deplib=$func_resolve_sysroot_result
 	        func_dirname "$deplib" "" "."
-		dir="$func_dirname_result"
+		dir=$func_dirname_result
 		# We need an absolute path.
 		case $dir in
 		[\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;;
@@ -5924,8 +7052,8 @@ func_mode_link ()
                       if test -z "$darwin_install_name"; then
                           darwin_install_name=`${OTOOL64} -L $depdepl  | awk '{if (NR == 2) {print $1;exit}}'`
                       fi
-		      compiler_flags="$compiler_flags ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
-		      linker_flags="$linker_flags -dylib_file ${darwin_install_name}:${depdepl}"
+		      func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
+		      func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}"
 		      path=
 		    fi
 		  fi
@@ -5958,7 +7086,7 @@ func_mode_link ()
 	  compile_deplibs="$new_inherited_linker_flags $compile_deplibs"
 	  finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs"
 	else
-	  compiler_flags="$compiler_flags "`$ECHO "X $new_inherited_linker_flags" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
+	  compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
 	fi
       fi
       dependency_libs="$newdependency_libs"
@@ -5975,7 +7103,7 @@ func_mode_link ()
 	  for dir in $newlib_search_path; do
 	    case "$lib_search_path " in
 	    *" $dir "*) ;;
-	    *) lib_search_path="$lib_search_path $dir" ;;
+	    *) func_append lib_search_path " $dir" ;;
 	    esac
 	  done
 	  newlib_search_path=
@@ -6033,10 +7161,10 @@ func_mode_link ()
 	    -L*)
 	      case " $tmp_libs " in
 	      *" $deplib "*) ;;
-	      *) tmp_libs="$tmp_libs $deplib" ;;
+	      *) func_append tmp_libs " $deplib" ;;
 	      esac
 	      ;;
-	    *) tmp_libs="$tmp_libs $deplib" ;;
+	    *) func_append tmp_libs " $deplib" ;;
 	    esac
 	  done
 	  eval $var=\"$tmp_libs\"
@@ -6052,7 +7180,7 @@ func_mode_link ()
 	  ;;
 	esac
 	if test -n "$i" ; then
-	  tmp_libs="$tmp_libs $i"
+	  func_append tmp_libs " $i"
 	fi
       done
       dependency_libs=$tmp_libs
@@ -6093,7 +7221,7 @@ func_mode_link ()
       # Now set the variables for building old libraries.
       build_libtool_libs=no
       oldlibs="$output"
-      objs="$objs$old_deplibs"
+      func_append objs "$old_deplibs"
       ;;
 
     lib)
@@ -6126,10 +7254,10 @@ func_mode_link ()
 	if test "$deplibs_check_method" != pass_all; then
 	  func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs"
 	else
-	  $ECHO
+	  echo
 	  $ECHO "*** Warning: Linking the shared library $output against the non-libtool"
 	  $ECHO "*** objects $objs is not portable!"
-	  libobjs="$libobjs $objs"
+	  func_append libobjs " $objs"
 	fi
       fi
 
@@ -6194,7 +7322,7 @@ func_mode_link ()
 	    age="$number_minor"
 	    revision="$number_revision"
 	    ;;
-	  freebsd-aout|freebsd-elf|sunos)
+	  freebsd-aout|freebsd-elf|qnx|sunos)
 	    current="$number_major"
 	    revision="$number_minor"
 	    age="0"
@@ -6327,7 +7455,7 @@ func_mode_link ()
 	  done
 
 	  # Make executables depend on our current version.
-	  verstring="$verstring:${current}.0"
+	  func_append verstring ":${current}.0"
 	  ;;
 
 	qnx)
@@ -6395,10 +7523,10 @@ func_mode_link ()
       fi
 
       func_generate_dlsyms "$libname" "$libname" "yes"
-      libobjs="$libobjs $symfileobj"
+      func_append libobjs " $symfileobj"
       test "X$libobjs" = "X " && libobjs=
 
-      if test "$mode" != relink; then
+      if test "$opt_mode" != relink; then
 	# Remove our outputs, but don't remove object files since they
 	# may have been created when compiling PIC objects.
 	removelist=
@@ -6414,7 +7542,7 @@ func_mode_link ()
 		   continue
 		 fi
 	       fi
-	       removelist="$removelist $p"
+	       func_append removelist " $p"
 	       ;;
 	    *) ;;
 	  esac
@@ -6425,27 +7553,28 @@ func_mode_link ()
 
       # Now set the variables for building old libraries.
       if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then
-	oldlibs="$oldlibs $output_objdir/$libname.$libext"
+	func_append oldlibs " $output_objdir/$libname.$libext"
 
 	# Transform .lo files to .o files.
-	oldobjs="$objs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP`
+	oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP`
       fi
 
       # Eliminate all temporary directories.
       #for path in $notinst_path; do
-      #	lib_search_path=`$ECHO "X$lib_search_path " | $Xsed -e "s% $path % %g"`
-      #	deplibs=`$ECHO "X$deplibs " | $Xsed -e "s% -L$path % %g"`
-      #	dependency_libs=`$ECHO "X$dependency_libs " | $Xsed -e "s% -L$path % %g"`
+      #	lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"`
+      #	deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"`
+      #	dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"`
       #done
 
       if test -n "$xrpath"; then
 	# If the user specified any rpath flags, then add them.
 	temp_xrpath=
 	for libdir in $xrpath; do
-	  temp_xrpath="$temp_xrpath -R$libdir"
+	  func_replace_sysroot "$libdir"
+	  func_append temp_xrpath " -R$func_replace_sysroot_result"
 	  case "$finalize_rpath " in
 	  *" $libdir "*) ;;
-	  *) finalize_rpath="$finalize_rpath $libdir" ;;
+	  *) func_append finalize_rpath " $libdir" ;;
 	  esac
 	done
 	if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then
@@ -6459,7 +7588,7 @@ func_mode_link ()
       for lib in $old_dlfiles; do
 	case " $dlprefiles $dlfiles " in
 	*" $lib "*) ;;
-	*) dlfiles="$dlfiles $lib" ;;
+	*) func_append dlfiles " $lib" ;;
 	esac
       done
 
@@ -6469,19 +7598,19 @@ func_mode_link ()
       for lib in $old_dlprefiles; do
 	case "$dlprefiles " in
 	*" $lib "*) ;;
-	*) dlprefiles="$dlprefiles $lib" ;;
+	*) func_append dlprefiles " $lib" ;;
 	esac
       done
 
       if test "$build_libtool_libs" = yes; then
 	if test -n "$rpath"; then
 	  case $host in
-	  *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc*)
+	  *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*)
 	    # these systems don't actually have a c library (as such)!
 	    ;;
 	  *-*-rhapsody* | *-*-darwin1.[012])
 	    # Rhapsody C library is in the System framework
-	    deplibs="$deplibs System.ltframework"
+	    func_append deplibs " System.ltframework"
 	    ;;
 	  *-*-netbsd*)
 	    # Don't link with libc until the a.out ld.so is fixed.
@@ -6498,7 +7627,7 @@ func_mode_link ()
 	  *)
 	    # Add libc to deplibs on all other systems if necessary.
 	    if test "$build_libtool_need_lc" = "yes"; then
-	      deplibs="$deplibs -lc"
+	      func_append deplibs " -lc"
 	    fi
 	    ;;
 	  esac
@@ -6547,7 +7676,7 @@ EOF
 		if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
 		  case " $predeps $postdeps " in
 		  *" $i "*)
-		    newdeplibs="$newdeplibs $i"
+		    func_append newdeplibs " $i"
 		    i=""
 		    ;;
 		  esac
@@ -6558,21 +7687,21 @@ EOF
 		  set dummy $deplib_matches; shift
 		  deplib_match=$1
 		  if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
-		    newdeplibs="$newdeplibs $i"
+		    func_append newdeplibs " $i"
 		  else
 		    droppeddeps=yes
-		    $ECHO
+		    echo
 		    $ECHO "*** Warning: dynamic linker does not accept needed library $i."
-		    $ECHO "*** I have the capability to make that library automatically link in when"
-		    $ECHO "*** you link to this library.  But I can only do this if you have a"
-		    $ECHO "*** shared version of the library, which I believe you do not have"
-		    $ECHO "*** because a test_compile did reveal that the linker did not use it for"
-		    $ECHO "*** its dynamic dependency list that programs get resolved with at runtime."
+		    echo "*** I have the capability to make that library automatically link in when"
+		    echo "*** you link to this library.  But I can only do this if you have a"
+		    echo "*** shared version of the library, which I believe you do not have"
+		    echo "*** because a test_compile did reveal that the linker did not use it for"
+		    echo "*** its dynamic dependency list that programs get resolved with at runtime."
 		  fi
 		fi
 		;;
 	      *)
-		newdeplibs="$newdeplibs $i"
+		func_append newdeplibs " $i"
 		;;
 	      esac
 	    done
@@ -6590,7 +7719,7 @@ EOF
 		  if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
 		    case " $predeps $postdeps " in
 		    *" $i "*)
-		      newdeplibs="$newdeplibs $i"
+		      func_append newdeplibs " $i"
 		      i=""
 		      ;;
 		    esac
@@ -6601,29 +7730,29 @@ EOF
 		    set dummy $deplib_matches; shift
 		    deplib_match=$1
 		    if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
-		      newdeplibs="$newdeplibs $i"
+		      func_append newdeplibs " $i"
 		    else
 		      droppeddeps=yes
-		      $ECHO
+		      echo
 		      $ECHO "*** Warning: dynamic linker does not accept needed library $i."
-		      $ECHO "*** I have the capability to make that library automatically link in when"
-		      $ECHO "*** you link to this library.  But I can only do this if you have a"
-		      $ECHO "*** shared version of the library, which you do not appear to have"
-		      $ECHO "*** because a test_compile did reveal that the linker did not use this one"
-		      $ECHO "*** as a dynamic dependency that programs can get resolved with at runtime."
+		      echo "*** I have the capability to make that library automatically link in when"
+		      echo "*** you link to this library.  But I can only do this if you have a"
+		      echo "*** shared version of the library, which you do not appear to have"
+		      echo "*** because a test_compile did reveal that the linker did not use this one"
+		      echo "*** as a dynamic dependency that programs can get resolved with at runtime."
 		    fi
 		  fi
 		else
 		  droppeddeps=yes
-		  $ECHO
+		  echo
 		  $ECHO "*** Warning!  Library $i is needed by this library but I was not able to"
-		  $ECHO "*** make it link in!  You will probably need to install it or some"
-		  $ECHO "*** library that it depends on before this library will be fully"
-		  $ECHO "*** functional.  Installing it before continuing would be even better."
+		  echo "*** make it link in!  You will probably need to install it or some"
+		  echo "*** library that it depends on before this library will be fully"
+		  echo "*** functional.  Installing it before continuing would be even better."
 		fi
 		;;
 	      *)
-		newdeplibs="$newdeplibs $i"
+		func_append newdeplibs " $i"
 		;;
 	      esac
 	    done
@@ -6640,15 +7769,27 @@ EOF
 	      if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
 		case " $predeps $postdeps " in
 		*" $a_deplib "*)
-		  newdeplibs="$newdeplibs $a_deplib"
+		  func_append newdeplibs " $a_deplib"
 		  a_deplib=""
 		  ;;
 		esac
 	      fi
 	      if test -n "$a_deplib" ; then
 		libname=`eval "\\$ECHO \"$libname_spec\""`
+		if test -n "$file_magic_glob"; then
+		  libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob`
+		else
+		  libnameglob=$libname
+		fi
+		test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob`
 		for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
-		  potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
+		  if test "$want_nocaseglob" = yes; then
+		    shopt -s nocaseglob
+		    potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
+		    $nocaseglob
+		  else
+		    potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
+		  fi
 		  for potent_lib in $potential_libs; do
 		      # Follow soft links.
 		      if ls -lLd "$potent_lib" 2>/dev/null |
@@ -6665,13 +7806,13 @@ EOF
 			potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'`
 			case $potliblink in
 			[\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";;
-			*) potlib=`$ECHO "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";;
+			*) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";;
 			esac
 		      done
 		      if eval $file_magic_cmd \"\$potlib\" 2>/dev/null |
 			 $SED -e 10q |
 			 $EGREP "$file_magic_regex" > /dev/null; then
-			newdeplibs="$newdeplibs $a_deplib"
+			func_append newdeplibs " $a_deplib"
 			a_deplib=""
 			break 2
 		      fi
@@ -6680,12 +7821,12 @@ EOF
 	      fi
 	      if test -n "$a_deplib" ; then
 		droppeddeps=yes
-		$ECHO
+		echo
 		$ECHO "*** Warning: linker path does not have real file for library $a_deplib."
-		$ECHO "*** I have the capability to make that library automatically link in when"
-		$ECHO "*** you link to this library.  But I can only do this if you have a"
-		$ECHO "*** shared version of the library, which you do not appear to have"
-		$ECHO "*** because I did check the linker path looking for a file starting"
+		echo "*** I have the capability to make that library automatically link in when"
+		echo "*** you link to this library.  But I can only do this if you have a"
+		echo "*** shared version of the library, which you do not appear to have"
+		echo "*** because I did check the linker path looking for a file starting"
 		if test -z "$potlib" ; then
 		  $ECHO "*** with $libname but no candidates were found. (...for file magic test)"
 		else
@@ -6696,7 +7837,7 @@ EOF
 	      ;;
 	    *)
 	      # Add a -L argument.
-	      newdeplibs="$newdeplibs $a_deplib"
+	      func_append newdeplibs " $a_deplib"
 	      ;;
 	    esac
 	  done # Gone through all deplibs.
@@ -6712,7 +7853,7 @@ EOF
 	      if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
 		case " $predeps $postdeps " in
 		*" $a_deplib "*)
-		  newdeplibs="$newdeplibs $a_deplib"
+		  func_append newdeplibs " $a_deplib"
 		  a_deplib=""
 		  ;;
 		esac
@@ -6723,9 +7864,9 @@ EOF
 		  potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
 		  for potent_lib in $potential_libs; do
 		    potlib="$potent_lib" # see symlink-check above in file_magic test
-		    if eval "\$ECHO \"X$potent_lib\"" 2>/dev/null | $Xsed -e 10q | \
+		    if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \
 		       $EGREP "$match_pattern_regex" > /dev/null; then
-		      newdeplibs="$newdeplibs $a_deplib"
+		      func_append newdeplibs " $a_deplib"
 		      a_deplib=""
 		      break 2
 		    fi
@@ -6734,12 +7875,12 @@ EOF
 	      fi
 	      if test -n "$a_deplib" ; then
 		droppeddeps=yes
-		$ECHO
+		echo
 		$ECHO "*** Warning: linker path does not have real file for library $a_deplib."
-		$ECHO "*** I have the capability to make that library automatically link in when"
-		$ECHO "*** you link to this library.  But I can only do this if you have a"
-		$ECHO "*** shared version of the library, which you do not appear to have"
-		$ECHO "*** because I did check the linker path looking for a file starting"
+		echo "*** I have the capability to make that library automatically link in when"
+		echo "*** you link to this library.  But I can only do this if you have a"
+		echo "*** shared version of the library, which you do not appear to have"
+		echo "*** because I did check the linker path looking for a file starting"
 		if test -z "$potlib" ; then
 		  $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)"
 		else
@@ -6750,32 +7891,32 @@ EOF
 	      ;;
 	    *)
 	      # Add a -L argument.
-	      newdeplibs="$newdeplibs $a_deplib"
+	      func_append newdeplibs " $a_deplib"
 	      ;;
 	    esac
 	  done # Gone through all deplibs.
 	  ;;
 	none | unknown | *)
 	  newdeplibs=""
-	  tmp_deplibs=`$ECHO "X $deplibs" | $Xsed \
-	      -e 's/ -lc$//' -e 's/ -[LR][^ ]*//g'`
+	  tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'`
 	  if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
 	    for i in $predeps $postdeps ; do
 	      # can't use Xsed below, because $i might contain '/'
-	      tmp_deplibs=`$ECHO "X $tmp_deplibs" | $Xsed -e "s,$i,,"`
+	      tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"`
 	    done
 	  fi
-	  if $ECHO "X $tmp_deplibs" | $Xsed -e 's/[	 ]//g' |
-	     $GREP . >/dev/null; then
-	    $ECHO
+	  case $tmp_deplibs in
+	  *[!\	\ ]*)
+	    echo
 	    if test "X$deplibs_check_method" = "Xnone"; then
-	      $ECHO "*** Warning: inter-library dependencies are not supported in this platform."
+	      echo "*** Warning: inter-library dependencies are not supported in this platform."
 	    else
-	      $ECHO "*** Warning: inter-library dependencies are not known to be supported."
+	      echo "*** Warning: inter-library dependencies are not known to be supported."
 	    fi
-	    $ECHO "*** All declared inter-library dependencies are being dropped."
+	    echo "*** All declared inter-library dependencies are being dropped."
 	    droppeddeps=yes
-	  fi
+	    ;;
+	  esac
 	  ;;
 	esac
 	versuffix=$versuffix_save
@@ -6787,23 +7928,23 @@ EOF
 	case $host in
 	*-*-rhapsody* | *-*-darwin1.[012])
 	  # On Rhapsody replace the C library with the System framework
-	  newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
+	  newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'`
 	  ;;
 	esac
 
 	if test "$droppeddeps" = yes; then
 	  if test "$module" = yes; then
-	    $ECHO
-	    $ECHO "*** Warning: libtool could not satisfy all declared inter-library"
+	    echo
+	    echo "*** Warning: libtool could not satisfy all declared inter-library"
 	    $ECHO "*** dependencies of module $libname.  Therefore, libtool will create"
-	    $ECHO "*** a static module, that should work as long as the dlopening"
-	    $ECHO "*** application is linked with the -dlopen flag."
+	    echo "*** a static module, that should work as long as the dlopening"
+	    echo "*** application is linked with the -dlopen flag."
 	    if test -z "$global_symbol_pipe"; then
-	      $ECHO
-	      $ECHO "*** However, this would only work if libtool was able to extract symbol"
-	      $ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could"
-	      $ECHO "*** not find such a program.  So, this module is probably useless."
-	      $ECHO "*** \`nm' from GNU binutils and a full rebuild may help."
+	      echo
+	      echo "*** However, this would only work if libtool was able to extract symbol"
+	      echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
+	      echo "*** not find such a program.  So, this module is probably useless."
+	      echo "*** \`nm' from GNU binutils and a full rebuild may help."
 	    fi
 	    if test "$build_old_libs" = no; then
 	      oldlibs="$output_objdir/$libname.$libext"
@@ -6813,16 +7954,16 @@ EOF
 	      build_libtool_libs=no
 	    fi
 	  else
-	    $ECHO "*** The inter-library dependencies that have been dropped here will be"
-	    $ECHO "*** automatically added whenever a program is linked with this library"
-	    $ECHO "*** or is declared to -dlopen it."
+	    echo "*** The inter-library dependencies that have been dropped here will be"
+	    echo "*** automatically added whenever a program is linked with this library"
+	    echo "*** or is declared to -dlopen it."
 
 	    if test "$allow_undefined" = no; then
-	      $ECHO
-	      $ECHO "*** Since this library must not contain undefined symbols,"
-	      $ECHO "*** because either the platform does not support them or"
-	      $ECHO "*** it was explicitly requested with -no-undefined,"
-	      $ECHO "*** libtool will only create a static version of it."
+	      echo
+	      echo "*** Since this library must not contain undefined symbols,"
+	      echo "*** because either the platform does not support them or"
+	      echo "*** it was explicitly requested with -no-undefined,"
+	      echo "*** libtool will only create a static version of it."
 	      if test "$build_old_libs" = no; then
 		oldlibs="$output_objdir/$libname.$libext"
 		build_libtool_libs=module
@@ -6839,9 +7980,9 @@ EOF
       # Time to change all our "foo.ltframework" stuff back to "-framework foo"
       case $host in
 	*-*-darwin*)
-	  newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
-	  new_inherited_linker_flags=`$ECHO "X $new_inherited_linker_flags" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
-	  deplibs=`$ECHO "X $deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
+	  newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
+	  new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
+	  deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
 	  ;;
       esac
 
@@ -6854,7 +7995,7 @@ EOF
 	*)
 	  case " $deplibs " in
 	  *" -L$path/$objdir "*)
-	    new_libs="$new_libs -L$path/$objdir" ;;
+	    func_append new_libs " -L$path/$objdir" ;;
 	  esac
 	  ;;
 	esac
@@ -6864,10 +8005,10 @@ EOF
 	-L*)
 	  case " $new_libs " in
 	  *" $deplib "*) ;;
-	  *) new_libs="$new_libs $deplib" ;;
+	  *) func_append new_libs " $deplib" ;;
 	  esac
 	  ;;
-	*) new_libs="$new_libs $deplib" ;;
+	*) func_append new_libs " $deplib" ;;
 	esac
       done
       deplibs="$new_libs"
@@ -6884,10 +8025,12 @@ EOF
 	  hardcode_libdirs=
 	  dep_rpath=
 	  rpath="$finalize_rpath"
-	  test "$mode" != relink && rpath="$compile_rpath$rpath"
+	  test "$opt_mode" != relink && rpath="$compile_rpath$rpath"
 	  for libdir in $rpath; do
 	    if test -n "$hardcode_libdir_flag_spec"; then
 	      if test -n "$hardcode_libdir_separator"; then
+		func_replace_sysroot "$libdir"
+		libdir=$func_replace_sysroot_result
 		if test -z "$hardcode_libdirs"; then
 		  hardcode_libdirs="$libdir"
 		else
@@ -6896,18 +8039,18 @@ EOF
 		  *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
 		    ;;
 		  *)
-		    hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
+		    func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
 		    ;;
 		  esac
 		fi
 	      else
 		eval flag=\"$hardcode_libdir_flag_spec\"
-		dep_rpath="$dep_rpath $flag"
+		func_append dep_rpath " $flag"
 	      fi
 	    elif test -n "$runpath_var"; then
 	      case "$perm_rpath " in
 	      *" $libdir "*) ;;
-	      *) perm_rpath="$perm_rpath $libdir" ;;
+	      *) func_apped perm_rpath " $libdir" ;;
 	      esac
 	    fi
 	  done
@@ -6925,7 +8068,7 @@ EOF
 	    # We should set the runpath_var.
 	    rpath=
 	    for dir in $perm_rpath; do
-	      rpath="$rpath$dir:"
+	      func_append rpath "$dir:"
 	    done
 	    eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var"
 	  fi
@@ -6933,7 +8076,7 @@ EOF
 	fi
 
 	shlibpath="$finalize_shlibpath"
-	test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
+	test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
 	if test -n "$shlibpath"; then
 	  eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var"
 	fi
@@ -6959,18 +8102,18 @@ EOF
 	linknames=
 	for link
 	do
-	  linknames="$linknames $link"
+	  func_append linknames " $link"
 	done
 
 	# Use standard objects if they are pic
-	test -z "$pic_flag" && libobjs=`$ECHO "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
+	test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP`
 	test "X$libobjs" = "X " && libobjs=
 
 	delfiles=
 	if test -n "$export_symbols" && test -n "$include_expsyms"; then
 	  $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp"
 	  export_symbols="$output_objdir/$libname.uexp"
-	  delfiles="$delfiles $export_symbols"
+	  func_append delfiles " $export_symbols"
 	fi
 
 	orig_export_symbols=
@@ -7001,13 +8144,45 @@ EOF
 	    $opt_dry_run || $RM $export_symbols
 	    cmds=$export_symbols_cmds
 	    save_ifs="$IFS"; IFS='~'
-	    for cmd in $cmds; do
+	    for cmd1 in $cmds; do
 	      IFS="$save_ifs"
-	      eval cmd=\"$cmd\"
-	      func_len " $cmd"
-	      len=$func_len_result
-	      if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
+	      # Take the normal branch if the nm_file_list_spec branch
+	      # doesn't work or if tool conversion is not needed.
+	      case $nm_file_list_spec~$to_tool_file_cmd in
+		*~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*)
+		  try_normal_branch=yes
+		  eval cmd=\"$cmd1\"
+		  func_len " $cmd"
+		  len=$func_len_result
+		  ;;
+		*)
+		  try_normal_branch=no
+		  ;;
+	      esac
+	      if test "$try_normal_branch" = yes \
+		 && { test "$len" -lt "$max_cmd_len" \
+		      || test "$max_cmd_len" -le -1; }
+	      then
+		func_show_eval "$cmd" 'exit $?'
+		skipped_export=false
+	      elif test -n "$nm_file_list_spec"; then
+		func_basename "$output"
+		output_la=$func_basename_result
+		save_libobjs=$libobjs
+		save_output=$output
+		output=${output_objdir}/${output_la}.nm
+		func_to_tool_file "$output"
+		libobjs=$nm_file_list_spec$func_to_tool_file_result
+		func_append delfiles " $output"
+		func_verbose "creating $NM input file list: $output"
+		for obj in $save_libobjs; do
+		  func_to_tool_file "$obj"
+		  $ECHO "$func_to_tool_file_result"
+		done > "$output"
+		eval cmd=\"$cmd1\"
 		func_show_eval "$cmd" 'exit $?'
+		output=$save_output
+		libobjs=$save_libobjs
 		skipped_export=false
 	      else
 		# The command line is too long to execute in one step.
@@ -7029,7 +8204,7 @@ EOF
 	if test -n "$export_symbols" && test -n "$include_expsyms"; then
 	  tmp_export_symbols="$export_symbols"
 	  test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
-	  $opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"'
+	  $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
 	fi
 
 	if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then
@@ -7041,7 +8216,7 @@ EOF
 	  # global variables. join(1) would be nice here, but unfortunately
 	  # isn't a blessed tool.
 	  $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
-	  delfiles="$delfiles $export_symbols $output_objdir/$libname.filter"
+	  func_append delfiles " $export_symbols $output_objdir/$libname.filter"
 	  export_symbols=$output_objdir/$libname.def
 	  $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
 	fi
@@ -7051,7 +8226,7 @@ EOF
 	  case " $convenience " in
 	  *" $test_deplib "*) ;;
 	  *)
-	    tmp_deplibs="$tmp_deplibs $test_deplib"
+	    func_append tmp_deplibs " $test_deplib"
 	    ;;
 	  esac
 	done
@@ -7071,21 +8246,21 @@ EOF
 	    test "X$libobjs" = "X " && libobjs=
 	  else
 	    gentop="$output_objdir/${outputname}x"
-	    generated="$generated $gentop"
+	    func_append generated " $gentop"
 
 	    func_extract_archives $gentop $convenience
-	    libobjs="$libobjs $func_extract_archives_result"
+	    func_append libobjs " $func_extract_archives_result"
 	    test "X$libobjs" = "X " && libobjs=
 	  fi
 	fi
 
 	if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then
 	  eval flag=\"$thread_safe_flag_spec\"
-	  linker_flags="$linker_flags $flag"
+	  func_append linker_flags " $flag"
 	fi
 
 	# Make a backup of the uninstalled library when relinking
-	if test "$mode" = relink; then
+	if test "$opt_mode" = relink; then
 	  $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $?
 	fi
 
@@ -7130,7 +8305,8 @@ EOF
 	    save_libobjs=$libobjs
 	  fi
 	  save_output=$output
-	  output_la=`$ECHO "X$output" | $Xsed -e "$basename"`
+	  func_basename "$output"
+	  output_la=$func_basename_result
 
 	  # Clear the reloadable object creation command queue and
 	  # initialize k to one.
@@ -7143,13 +8319,16 @@ EOF
 	  if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then
 	    output=${output_objdir}/${output_la}.lnkscript
 	    func_verbose "creating GNU ld script: $output"
-	    $ECHO 'INPUT (' > $output
+	    echo 'INPUT (' > $output
 	    for obj in $save_libobjs
 	    do
-	      $ECHO "$obj" >> $output
+	      func_to_tool_file "$obj"
+	      $ECHO "$func_to_tool_file_result" >> $output
 	    done
-	    $ECHO ')' >> $output
-	    delfiles="$delfiles $output"
+	    echo ')' >> $output
+	    func_append delfiles " $output"
+	    func_to_tool_file "$output"
+	    output=$func_to_tool_file_result
 	  elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then
 	    output=${output_objdir}/${output_la}.lnk
 	    func_verbose "creating linker input file list: $output"
@@ -7163,10 +8342,12 @@ EOF
 	    fi
 	    for obj
 	    do
-	      $ECHO "$obj" >> $output
+	      func_to_tool_file "$obj"
+	      $ECHO "$func_to_tool_file_result" >> $output
 	    done
-	    delfiles="$delfiles $output"
-	    output=$firstobj\"$file_list_spec$output\"
+	    func_append delfiles " $output"
+	    func_to_tool_file "$output"
+	    output=$firstobj\"$file_list_spec$func_to_tool_file_result\"
 	  else
 	    if test -n "$save_libobjs"; then
 	      func_verbose "creating reloadable object files..."
@@ -7190,17 +8371,19 @@ EOF
 		  # command to the queue.
 		  if test "$k" -eq 1 ; then
 		    # The first file doesn't have a previous command to add.
-		    eval concat_cmds=\"$reload_cmds $objlist $last_robj\"
+		    reload_objs=$objlist
+		    eval concat_cmds=\"$reload_cmds\"
 		  else
 		    # All subsequent reloadable object files will link in
 		    # the last one created.
-		    eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj~\$RM $last_robj\"
+		    reload_objs="$objlist $last_robj"
+		    eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\"
 		  fi
 		  last_robj=$output_objdir/$output_la-${k}.$objext
 		  func_arith $k + 1
 		  k=$func_arith_result
 		  output=$output_objdir/$output_la-${k}.$objext
-		  objlist=$obj
+		  objlist=" $obj"
 		  func_len " $last_robj"
 		  func_arith $len0 + $func_len_result
 		  len=$func_arith_result
@@ -7210,11 +8393,12 @@ EOF
 	      # reloadable object file.  All subsequent reloadable object
 	      # files will link in the last one created.
 	      test -z "$concat_cmds" || concat_cmds=$concat_cmds~
-	      eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\"
+	      reload_objs="$objlist $last_robj"
+	      eval concat_cmds=\"\${concat_cmds}$reload_cmds\"
 	      if test -n "$last_robj"; then
 	        eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\"
 	      fi
-	      delfiles="$delfiles $output"
+	      func_append delfiles " $output"
 
 	    else
 	      output=
@@ -7248,7 +8432,7 @@ EOF
 		lt_exit=$?
 
 		# Restore the uninstalled library and exit
-		if test "$mode" = relink; then
+		if test "$opt_mode" = relink; then
 		  ( cd "$output_objdir" && \
 		    $RM "${realname}T" && \
 		    $MV "${realname}U" "$realname" )
@@ -7269,7 +8453,7 @@ EOF
 	    if test -n "$export_symbols" && test -n "$include_expsyms"; then
 	      tmp_export_symbols="$export_symbols"
 	      test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
-	      $opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"'
+	      $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
 	    fi
 
 	    if test -n "$orig_export_symbols"; then
@@ -7281,7 +8465,7 @@ EOF
 	      # global variables. join(1) would be nice here, but unfortunately
 	      # isn't a blessed tool.
 	      $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
-	      delfiles="$delfiles $export_symbols $output_objdir/$libname.filter"
+	      func_append delfiles " $export_symbols $output_objdir/$libname.filter"
 	      export_symbols=$output_objdir/$libname.def
 	      $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
 	    fi
@@ -7322,10 +8506,10 @@ EOF
 	# Add any objects from preloaded convenience libraries
 	if test -n "$dlprefiles"; then
 	  gentop="$output_objdir/${outputname}x"
-	  generated="$generated $gentop"
+	  func_append generated " $gentop"
 
 	  func_extract_archives $gentop $dlprefiles
-	  libobjs="$libobjs $func_extract_archives_result"
+	  func_append libobjs " $func_extract_archives_result"
 	  test "X$libobjs" = "X " && libobjs=
 	fi
 
@@ -7341,7 +8525,7 @@ EOF
 	    lt_exit=$?
 
 	    # Restore the uninstalled library and exit
-	    if test "$mode" = relink; then
+	    if test "$opt_mode" = relink; then
 	      ( cd "$output_objdir" && \
 	        $RM "${realname}T" && \
 		$MV "${realname}U" "$realname" )
@@ -7353,7 +8537,7 @@ EOF
 	IFS="$save_ifs"
 
 	# Restore the uninstalled library and exit
-	if test "$mode" = relink; then
+	if test "$opt_mode" = relink; then
 	  $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $?
 
 	  if test -n "$convenience"; then
@@ -7434,18 +8618,21 @@ EOF
       if test -n "$convenience"; then
 	if test -n "$whole_archive_flag_spec"; then
 	  eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
-	  reload_conv_objs=$reload_objs\ `$ECHO "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'`
+	  reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'`
 	else
 	  gentop="$output_objdir/${obj}x"
-	  generated="$generated $gentop"
+	  func_append generated " $gentop"
 
 	  func_extract_archives $gentop $convenience
 	  reload_conv_objs="$reload_objs $func_extract_archives_result"
 	fi
       fi
 
+      # If we're not building shared, we need to use non_pic_objs
+      test "$build_libtool_libs" != yes && libobjs="$non_pic_objects"
+
       # Create the old-style object.
-      reload_objs="$objs$old_deplibs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
+      reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
 
       output="$obj"
       func_execute_cmds "$reload_cmds" 'exit $?'
@@ -7505,8 +8692,8 @@ EOF
       case $host in
       *-*-rhapsody* | *-*-darwin1.[012])
 	# On Rhapsody replace the C library is the System framework
-	compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
-	finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
+	compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'`
+	finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'`
 	;;
       esac
 
@@ -7517,14 +8704,14 @@ EOF
 	if test "$tagname" = CXX ; then
 	  case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
 	    10.[0123])
-	      compile_command="$compile_command ${wl}-bind_at_load"
-	      finalize_command="$finalize_command ${wl}-bind_at_load"
+	      func_append compile_command " ${wl}-bind_at_load"
+	      func_append finalize_command " ${wl}-bind_at_load"
 	    ;;
 	  esac
 	fi
 	# Time to change all our "foo.ltframework" stuff back to "-framework foo"
-	compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
-	finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
+	compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
+	finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
 	;;
       esac
 
@@ -7538,7 +8725,7 @@ EOF
 	*)
 	  case " $compile_deplibs " in
 	  *" -L$path/$objdir "*)
-	    new_libs="$new_libs -L$path/$objdir" ;;
+	    func_append new_libs " -L$path/$objdir" ;;
 	  esac
 	  ;;
 	esac
@@ -7548,17 +8735,17 @@ EOF
 	-L*)
 	  case " $new_libs " in
 	  *" $deplib "*) ;;
-	  *) new_libs="$new_libs $deplib" ;;
+	  *) func_append new_libs " $deplib" ;;
 	  esac
 	  ;;
-	*) new_libs="$new_libs $deplib" ;;
+	*) func_append new_libs " $deplib" ;;
 	esac
       done
       compile_deplibs="$new_libs"
 
 
-      compile_command="$compile_command $compile_deplibs"
-      finalize_command="$finalize_command $finalize_deplibs"
+      func_append compile_command " $compile_deplibs"
+      func_append finalize_command " $finalize_deplibs"
 
       if test -n "$rpath$xrpath"; then
 	# If the user specified any rpath flags, then add them.
@@ -7566,7 +8753,7 @@ EOF
 	  # This is the magic to use -rpath.
 	  case "$finalize_rpath " in
 	  *" $libdir "*) ;;
-	  *) finalize_rpath="$finalize_rpath $libdir" ;;
+	  *) func_append finalize_rpath " $libdir" ;;
 	  esac
 	done
       fi
@@ -7585,18 +8772,18 @@ EOF
 	      *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
 		;;
 	      *)
-		hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
+		func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
 		;;
 	      esac
 	    fi
 	  else
 	    eval flag=\"$hardcode_libdir_flag_spec\"
-	    rpath="$rpath $flag"
+	    func_append rpath " $flag"
 	  fi
 	elif test -n "$runpath_var"; then
 	  case "$perm_rpath " in
 	  *" $libdir "*) ;;
-	  *) perm_rpath="$perm_rpath $libdir" ;;
+	  *) func_append perm_rpath " $libdir" ;;
 	  esac
 	fi
 	case $host in
@@ -7605,12 +8792,12 @@ EOF
 	  case :$dllsearchpath: in
 	  *":$libdir:"*) ;;
 	  ::) dllsearchpath=$libdir;;
-	  *) dllsearchpath="$dllsearchpath:$libdir";;
+	  *) func_append dllsearchpath ":$libdir";;
 	  esac
 	  case :$dllsearchpath: in
 	  *":$testbindir:"*) ;;
 	  ::) dllsearchpath=$testbindir;;
-	  *) dllsearchpath="$dllsearchpath:$testbindir";;
+	  *) func_append dllsearchpath ":$testbindir";;
 	  esac
 	  ;;
 	esac
@@ -7636,18 +8823,18 @@ EOF
 	      *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
 		;;
 	      *)
-		hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
+		func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
 		;;
 	      esac
 	    fi
 	  else
 	    eval flag=\"$hardcode_libdir_flag_spec\"
-	    rpath="$rpath $flag"
+	    func_append rpath " $flag"
 	  fi
 	elif test -n "$runpath_var"; then
 	  case "$finalize_perm_rpath " in
 	  *" $libdir "*) ;;
-	  *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;;
+	  *) func_append finalize_perm_rpath " $libdir" ;;
 	  esac
 	fi
       done
@@ -7661,8 +8848,8 @@ EOF
 
       if test -n "$libobjs" && test "$build_old_libs" = yes; then
 	# Transform all the library objects into standard objects.
-	compile_command=`$ECHO "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
-	finalize_command=`$ECHO "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
+	compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
+	finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
       fi
 
       func_generate_dlsyms "$outputname" "@PROGRAM@" "no"
@@ -7674,15 +8861,15 @@ EOF
 
       wrappers_required=yes
       case $host in
+      *cegcc* | *mingw32ce*)
+        # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway.
+        wrappers_required=no
+        ;;
       *cygwin* | *mingw* )
         if test "$build_libtool_libs" != yes; then
           wrappers_required=no
         fi
         ;;
-      *cegcc)
-        # Disable wrappers for cegcc, we are cross compiling anyway.
-        wrappers_required=no
-        ;;
       *)
         if test "$need_relink" = no || test "$build_libtool_libs" != yes; then
           wrappers_required=no
@@ -7691,13 +8878,19 @@ EOF
       esac
       if test "$wrappers_required" = no; then
 	# Replace the output file specification.
-	compile_command=`$ECHO "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'`
+	compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
 	link_command="$compile_command$compile_rpath"
 
 	# We have no uninstalled library dependencies, so finalize right now.
 	exit_status=0
 	func_show_eval "$link_command" 'exit_status=$?'
 
+	if test -n "$postlink_cmds"; then
+	  func_to_tool_file "$output"
+	  postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
+	  func_execute_cmds "$postlink_cmds" 'exit $?'
+	fi
+
 	# Delete the generated files.
 	if test -f "$output_objdir/${outputname}S.${objext}"; then
 	  func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"'
@@ -7720,7 +8913,7 @@ EOF
 	  # We should set the runpath_var.
 	  rpath=
 	  for dir in $perm_rpath; do
-	    rpath="$rpath$dir:"
+	    func_append rpath "$dir:"
 	  done
 	  compile_var="$runpath_var=\"$rpath\$$runpath_var\" "
 	fi
@@ -7728,7 +8921,7 @@ EOF
 	  # We should set the runpath_var.
 	  rpath=
 	  for dir in $finalize_perm_rpath; do
-	    rpath="$rpath$dir:"
+	    func_append rpath "$dir:"
 	  done
 	  finalize_var="$runpath_var=\"$rpath\$$runpath_var\" "
 	fi
@@ -7738,11 +8931,18 @@ EOF
 	# We don't need to create a wrapper script.
 	link_command="$compile_var$compile_command$compile_rpath"
 	# Replace the output file specification.
-	link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'`
+	link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
 	# Delete the old output file.
 	$opt_dry_run || $RM $output
 	# Link the executable and exit
 	func_show_eval "$link_command" 'exit $?'
+
+	if test -n "$postlink_cmds"; then
+	  func_to_tool_file "$output"
+	  postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
+	  func_execute_cmds "$postlink_cmds" 'exit $?'
+	fi
+
 	exit $EXIT_SUCCESS
       fi
 
@@ -7757,7 +8957,7 @@ EOF
 	if test "$fast_install" != no; then
 	  link_command="$finalize_var$compile_command$finalize_rpath"
 	  if test "$fast_install" = yes; then
-	    relink_command=`$ECHO "X$compile_var$compile_command$compile_rpath" | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g'`
+	    relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'`
 	  else
 	    # fast_install is set to needless
 	    relink_command=
@@ -7769,13 +8969,19 @@ EOF
       fi
 
       # Replace the output file specification.
-      link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
+      link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
 
       # Delete the old output files.
       $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname
 
       func_show_eval "$link_command" 'exit $?'
 
+      if test -n "$postlink_cmds"; then
+	func_to_tool_file "$output_objdir/$outputname"
+	postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
+	func_execute_cmds "$postlink_cmds" 'exit $?'
+      fi
+
       # Now create the wrapper script.
       func_verbose "creating $output"
 
@@ -7793,18 +8999,7 @@ EOF
 	  fi
 	done
 	relink_command="(cd `pwd`; $relink_command)"
-	relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"`
-      fi
-
-      # Quote $ECHO for shipping.
-      if test "X$ECHO" = "X$SHELL $progpath --fallback-echo"; then
-	case $progpath in
-	[\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";;
-	*) qecho="$SHELL `pwd`/$progpath --fallback-echo";;
-	esac
-	qecho=`$ECHO "X$qecho" | $Xsed -e "$sed_quote_subst"`
-      else
-	qecho=`$ECHO "X$ECHO" | $Xsed -e "$sed_quote_subst"`
+	relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"`
       fi
 
       # Only actually do things if not in dry run mode.
@@ -7884,7 +9079,7 @@ EOF
 	else
 	  oldobjs="$old_deplibs $non_pic_objects"
 	  if test "$preload" = yes && test -f "$symfileobj"; then
-	    oldobjs="$oldobjs $symfileobj"
+	    func_append oldobjs " $symfileobj"
 	  fi
 	fi
 	addlibs="$old_convenience"
@@ -7892,10 +9087,10 @@ EOF
 
       if test -n "$addlibs"; then
 	gentop="$output_objdir/${outputname}x"
-	generated="$generated $gentop"
+	func_append generated " $gentop"
 
 	func_extract_archives $gentop $addlibs
-	oldobjs="$oldobjs $func_extract_archives_result"
+	func_append oldobjs " $func_extract_archives_result"
       fi
 
       # Do each command in the archive commands.
@@ -7906,10 +9101,10 @@ EOF
 	# Add any objects from preloaded convenience libraries
 	if test -n "$dlprefiles"; then
 	  gentop="$output_objdir/${outputname}x"
-	  generated="$generated $gentop"
+	  func_append generated " $gentop"
 
 	  func_extract_archives $gentop $dlprefiles
-	  oldobjs="$oldobjs $func_extract_archives_result"
+	  func_append oldobjs " $func_extract_archives_result"
 	fi
 
 	# POSIX demands no paths to be encoded in archives.  We have
@@ -7925,9 +9120,9 @@ EOF
 	    done | sort | sort -uc >/dev/null 2>&1); then
 	  :
 	else
-	  $ECHO "copying selected object files to avoid basename conflicts..."
+	  echo "copying selected object files to avoid basename conflicts..."
 	  gentop="$output_objdir/${outputname}x"
-	  generated="$generated $gentop"
+	  func_append generated " $gentop"
 	  func_mkdir_p "$gentop"
 	  save_oldobjs=$oldobjs
 	  oldobjs=
@@ -7951,9 +9146,9 @@ EOF
 		esac
 	      done
 	      func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj"
-	      oldobjs="$oldobjs $gentop/$newobj"
+	      func_append oldobjs " $gentop/$newobj"
 	      ;;
-	    *) oldobjs="$oldobjs $obj" ;;
+	    *) func_append oldobjs " $obj" ;;
 	    esac
 	  done
 	fi
@@ -7963,6 +9158,16 @@ EOF
 	len=$func_len_result
 	if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
 	  cmds=$old_archive_cmds
+	elif test -n "$archiver_list_spec"; then
+	  func_verbose "using command file archive linking..."
+	  for obj in $oldobjs
+	  do
+	    func_to_tool_file "$obj"
+	    $ECHO "$func_to_tool_file_result"
+	  done > $output_objdir/$libname.libcmd
+	  func_to_tool_file "$output_objdir/$libname.libcmd"
+	  oldobjs=" $archiver_list_spec$func_to_tool_file_result"
+	  cmds=$old_archive_cmds
 	else
 	  # the command line is too long to link in one step, link in parts
 	  func_verbose "using piecewise archive linking..."
@@ -8036,7 +9241,7 @@ EOF
       done
       # Quote the link command for shipping.
       relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
-      relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"`
+      relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"`
       if test "$hardcode_automatic" = yes ; then
 	relink_command=
       fi
@@ -8059,9 +9264,19 @@ EOF
 		eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
 		test -z "$libdir" && \
 		  func_fatal_error "\`$deplib' is not a valid libtool archive"
-		newdependency_libs="$newdependency_libs $libdir/$name"
+		func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name"
+		;;
+	      -L*)
+		func_stripname -L '' "$deplib"
+		func_replace_sysroot "$func_stripname_result"
+		func_append newdependency_libs " -L$func_replace_sysroot_result"
 		;;
-	      *) newdependency_libs="$newdependency_libs $deplib" ;;
+	      -R*)
+		func_stripname -R '' "$deplib"
+		func_replace_sysroot "$func_stripname_result"
+		func_append newdependency_libs " -R$func_replace_sysroot_result"
+		;;
+	      *) func_append newdependency_libs " $deplib" ;;
 	      esac
 	    done
 	    dependency_libs="$newdependency_libs"
@@ -8075,9 +9290,9 @@ EOF
 		eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
 		test -z "$libdir" && \
 		  func_fatal_error "\`$lib' is not a valid libtool archive"
-		newdlfiles="$newdlfiles $libdir/$name"
+		func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name"
 		;;
-	      *) newdlfiles="$newdlfiles $lib" ;;
+	      *) func_append newdlfiles " $lib" ;;
 	      esac
 	    done
 	    dlfiles="$newdlfiles"
@@ -8094,7 +9309,7 @@ EOF
 		eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
 		test -z "$libdir" && \
 		  func_fatal_error "\`$lib' is not a valid libtool archive"
-		newdlprefiles="$newdlprefiles $libdir/$name"
+		func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name"
 		;;
 	      esac
 	    done
@@ -8106,7 +9321,7 @@ EOF
 		[\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
 		*) abs=`pwd`"/$lib" ;;
 	      esac
-	      newdlfiles="$newdlfiles $abs"
+	      func_append newdlfiles " $abs"
 	    done
 	    dlfiles="$newdlfiles"
 	    newdlprefiles=
@@ -8115,15 +9330,33 @@ EOF
 		[\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
 		*) abs=`pwd`"/$lib" ;;
 	      esac
-	      newdlprefiles="$newdlprefiles $abs"
+	      func_append newdlprefiles " $abs"
 	    done
 	    dlprefiles="$newdlprefiles"
 	  fi
 	  $RM $output
 	  # place dlname in correct position for cygwin
+	  # In fact, it would be nice if we could use this code for all target
+	  # systems that can't hard-code library paths into their executables
+	  # and that have no shared library path variable independent of PATH,
+	  # but it turns out we can't easily determine that from inspecting
+	  # libtool variables, so we have to hard-code the OSs to which it
+	  # applies here; at the moment, that means platforms that use the PE
+	  # object format with DLL files.  See the long comment at the top of
+	  # tests/bindir.at for full details.
 	  tdlname=$dlname
 	  case $host,$output,$installed,$module,$dlname in
-	    *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;;
+	    *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll)
+	      # If a -bindir argument was supplied, place the dll there.
+	      if test "x$bindir" != x ;
+	      then
+		func_relative_path "$install_libdir" "$bindir"
+		tdlname=$func_relative_path_result$dlname
+	      else
+		# Otherwise fall back on heuristic.
+		tdlname=../bin/$dlname
+	      fi
+	      ;;
 	  esac
 	  $ECHO > $output "\
 # $outputname - a libtool library file
@@ -8182,7 +9415,7 @@ relink_command=\"$relink_command\""
     exit $EXIT_SUCCESS
 }
 
-{ test "$mode" = link || test "$mode" = relink; } &&
+{ test "$opt_mode" = link || test "$opt_mode" = relink; } &&
     func_mode_link ${1+"$@"}
 
 
@@ -8202,9 +9435,9 @@ func_mode_uninstall ()
     for arg
     do
       case $arg in
-      -f) RM="$RM $arg"; rmforce=yes ;;
-      -*) RM="$RM $arg" ;;
-      *) files="$files $arg" ;;
+      -f) func_append RM " $arg"; rmforce=yes ;;
+      -*) func_append RM " $arg" ;;
+      *) func_append files " $arg" ;;
       esac
     done
 
@@ -8213,24 +9446,23 @@ func_mode_uninstall ()
 
     rmdirs=
 
-    origobjdir="$objdir"
     for file in $files; do
       func_dirname "$file" "" "."
       dir="$func_dirname_result"
       if test "X$dir" = X.; then
-	objdir="$origobjdir"
+	odir="$objdir"
       else
-	objdir="$dir/$origobjdir"
+	odir="$dir/$objdir"
       fi
       func_basename "$file"
       name="$func_basename_result"
-      test "$mode" = uninstall && objdir="$dir"
+      test "$opt_mode" = uninstall && odir="$dir"
 
-      # Remember objdir for removal later, being careful to avoid duplicates
-      if test "$mode" = clean; then
+      # Remember odir for removal later, being careful to avoid duplicates
+      if test "$opt_mode" = clean; then
 	case " $rmdirs " in
-	  *" $objdir "*) ;;
-	  *) rmdirs="$rmdirs $objdir" ;;
+	  *" $odir "*) ;;
+	  *) func_append rmdirs " $odir" ;;
 	esac
       fi
 
@@ -8256,18 +9488,17 @@ func_mode_uninstall ()
 
 	  # Delete the libtool libraries and symlinks.
 	  for n in $library_names; do
-	    rmfiles="$rmfiles $objdir/$n"
+	    func_append rmfiles " $odir/$n"
 	  done
-	  test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library"
+	  test -n "$old_library" && func_append rmfiles " $odir/$old_library"
 
-	  case "$mode" in
+	  case "$opt_mode" in
 	  clean)
-	    case "  $library_names " in
-	    # "  " in the beginning catches empty $dlname
+	    case " $library_names " in
 	    *" $dlname "*) ;;
-	    *) rmfiles="$rmfiles $objdir/$dlname" ;;
+	    *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;;
 	    esac
-	    test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i"
+	    test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i"
 	    ;;
 	  uninstall)
 	    if test -n "$library_names"; then
@@ -8295,19 +9526,19 @@ func_mode_uninstall ()
 	  # Add PIC object to the list of files to remove.
 	  if test -n "$pic_object" &&
 	     test "$pic_object" != none; then
-	    rmfiles="$rmfiles $dir/$pic_object"
+	    func_append rmfiles " $dir/$pic_object"
 	  fi
 
 	  # Add non-PIC object to the list of files to remove.
 	  if test -n "$non_pic_object" &&
 	     test "$non_pic_object" != none; then
-	    rmfiles="$rmfiles $dir/$non_pic_object"
+	    func_append rmfiles " $dir/$non_pic_object"
 	  fi
 	fi
 	;;
 
       *)
-	if test "$mode" = clean ; then
+	if test "$opt_mode" = clean ; then
 	  noexename=$name
 	  case $file in
 	  *.exe)
@@ -8317,7 +9548,7 @@ func_mode_uninstall ()
 	    noexename=$func_stripname_result
 	    # $file with .exe has already been added to rmfiles,
 	    # add $file without .exe
-	    rmfiles="$rmfiles $file"
+	    func_append rmfiles " $file"
 	    ;;
 	  esac
 	  # Do a test to see if this is a libtool program.
@@ -8326,7 +9557,7 @@ func_mode_uninstall ()
 	      func_ltwrapper_scriptname "$file"
 	      relink_command=
 	      func_source $func_ltwrapper_scriptname_result
-	      rmfiles="$rmfiles $func_ltwrapper_scriptname_result"
+	      func_append rmfiles " $func_ltwrapper_scriptname_result"
 	    else
 	      relink_command=
 	      func_source $dir/$noexename
@@ -8334,12 +9565,12 @@ func_mode_uninstall ()
 
 	    # note $name still contains .exe if it was in $file originally
 	    # as does the version of $file that was added into $rmfiles
-	    rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}"
+	    func_append rmfiles " $odir/$name $odir/${name}S.${objext}"
 	    if test "$fast_install" = yes && test -n "$relink_command"; then
-	      rmfiles="$rmfiles $objdir/lt-$name"
+	      func_append rmfiles " $odir/lt-$name"
 	    fi
 	    if test "X$noexename" != "X$name" ; then
-	      rmfiles="$rmfiles $objdir/lt-${noexename}.c"
+	      func_append rmfiles " $odir/lt-${noexename}.c"
 	    fi
 	  fi
 	fi
@@ -8347,7 +9578,6 @@ func_mode_uninstall ()
       esac
       func_show_eval "$RM $rmfiles" 'exit_status=1'
     done
-    objdir="$origobjdir"
 
     # Try to remove the ${objdir}s in the directories where we deleted files
     for dir in $rmdirs; do
@@ -8359,16 +9589,16 @@ func_mode_uninstall ()
     exit $exit_status
 }
 
-{ test "$mode" = uninstall || test "$mode" = clean; } &&
+{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } &&
     func_mode_uninstall ${1+"$@"}
 
-test -z "$mode" && {
+test -z "$opt_mode" && {
   help="$generic_help"
   func_fatal_help "you must specify a MODE"
 }
 
 test -z "$exec_cmd" && \
-  func_fatal_help "invalid operation mode \`$mode'"
+  func_fatal_help "invalid operation mode \`$opt_mode'"
 
 if test -n "$exec_cmd"; then
   eval exec "$exec_cmd"
diff --git a/config/ltoptions.m4 b/config/ltoptions.m4
index 34151a3..17cfd51 100644
--- a/config/ltoptions.m4
+++ b/config/ltoptions.m4
@@ -1,13 +1,14 @@
 # Helper functions for option handling.                    -*- Autoconf -*-
 #
-#   Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
+#   Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
+#   Inc.
 #   Written by Gary V. Vaughan, 2004
 #
 # This file is free software; the Free Software Foundation gives
 # unlimited permission to copy and/or distribute it, with or without
 # modifications, as long as this notice is preserved.
 
-# serial 6 ltoptions.m4
+# serial 7 ltoptions.m4
 
 # This is to help aclocal find these macros, as it can't see m4_define.
 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
@@ -125,7 +126,7 @@ LT_OPTION_DEFINE([LT_INIT], [win32-dll],
 [enable_win32_dll=yes
 
 case $host in
-*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*)
+*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
   AC_CHECK_TOOL(AS, as, false)
   AC_CHECK_TOOL(DLLTOOL, dlltool, false)
   AC_CHECK_TOOL(OBJDUMP, objdump, false)
@@ -133,13 +134,13 @@ case $host in
 esac
 
 test -z "$AS" && AS=as
-_LT_DECL([], [AS],      [0], [Assembler program])dnl
+_LT_DECL([], [AS],      [1], [Assembler program])dnl
 
 test -z "$DLLTOOL" && DLLTOOL=dlltool
-_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl
+_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
 
 test -z "$OBJDUMP" && OBJDUMP=objdump
-_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl
+_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
 ])# win32-dll
 
 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
diff --git a/config/ltversion.m4 b/config/ltversion.m4
index f3c5309..9c7b5d4 100644
--- a/config/ltversion.m4
+++ b/config/ltversion.m4
@@ -7,17 +7,17 @@
 # unlimited permission to copy and/or distribute it, with or without
 # modifications, as long as this notice is preserved.
 
-# Generated from ltversion.in.
+# @configure_input@
 
-# serial 3017 ltversion.m4
+# serial 3293 ltversion.m4
 # This file is part of GNU Libtool
 
-m4_define([LT_PACKAGE_VERSION], [2.2.6b])
-m4_define([LT_PACKAGE_REVISION], [1.3017])
+m4_define([LT_PACKAGE_VERSION], [2.4])
+m4_define([LT_PACKAGE_REVISION], [1.3293])
 
 AC_DEFUN([LTVERSION_VERSION],
-[macro_version='2.2.6b'
-macro_revision='1.3017'
+[macro_version='2.4'
+macro_revision='1.3293'
 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
 _LT_DECL(, macro_revision, 0)
 ])
diff --git a/config/lt~obsolete.m4 b/config/lt~obsolete.m4
index 637bb20..c573da9 100644
--- a/config/lt~obsolete.m4
+++ b/config/lt~obsolete.m4
@@ -1,13 +1,13 @@
 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions.    -*-Autoconf-*-
 #
-#   Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc.
+#   Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
 #   Written by Scott James Remnant, 2004.
 #
 # This file is free software; the Free Software Foundation gives
 # unlimited permission to copy and/or distribute it, with or without
 # modifications, as long as this notice is preserved.
 
-# serial 4 lt~obsolete.m4
+# serial 5 lt~obsolete.m4
 
 # These exist entirely to fool aclocal when bootstrapping libtool.
 #
@@ -77,7 +77,6 @@ m4_ifndef([AC_DISABLE_FAST_INSTALL],	[AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
 m4_ifndef([_LT_AC_LANG_CXX],		[AC_DEFUN([_LT_AC_LANG_CXX])])
 m4_ifndef([_LT_AC_LANG_F77],		[AC_DEFUN([_LT_AC_LANG_F77])])
 m4_ifndef([_LT_AC_LANG_GCJ],		[AC_DEFUN([_LT_AC_LANG_GCJ])])
-m4_ifndef([AC_LIBTOOL_RC],		[AC_DEFUN([AC_LIBTOOL_RC])])
 m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
 m4_ifndef([_LT_AC_LANG_C_CONFIG],	[AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
 m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
@@ -90,3 +89,10 @@ m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG],	[AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
 m4_ifndef([_LT_AC_LANG_RC_CONFIG],	[AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
 m4_ifndef([AC_LIBTOOL_CONFIG],		[AC_DEFUN([AC_LIBTOOL_CONFIG])])
 m4_ifndef([_LT_AC_FILE_LTDLL_C],	[AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
+m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS],	[AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
+m4_ifndef([_LT_AC_PROG_CXXCPP],		[AC_DEFUN([_LT_AC_PROG_CXXCPP])])
+m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS],	[AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
+m4_ifndef([_LT_PROG_ECHO_BACKSLASH],	[AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
+m4_ifndef([_LT_PROG_F77],		[AC_DEFUN([_LT_PROG_F77])])
+m4_ifndef([_LT_PROG_FC],		[AC_DEFUN([_LT_PROG_FC])])
+m4_ifndef([_LT_PROG_CXX],		[AC_DEFUN([_LT_PROG_CXX])])
diff --git a/config/nls.m4 b/config/nls.m4
index 7967cc2..003704c 100644
--- a/config/nls.m4
+++ b/config/nls.m4
@@ -1,5 +1,6 @@
-# nls.m4 serial 3 (gettext-0.15)
-dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc.
+# nls.m4 serial 5 (gettext-0.18)
+dnl Copyright (C) 1995-2003, 2005-2006, 2008-2010 Free Software Foundation,
+dnl Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -17,15 +18,15 @@ dnl Authors:
 dnl   Ulrich Drepper <drepper at cygnus.com>, 1995-2000.
 dnl   Bruno Haible <haible at clisp.cons.org>, 2000-2003.
 
-AC_PREREQ(2.50)
+AC_PREREQ([2.50])
 
 AC_DEFUN([AM_NLS],
 [
   AC_MSG_CHECKING([whether NLS is requested])
   dnl Default is enabled NLS
-  AC_ARG_ENABLE(nls,
+  AC_ARG_ENABLE([nls],
     [  --disable-nls           do not use Native Language Support],
     USE_NLS=$enableval, USE_NLS=yes)
-  AC_MSG_RESULT($USE_NLS)
-  AC_SUBST(USE_NLS)
+  AC_MSG_RESULT([$USE_NLS])
+  AC_SUBST([USE_NLS])
 ])
diff --git a/config/po.m4 b/config/po.m4
index 0734762..47f36a4 100644
--- a/config/po.m4
+++ b/config/po.m4
@@ -1,5 +1,5 @@
-# po.m4 serial 15 (gettext-0.17)
-dnl Copyright (C) 1995-2007 Free Software Foundation, Inc.
+# po.m4 serial 17 (gettext-0.18)
+dnl Copyright (C) 1995-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -17,7 +17,7 @@ dnl Authors:
 dnl   Ulrich Drepper <drepper at cygnus.com>, 1995-2000.
 dnl   Bruno Haible <haible at clisp.cons.org>, 2000-2003.
 
-AC_PREREQ(2.50)
+AC_PREREQ([2.50])
 
 dnl Checks for all prerequisites of the po subdirectory.
 AC_DEFUN([AM_PO_SUBDIRS],
@@ -29,7 +29,7 @@ AC_DEFUN([AM_PO_SUBDIRS],
 
   dnl Release version of the gettext macros. This is used to ensure that
   dnl the gettext macros and po/Makefile.in.in are in sync.
-  AC_SUBST([GETTEXT_MACRO_VERSION], [0.17])
+  AC_SUBST([GETTEXT_MACRO_VERSION], [0.18])
 
   dnl Perform the following tests also if --disable-nls has been given,
   dnl because they are needed for "make dist" to work.
@@ -41,7 +41,7 @@ AC_DEFUN([AM_PO_SUBDIRS],
     [$ac_dir/$ac_word --statistics /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 &&
      (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
     :)
-  AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
+  AC_PATH_PROG([GMSGFMT], [gmsgfmt], [$MSGFMT])
 
   dnl Test whether it is GNU msgfmt >= 0.15.
 changequote(,)dnl
diff --git a/config/progtest.m4 b/config/progtest.m4
index a56365c..2d804ac 100644
--- a/config/progtest.m4
+++ b/config/progtest.m4
@@ -1,5 +1,5 @@
-# progtest.m4 serial 4 (gettext-0.14.2)
-dnl Copyright (C) 1996-2003, 2005 Free Software Foundation, Inc.
+# progtest.m4 serial 6 (gettext-0.18)
+dnl Copyright (C) 1996-2003, 2005, 2008-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
 dnl with or without modifications, as long as this notice is preserved.
@@ -16,7 +16,7 @@ dnl They are *not* in the public domain.
 dnl Authors:
 dnl   Ulrich Drepper <drepper at cygnus.com>, 1996.
 
-AC_PREREQ(2.50)
+AC_PREREQ([2.50])
 
 # Search path for a program which passes the given test.
 
@@ -55,7 +55,7 @@ rm -f conf$$.file
 # Extract the first word of "$2", so it can be a program name with args.
 set dummy $2; ac_word=[$]2
 AC_MSG_CHECKING([for $ac_word])
-AC_CACHE_VAL(ac_cv_path_$1,
+AC_CACHE_VAL([ac_cv_path_$1],
 [case "[$]$1" in
   [[\\/]]* | ?:[[\\/]]*)
     ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
@@ -84,9 +84,9 @@ ifelse([$4], , , [  test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
 esac])dnl
 $1="$ac_cv_path_$1"
 if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
-  AC_MSG_RESULT([$]$1)
+  AC_MSG_RESULT([$][$1])
 else
-  AC_MSG_RESULT(no)
+  AC_MSG_RESULT([no])
 fi
-AC_SUBST($1)dnl
+AC_SUBST([$1])dnl
 ])
diff --git a/configure b/configure
index 39735cb..e2f8e15 100755
--- a/configure
+++ b/configure
@@ -1,13 +1,13 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.65 for ncs 2.0.0-rc1.
+# Generated by GNU Autoconf 2.68 for ncs 2.0.1.
 #
 # Report bugs to <saturne-support at edf.fr>.
 #
 #
 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
-# Inc.
+# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
+# Foundation, Inc.
 #
 #
 # This configure script is free software; the Free Software Foundation
@@ -91,6 +91,7 @@ fi
 IFS=" ""	$as_nl"
 
 # Find who we are.  Look in the path if we contain no directory separator.
+as_myself=
 case $0 in #((
   *[\\/]* ) as_myself=$0 ;;
   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -173,7 +174,15 @@ test x\$exitcode = x0 || exit 1"
   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1"
+test \$(( 1 + 1 )) = 2 || exit 1
+
+  test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
+    ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+    ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
+    ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
+    PATH=/empty FPATH=/empty; export PATH FPATH
+    test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
+      || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
   if (eval "$as_required") 2>/dev/null; then :
   as_have_required=yes
 else
@@ -216,11 +225,18 @@ IFS=$as_save_IFS
   # We cannot yet assume a decent shell, so we have to provide a
 	# neutralization value for shells without unset; and this also
 	# works around shells that cannot unset nonexistent variables.
+	# Preserve -v and -x to the replacement shell.
 	BASH_ENV=/dev/null
 	ENV=/dev/null
 	(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
 	export CONFIG_SHELL
-	exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
+	case $- in # ((((
+	  *v*x* | *x*v* ) as_opts=-vx ;;
+	  *v* ) as_opts=-v ;;
+	  *x* ) as_opts=-x ;;
+	  * ) as_opts= ;;
+	esac
+	exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
 fi
 
     if test x$as_have_required = xno; then :
@@ -319,7 +335,7 @@ $as_echo X"$as_dir" |
       test -d "$as_dir" && break
     done
     test -z "$as_dirs" || eval "mkdir $as_dirs"
-  } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
+  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
 
 
 } # as_fn_mkdir_p
@@ -359,19 +375,19 @@ else
 fi # as_fn_arith
 
 
-# as_fn_error ERROR [LINENO LOG_FD]
-# ---------------------------------
+# as_fn_error STATUS ERROR [LINENO LOG_FD]
+# ----------------------------------------
 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with status $?, using 1 if that was 0.
+# script with STATUS, using 1 if that was 0.
 as_fn_error ()
 {
-  as_status=$?; test $as_status -eq 0 && as_status=1
-  if test "$3"; then
-    as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-    $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
+  as_status=$1; test $as_status -eq 0 && as_status=1
+  if test "$4"; then
+    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
   fi
-  $as_echo "$as_me: error: $1" >&2
+  $as_echo "$as_me: error: $2" >&2
   as_fn_exit $as_status
 } # as_fn_error
 
@@ -528,161 +544,14 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
 # Sed expression to map a string onto a valid variable name.
 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
 
-
-
-# Check that we are running under the correct shell.
 SHELL=${CONFIG_SHELL-/bin/sh}
 
-case X$lt_ECHO in
-X*--fallback-echo)
-  # Remove one level of quotation (which was required for Make).
-  ECHO=`echo "$lt_ECHO" | sed 's,\\\\\$\\$0,'$0','`
-  ;;
-esac
-
-ECHO=${lt_ECHO-echo}
-if test "X$1" = X--no-reexec; then
-  # Discard the --no-reexec flag, and continue.
-  shift
-elif test "X$1" = X--fallback-echo; then
-  # Avoid inline document here, it may be left over
-  :
-elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
-  # Yippee, $ECHO works!
-  :
-else
-  # Restart under the correct shell.
-  exec $SHELL "$0" --no-reexec ${1+"$@"}
-fi
-
-if test "X$1" = X--fallback-echo; then
-  # used as fallback echo
-  shift
-  cat <<_LT_EOF
-$*
-_LT_EOF
-  exit 0
-fi
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-if test -z "$lt_ECHO"; then
-  if test "X${echo_test_string+set}" != Xset; then
-    # find a string as large as possible, as long as the shell can cope with it
-    for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
-      # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
-      if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
-	 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
-      then
-        break
-      fi
-    done
-  fi
-
-  if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
-     echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
-     test "X$echo_testing_string" = "X$echo_test_string"; then
-    :
-  else
-    # The Solaris, AIX, and Digital Unix default echo programs unquote
-    # backslashes.  This makes it impossible to quote backslashes using
-    #   echo "$something" | sed 's/\\/\\\\/g'
-    #
-    # So, first we look for a working echo in the user's PATH.
-
-    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-    for dir in $PATH /usr/ucb; do
-      IFS="$lt_save_ifs"
-      if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
-         test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
-         echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
-         test "X$echo_testing_string" = "X$echo_test_string"; then
-        ECHO="$dir/echo"
-        break
-      fi
-    done
-    IFS="$lt_save_ifs"
-
-    if test "X$ECHO" = Xecho; then
-      # We didn't find a better echo, so look for alternatives.
-      if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
-         echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
-         test "X$echo_testing_string" = "X$echo_test_string"; then
-        # This shell has a builtin print -r that does the trick.
-        ECHO='print -r'
-      elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
-	   test "X$CONFIG_SHELL" != X/bin/ksh; then
-        # If we have ksh, try running configure again with it.
-        ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
-        export ORIGINAL_CONFIG_SHELL
-        CONFIG_SHELL=/bin/ksh
-        export CONFIG_SHELL
-        exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
-      else
-        # Try using printf.
-        ECHO='printf %s\n'
-        if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
-	   echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
-	   test "X$echo_testing_string" = "X$echo_test_string"; then
-	  # Cool, printf works
-	  :
-        elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
-	     test "X$echo_testing_string" = 'X\t' &&
-	     echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
-	     test "X$echo_testing_string" = "X$echo_test_string"; then
-	  CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
-	  export CONFIG_SHELL
-	  SHELL="$CONFIG_SHELL"
-	  export SHELL
-	  ECHO="$CONFIG_SHELL $0 --fallback-echo"
-        elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
-	     test "X$echo_testing_string" = 'X\t' &&
-	     echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
-	     test "X$echo_testing_string" = "X$echo_test_string"; then
-	  ECHO="$CONFIG_SHELL $0 --fallback-echo"
-        else
-	  # maybe with a smaller string...
-	  prev=:
-
-	  for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
-	    if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
-	    then
-	      break
-	    fi
-	    prev="$cmd"
-	  done
-
-	  if test "$prev" != 'sed 50q "$0"'; then
-	    echo_test_string=`eval $prev`
-	    export echo_test_string
-	    exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
-	  else
-	    # Oops.  We lost completely, so just stick with echo.
-	    ECHO=echo
-	  fi
-        fi
-      fi
-    fi
-  fi
-fi
-
-# Copy echo and quote the copy suitably for passing to libtool from
-# the Makefile, instead of quoting the original, which is used later.
-lt_ECHO=$ECHO
-if test "X$lt_ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
-   lt_ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
-fi
-
-
-
 
 test -n "$DJDIR" || exec 7<&0 </dev/null
 exec 6>&1
 
 # Name of the host.
-# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
+# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
 # so uname gets run too.
 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
 
@@ -701,8 +570,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='ncs'
 PACKAGE_TARNAME='ncs'
-PACKAGE_VERSION='2.0.0-rc1'
-PACKAGE_STRING='ncs 2.0.0-rc1'
+PACKAGE_VERSION='2.0.1'
+PACKAGE_STRING='ncs 2.0.1'
 PACKAGE_BUGREPORT='saturne-support at edf.fr'
 PACKAGE_URL=''
 
@@ -831,9 +700,11 @@ OTOOL
 LIPO
 NMEDIT
 DSYMUTIL
-lt_ECHO
+MANIFEST_TOOL
 RANLIB
+ac_ct_AR
 AR
+DLLTOOL
 OBJDUMP
 NM
 ac_ct_DUMPBIN
@@ -873,6 +744,8 @@ CPPFLAGS
 LDFLAGS
 CFLAGS
 CC
+AM_BACKSLASH
+AM_DEFAULT_VERBOSITY
 MAINT
 MAINTAINER_MODE_FALSE
 MAINTAINER_MODE_TRUE
@@ -954,6 +827,7 @@ ac_subst_files='cs_config_comments'
 ac_user_opts='
 enable_option_checking
 enable_maintainer_mode
+enable_silent_rules
 enable_dependency_tracking
 enable_debug
 enable_auto_flags
@@ -963,6 +837,7 @@ enable_static
 with_pic
 enable_fast_install
 with_gnu_ld
+with_sysroot
 enable_libtool_lock
 enable_openmp
 with_bft
@@ -996,6 +871,7 @@ with_pyqt4_exec
 enable_sockets
 enable_dlloader
 enable_nls
+with_gnu_ld
 enable_rpath
 with_libiconv_prefix
 with_libintl_prefix
@@ -1010,9 +886,17 @@ LIBS
 CPPFLAGS
 FC
 FCFLAGS
+LDFLAGS
+LIBS
 CPP
+CPPFLAGS
+F77
+FFLAGS
+LDFLAGS
+LIBS
 F77
-FFLAGS'
+LDFLAGS
+LIBS'
 
 
 # Initialize some variables set by options.
@@ -1075,8 +959,9 @@ do
   fi
 
   case $ac_option in
-  *=*)	ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
-  *)	ac_optarg=yes ;;
+  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
+  *=)   ac_optarg= ;;
+  *)    ac_optarg=yes ;;
   esac
 
   # Accept the important Cygnus configure options, so we can diagnose typos.
@@ -1121,7 +1006,7 @@ do
     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
     # Reject names that are not valid shell variable names.
     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
-      as_fn_error "invalid feature name: $ac_useropt"
+      as_fn_error $? "invalid feature name: $ac_useropt"
     ac_useropt_orig=$ac_useropt
     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
     case $ac_user_opts in
@@ -1147,7 +1032,7 @@ do
     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
     # Reject names that are not valid shell variable names.
     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
-      as_fn_error "invalid feature name: $ac_useropt"
+      as_fn_error $? "invalid feature name: $ac_useropt"
     ac_useropt_orig=$ac_useropt
     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
     case $ac_user_opts in
@@ -1351,7 +1236,7 @@ do
     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
     # Reject names that are not valid shell variable names.
     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
-      as_fn_error "invalid package name: $ac_useropt"
+      as_fn_error $? "invalid package name: $ac_useropt"
     ac_useropt_orig=$ac_useropt
     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
     case $ac_user_opts in
@@ -1367,7 +1252,7 @@ do
     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
     # Reject names that are not valid shell variable names.
     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
-      as_fn_error "invalid package name: $ac_useropt"
+      as_fn_error $? "invalid package name: $ac_useropt"
     ac_useropt_orig=$ac_useropt
     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
     case $ac_user_opts in
@@ -1397,8 +1282,8 @@ do
   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
     x_libraries=$ac_optarg ;;
 
-  -*) as_fn_error "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information."
+  -*) as_fn_error $? "unrecognized option: \`$ac_option'
+Try \`$0 --help' for more information"
     ;;
 
   *=*)
@@ -1406,7 +1291,7 @@ Try \`$0 --help' for more information."
     # Reject names that are not valid shell variable names.
     case $ac_envvar in #(
       '' | [0-9]* | *[!_$as_cr_alnum]* )
-      as_fn_error "invalid variable name: \`$ac_envvar'" ;;
+      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
     esac
     eval $ac_envvar=\$ac_optarg
     export $ac_envvar ;;
@@ -1416,7 +1301,7 @@ Try \`$0 --help' for more information."
     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
-    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
+    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
     ;;
 
   esac
@@ -1424,13 +1309,13 @@ done
 
 if test -n "$ac_prev"; then
   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
-  as_fn_error "missing argument to $ac_option"
+  as_fn_error $? "missing argument to $ac_option"
 fi
 
 if test -n "$ac_unrecognized_opts"; then
   case $enable_option_checking in
     no) ;;
-    fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
+    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
   esac
 fi
@@ -1453,7 +1338,7 @@ do
     [\\/$]* | ?:[\\/]* )  continue;;
     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
   esac
-  as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
+  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
 done
 
 # There might be people who depend on the old broken behavior: `$host'
@@ -1467,8 +1352,8 @@ target=$target_alias
 if test "x$host_alias" != x; then
   if test "x$build_alias" = x; then
     cross_compiling=maybe
-    $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
-    If a cross compiler is detected then cross compile mode will be used." >&2
+    $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
+    If a cross compiler is detected then cross compile mode will be used" >&2
   elif test "x$build_alias" != "x$host_alias"; then
     cross_compiling=yes
   fi
@@ -1483,9 +1368,9 @@ test "$silent" = yes && exec 6>/dev/null
 ac_pwd=`pwd` && test -n "$ac_pwd" &&
 ac_ls_di=`ls -di .` &&
 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
-  as_fn_error "working directory cannot be determined"
+  as_fn_error $? "working directory cannot be determined"
 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
-  as_fn_error "pwd does not report name of working directory"
+  as_fn_error $? "pwd does not report name of working directory"
 
 
 # Find the source files, if location was not specified.
@@ -1524,11 +1409,11 @@ else
 fi
 if test ! -r "$srcdir/$ac_unique_file"; then
   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
-  as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
+  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
 fi
 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
 ac_abs_confdir=`(
-	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
+	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
 	pwd)`
 # When building in place, set srcdir=.
 if test "$ac_abs_confdir" = "$ac_pwd"; then
@@ -1554,7 +1439,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures ncs 2.0.0-rc1 to adapt to many kinds of systems.
+\`configure' configures ncs 2.0.1 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1568,7 +1453,7 @@ Configuration:
       --help=short        display options specific to this package
       --help=recursive    display the short help of all the included packages
   -V, --version           display version information and exit
-  -q, --quiet, --silent   do not print \`checking...' messages
+  -q, --quiet, --silent   do not print \`checking ...' messages
       --cache-file=FILE   cache test results in FILE [disabled]
   -C, --config-cache      alias for \`--cache-file=config.cache'
   -n, --no-create         do not create output files
@@ -1625,7 +1510,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of ncs 2.0.0-rc1:";;
+     short | recursive ) echo "Configuration of ncs 2.0.1:";;
    esac
   cat <<\_ACEOF
 
@@ -1635,6 +1520,8 @@ Optional Features:
   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
   --enable-maintainer-mode  enable make rules and dependencies not useful
 			  (and sometimes confusing) to the casual installer
+  --enable-silent-rules          less verbose build output (undo: `make V=1')
+  --disable-silent-rules         verbose build output (undo: `make V=0')
   --disable-dependency-tracking  speeds up one-time build
   --enable-dependency-tracking   do not reject slow dependency extractors
   --enable-debug          enable debugging (reduces optimization)
@@ -1658,6 +1545,8 @@ Optional Packages:
   --with-pic              try to use only PIC/non-PIC objects [default=use
                           both]
   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
+  --with-sysroot=DIR Search for dependent libraries within DIR
+                        (or the compiler's sysroot if not specified).
   --with-bft=PATH         specify prefix directory for BFT
   --with-bft-exec=PATH    specify directory for BFT executables
   --with-bft-include=PATH specify directory for BFT include files
@@ -1774,10 +1663,10 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-ncs configure 2.0.0-rc1
-generated by GNU Autoconf 2.65
+ncs configure 2.0.1
+generated by GNU Autoconf 2.68
 
-Copyright (C) 2009 Free Software Foundation, Inc.
+Copyright (C) 2010 Free Software Foundation, Inc.
 This configure script is free software; the Free Software Foundation
 gives unlimited permission to copy, distribute and modify it.
 _ACEOF
@@ -1821,7 +1710,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
 
 	ac_retval=1
 fi
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_c_try_compile
@@ -1859,7 +1748,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
 
 	ac_retval=1
 fi
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_fc_try_compile
@@ -1905,7 +1794,7 @@ fi
   # interfere with the next link command; also delete a directory that is
   # left behind by Apple's compiler.  We do this before executing the actions.
   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_c_try_link
@@ -1919,7 +1808,7 @@ ac_fn_c_check_header_compile ()
   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
 $as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${$3+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -1937,7 +1826,7 @@ fi
 eval ac_res=\$$3
 	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
 $as_echo "$ac_res" >&6; }
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
 
 } # ac_fn_c_check_header_compile
 
@@ -1962,7 +1851,7 @@ $as_echo "$ac_try_echo"; } >&5
     mv -f conftest.er1 conftest.err
   fi
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-  test $ac_status = 0; } >/dev/null && {
+  test $ac_status = 0; } > conftest.i && {
 	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
 	 test ! -s conftest.err
        }; then :
@@ -1973,7 +1862,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
 
     ac_retval=1
 fi
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_c_try_cpp
@@ -2015,7 +1904,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
        ac_retval=$ac_status
 fi
   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_c_try_run
@@ -2028,7 +1917,7 @@ ac_fn_c_check_func ()
   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
 $as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${$3+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -2083,7 +1972,7 @@ fi
 eval ac_res=\$$3
 	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
 $as_echo "$ac_res" >&6; }
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
 
 } # ac_fn_c_check_func
 
@@ -2128,7 +2017,7 @@ fi
   # interfere with the next link command; also delete a directory that is
   # left behind by Apple's compiler.  We do this before executing the actions.
   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_fc_try_link
@@ -2142,7 +2031,7 @@ ac_fn_c_check_type ()
   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
 $as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${$3+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   eval "$3=no"
@@ -2183,7 +2072,7 @@ fi
 eval ac_res=\$$3
 	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
 $as_echo "$ac_res" >&6; }
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
 
 } # ac_fn_c_check_type
 
@@ -2360,7 +2249,7 @@ rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
 rm -f conftest.val
 
   fi
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_c_compute_int
@@ -2373,10 +2262,10 @@ rm -f conftest.val
 ac_fn_c_check_header_mongrel ()
 {
   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-  if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+  if eval \${$3+:} false; then :
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
 $as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${$3+:} false; then :
   $as_echo_n "(cached) " >&6
 fi
 eval ac_res=\$$3
@@ -2412,7 +2301,7 @@ if ac_fn_c_try_cpp "$LINENO"; then :
 else
   ac_header_preproc=no
 fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
 $as_echo "$ac_header_preproc" >&6; }
 
@@ -2435,17 +2324,15 @@ $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
-( cat <<\_ASBOX
-## ------------------------------------- ##
+( $as_echo "## ------------------------------------- ##
 ## Report this to saturne-support at edf.fr ##
-## ------------------------------------- ##
-_ASBOX
+## ------------------------------------- ##"
      ) | sed "s/^/$as_me: WARNING:     /" >&2
     ;;
 esac
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
 $as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${$3+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   eval "$3=\$ac_header_compiler"
@@ -2454,7 +2341,7 @@ eval ac_res=\$$3
 	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
 $as_echo "$ac_res" >&6; }
 fi
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
 
 } # ac_fn_c_check_header_mongrel
 
@@ -2491,7 +2378,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
 
 	ac_retval=1
 fi
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_f77_try_compile
@@ -2537,7 +2424,7 @@ fi
   # interfere with the next link command; also delete a directory that is
   # left behind by Apple's compiler.  We do this before executing the actions.
   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
-  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
   as_fn_set_status $ac_retval
 
 } # ac_fn_f77_try_link
@@ -2545,8 +2432,8 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by ncs $as_me 2.0.0-rc1, which was
-generated by GNU Autoconf 2.65.  Invocation command line was
+It was created by ncs $as_me 2.0.1, which was
+generated by GNU Autoconf 2.68.  Invocation command line was
 
   $ $0 $@
 
@@ -2656,11 +2543,9 @@ trap 'exit_status=$?
   {
     echo
 
-    cat <<\_ASBOX
-## ---------------- ##
+    $as_echo "## ---------------- ##
 ## Cache variables. ##
-## ---------------- ##
-_ASBOX
+## ---------------- ##"
     echo
     # The following way of writing the cache mishandles newlines in values,
 (
@@ -2694,11 +2579,9 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
 )
     echo
 
-    cat <<\_ASBOX
-## ----------------- ##
+    $as_echo "## ----------------- ##
 ## Output variables. ##
-## ----------------- ##
-_ASBOX
+## ----------------- ##"
     echo
     for ac_var in $ac_subst_vars
     do
@@ -2711,11 +2594,9 @@ _ASBOX
     echo
 
     if test -n "$ac_subst_files"; then
-      cat <<\_ASBOX
-## ------------------- ##
+      $as_echo "## ------------------- ##
 ## File substitutions. ##
-## ------------------- ##
-_ASBOX
+## ------------------- ##"
       echo
       for ac_var in $ac_subst_files
       do
@@ -2729,11 +2610,9 @@ _ASBOX
     fi
 
     if test -s confdefs.h; then
-      cat <<\_ASBOX
-## ----------- ##
+      $as_echo "## ----------- ##
 ## confdefs.h. ##
-## ----------- ##
-_ASBOX
+## ----------- ##"
       echo
       cat confdefs.h
       echo
@@ -2788,7 +2667,12 @@ _ACEOF
 ac_site_file1=NONE
 ac_site_file2=NONE
 if test -n "$CONFIG_SITE"; then
-  ac_site_file1=$CONFIG_SITE
+  # We do not want a PATH search for config.site.
+  case $CONFIG_SITE in #((
+    -*)  ac_site_file1=./$CONFIG_SITE;;
+    */*) ac_site_file1=$CONFIG_SITE;;
+    *)   ac_site_file1=./$CONFIG_SITE;;
+  esac
 elif test "x$prefix" != xNONE; then
   ac_site_file1=$prefix/share/config.site
   ac_site_file2=$prefix/etc/config.site
@@ -2803,7 +2687,11 @@ do
     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
     sed 's/^/| /' "$ac_site_file" >&5
-    . "$ac_site_file"
+    . "$ac_site_file" \
+      || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "failed to load site script $ac_site_file
+See \`config.log' for more details" "$LINENO" 5; }
   fi
 done
 
@@ -2880,7 +2768,7 @@ if $ac_cache_corrupted; then
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
-  as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
+  as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
 fi
 ## -------------------- ##
 ## Main body of script. ##
@@ -2898,16 +2786,22 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
 # Use the config directory for libtool stuff ...
 ac_aux_dir=
 for ac_dir in config "$srcdir"/config; do
-  for ac_t in install-sh install.sh shtool; do
-    if test -f "$ac_dir/$ac_t"; then
-      ac_aux_dir=$ac_dir
-      ac_install_sh="$ac_aux_dir/$ac_t -c"
-      break 2
-    fi
-  done
+  if test -f "$ac_dir/install-sh"; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install-sh -c"
+    break
+  elif test -f "$ac_dir/install.sh"; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install.sh -c"
+    break
+  elif test -f "$ac_dir/shtool"; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/shtool install -c"
+    break
+  fi
 done
 if test -z "$ac_aux_dir"; then
-  as_fn_error "cannot find install-sh, install.sh, or shtool in config \"$srcdir\"/config" "$LINENO" 5
+  as_fn_error $? "cannot find install-sh, install.sh, or shtool in config \"$srcdir\"/config" "$LINENO" 5
 fi
 
 # These three variables are undocumented and unsupported,
@@ -2924,27 +2818,27 @@ ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
 
 # Make sure we can run config.sub.
 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
-  as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
+  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
 $as_echo_n "checking build system type... " >&6; }
-if test "${ac_cv_build+set}" = set; then :
+if ${ac_cv_build+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_build_alias=$build_alias
 test "x$ac_build_alias" = x &&
   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
 test "x$ac_build_alias" = x &&
-  as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
+  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
-  as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
+  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
 
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
 $as_echo "$ac_cv_build" >&6; }
 case $ac_cv_build in
 *-*-*) ;;
-*) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
+*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
 esac
 build=$ac_cv_build
 ac_save_IFS=$IFS; IFS='-'
@@ -2962,14 +2856,14 @@ case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
 $as_echo_n "checking host system type... " >&6; }
-if test "${ac_cv_host+set}" = set; then :
+if ${ac_cv_host+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test "x$host_alias" = x; then
   ac_cv_host=$ac_cv_build
 else
   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
-    as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
+    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
 fi
 
 fi
@@ -2977,7 +2871,7 @@ fi
 $as_echo "$ac_cv_host" >&6; }
 case $ac_cv_host in
 *-*-*) ;;
-*) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
+*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
 esac
 host=$ac_cv_host
 ac_save_IFS=$IFS; IFS='-'
@@ -2995,14 +2889,14 @@ case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
 $as_echo_n "checking target system type... " >&6; }
-if test "${ac_cv_target+set}" = set; then :
+if ${ac_cv_target+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test "x$target_alias" = x; then
   ac_cv_target=$ac_cv_host
 else
   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
-    as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
+    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
 fi
 
 fi
@@ -3010,7 +2904,7 @@ fi
 $as_echo "$ac_cv_target" >&6; }
 case $ac_cv_target in
 *-*-*) ;;
-*) as_fn_error "invalid value of canonical target" "$LINENO" 5;;
+*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
 esac
 target=$ac_cv_target
 ac_save_IFS=$IFS; IFS='-'
@@ -3056,7 +2950,7 @@ am__api_version='1.11'
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
 $as_echo_n "checking for a BSD-compatible install... " >&6; }
 if test -z "$INSTALL"; then
-if test "${ac_cv_path_install+set}" = set; then :
+if ${ac_cv_path_install+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3143,11 +3037,11 @@ am_lf='
 '
 case `pwd` in
   *[\\\"\#\$\&\'\`$am_lf]*)
-    as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
+    as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
 esac
 case $srcdir in
   *[\\\"\#\$\&\'\`$am_lf\ \	]*)
-    as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
+    as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
 esac
 
 # Do `set' in a subshell so we don't clobber the current shell's
@@ -3169,7 +3063,7 @@ if (
       # if, for instance, CONFIG_SHELL is bash and it inherits a
       # broken ls alias from the environment.  This has actually
       # happened.  Such a system could not be considered "sane".
-      as_fn_error "ls -t appears to fail.  Make sure there is not a broken
+      as_fn_error $? "ls -t appears to fail.  Make sure there is not a broken
 alias in your environment" "$LINENO" 5
    fi
 
@@ -3179,7 +3073,7 @@ then
    # Ok.
    :
 else
-   as_fn_error "newly created file is older than distributed files!
+   as_fn_error $? "newly created file is older than distributed files!
 Check your system clock" "$LINENO" 5
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
@@ -3233,7 +3127,7 @@ if test "$cross_compiling" != no; then
 set dummy ${ac_tool_prefix}strip; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_STRIP+set}" = set; then :
+if ${ac_cv_prog_STRIP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$STRIP"; then
@@ -3273,7 +3167,7 @@ if test -z "$ac_cv_prog_STRIP"; then
 set dummy strip; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
+if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_STRIP"; then
@@ -3326,7 +3220,7 @@ INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
 if test -z "$MKDIR_P"; then
-  if test "${ac_cv_path_mkdir+set}" = set; then :
+  if ${ac_cv_path_mkdir+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3377,7 +3271,7 @@ do
 set dummy $ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_AWK+set}" = set; then :
+if ${ac_cv_prog_AWK+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$AWK"; then
@@ -3417,7 +3311,7 @@ done
 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
 set x ${MAKE-make}
 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat >conftest.make <<\_ACEOF
@@ -3425,7 +3319,7 @@ SHELL = /bin/sh
 all:
 	@echo '@@@%%%=$(MAKE)=@@@%%%'
 _ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
 case `${MAKE-make} -f conftest.make 2>/dev/null` in
   *@@@%%%=?*=@@@%%%*)
     eval ac_cv_prog_make_${ac_make}_set=yes;;
@@ -3459,7 +3353,7 @@ if test "`cd $srcdir && pwd`" != "`pwd`"; then
   am__isrc=' -I$(srcdir)'
   # test to see if srcdir already configured
   if test -f $srcdir/config.status; then
-    as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
+    as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
   fi
 fi
 
@@ -3475,7 +3369,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='ncs'
- VERSION='2.0.0-rc1'
+ VERSION='2.0.1'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -3540,6 +3434,20 @@ fi
 
 
 
+# Enable silent rules with "./configure --enable-silent-rules" or "make V=0"
+# Check whether --enable-silent-rules was given.
+if test "${enable_silent_rules+set}" = set; then :
+  enableval=$enable_silent_rules;
+fi
+
+case $enable_silent_rules in
+yes) AM_DEFAULT_VERBOSITY=0;;
+no)  AM_DEFAULT_VERBOSITY=1;;
+*)   AM_DEFAULT_VERBOSITY=1;;
+esac
+AM_BACKSLASH='\'
+
+
 #------------------------------------------------------------------------------
 # Checks for programs.
 #------------------------------------------------------------------------------
@@ -3563,7 +3471,7 @@ if test -n "$ac_tool_prefix"; then
 set dummy ${ac_tool_prefix}gcc; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$CC"; then
@@ -3603,7 +3511,7 @@ if test -z "$ac_cv_prog_CC"; then
 set dummy gcc; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
+if ${ac_cv_prog_ac_ct_CC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_CC"; then
@@ -3656,7 +3564,7 @@ if test -z "$CC"; then
 set dummy ${ac_tool_prefix}cc; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$CC"; then
@@ -3696,7 +3604,7 @@ if test -z "$CC"; then
 set dummy cc; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$CC"; then
@@ -3755,7 +3663,7 @@ if test -z "$CC"; then
 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$CC"; then
@@ -3799,7 +3707,7 @@ do
 set dummy $ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
+if ${ac_cv_prog_ac_ct_CC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_CC"; then
@@ -3853,8 +3761,8 @@ fi
 
 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "no acceptable C compiler found in \$PATH
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "no acceptable C compiler found in \$PATH
+See \`config.log' for more details" "$LINENO" 5; }
 
 # Provide some information about the compiler.
 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
@@ -3968,9 +3876,8 @@ sed 's/^/| /' conftest.$ac_ext >&5
 
 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "C compiler cannot create executables
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "C compiler cannot create executables
+See \`config.log' for more details" "$LINENO" 5; }
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
 $as_echo "yes" >&6; }
@@ -4012,8 +3919,8 @@ done
 else
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot compute suffix of executables: cannot compile and link
+See \`config.log' for more details" "$LINENO" 5; }
 fi
 rm -f conftest conftest$ac_cv_exeext
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
@@ -4070,9 +3977,9 @@ $as_echo "$ac_try_echo"; } >&5
     else
 	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot run C compiled programs.
+as_fn_error $? "cannot run C compiled programs.
 If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5; }
     fi
   fi
 fi
@@ -4083,7 +3990,7 @@ rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
 ac_clean_files=$ac_clean_files_save
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
 $as_echo_n "checking for suffix of object files... " >&6; }
-if test "${ac_cv_objext+set}" = set; then :
+if ${ac_cv_objext+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4123,8 +4030,8 @@ sed 's/^/| /' conftest.$ac_ext >&5
 
 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot compute suffix of object files: cannot compile
+See \`config.log' for more details" "$LINENO" 5; }
 fi
 rm -f conftest.$ac_cv_objext conftest.$ac_ext
 fi
@@ -4134,7 +4041,7 @@ OBJEXT=$ac_cv_objext
 ac_objext=$OBJEXT
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if test "${ac_cv_c_compiler_gnu+set}" = set; then :
+if ${ac_cv_c_compiler_gnu+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4171,7 +4078,7 @@ ac_test_CFLAGS=${CFLAGS+set}
 ac_save_CFLAGS=$CFLAGS
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
 $as_echo_n "checking whether $CC accepts -g... " >&6; }
-if test "${ac_cv_prog_cc_g+set}" = set; then :
+if ${ac_cv_prog_cc_g+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_save_c_werror_flag=$ac_c_werror_flag
@@ -4249,7 +4156,7 @@ else
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if test "${ac_cv_prog_cc_c89+set}" = set; then :
+if ${ac_cv_prog_cc_c89+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_cv_prog_cc_c89=no
@@ -4410,7 +4317,7 @@ depcc="$CC"   am_compiler_list=
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
 $as_echo_n "checking dependency style of $depcc... " >&6; }
-if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
+if ${am_cv_CC_dependencies_compiler_type+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
@@ -4538,13 +4445,13 @@ ac_compile='$FC -c $FCFLAGS $ac_fcflags_srcext conftest.$ac_ext >&5'
 ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_fc_compiler_gnu
 if test -n "$ac_tool_prefix"; then
-  for ac_prog in gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn xlf90 f90 pgf90 pghpf epcf90 g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77
+  for ac_prog in gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn xlf90 f90 pgf90 pghpf epcf90 g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77
   do
     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_FC+set}" = set; then :
+if ${ac_cv_prog_FC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$FC"; then
@@ -4582,13 +4489,13 @@ fi
 fi
 if test -z "$FC"; then
   ac_ct_FC=$FC
-  for ac_prog in gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn xlf90 f90 pgf90 pghpf epcf90 g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77
+  for ac_prog in gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn xlf90 f90 pgf90 pghpf epcf90 g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_FC+set}" = set; then :
+if ${ac_cv_prog_ac_ct_FC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_FC"; then
@@ -4670,7 +4577,7 @@ ac_save_ext=$ac_ext
 ac_ext=F
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Fortran compiler" >&5
 $as_echo_n "checking whether we are using the GNU Fortran compiler... " >&6; }
-if test "${ac_cv_fc_compiler_gnu+set}" = set; then :
+if ${ac_cv_fc_compiler_gnu+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat > conftest.$ac_ext <<_ACEOF
@@ -4698,7 +4605,7 @@ ac_save_FCFLAGS=$FCFLAGS
 FCFLAGS=
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $FC accepts -g" >&5
 $as_echo_n "checking whether $FC accepts -g... " >&6; }
-if test "${ac_cv_prog_fc_g+set}" = set; then :
+if ${ac_cv_prog_fc_g+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   FCFLAGS=-g
@@ -4753,7 +4660,7 @@ fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if test "${ac_cv_path_SED+set}" = set; then :
+if ${ac_cv_path_SED+:} false; then :
   $as_echo_n "(cached) " >&6
 else
             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
@@ -4808,7 +4715,7 @@ esac
   done
 IFS=$as_save_IFS
   if test -z "$ac_cv_path_SED"; then
-    as_fn_error "no acceptable sed could be found in \$PATH" "$LINENO" 5
+    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
   fi
 else
   ac_cv_path_SED=$SED
@@ -4828,7 +4735,7 @@ ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest
 ac_compiler_gnu=$ac_cv_fc_compiler_gnu
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get verbose linking output from $FC" >&5
 $as_echo_n "checking how to get verbose linking output from $FC... " >&6; }
-if test "${ac_cv_prog_fc_v+set}" = set; then :
+if ${ac_cv_prog_fc_v+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat > conftest.$ac_ext <<_ACEOF
@@ -4858,7 +4765,8 @@ $as_echo "$as_me:${as_lineno-$LINENO}: $*" >&5
 # gfortran 4.3 outputs lines setting COLLECT_GCC_OPTIONS, COMPILER_PATH,
 # LIBRARY_PATH; skip all such settings.
 ac_fc_v_output=`eval $ac_link 5>&1 2>&1 |
-  grep -v 'Driving:' | grep -v "^[_$as_cr_Letters][_$as_cr_alnum]*="`
+  sed '/^Driving:/d; /^Configured with:/d;
+      '"/^[_$as_cr_Letters][_$as_cr_alnum]*=/d"`
 $as_echo "$ac_fc_v_output" >&5
 FCFLAGS=$ac_save_FCFLAGS
 
@@ -4923,7 +4831,7 @@ fi
 $as_echo "$ac_cv_prog_fc_v" >&6; }
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Fortran libraries of $FC" >&5
 $as_echo_n "checking for Fortran libraries of $FC... " >&6; }
-if test "${ac_cv_fc_libs+set}" = set; then :
+if ${ac_cv_fc_libs+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test "x$FCLIBS" != "x"; then
@@ -4948,7 +4856,8 @@ $as_echo "$as_me:${as_lineno-$LINENO}: $*" >&5
 # gfortran 4.3 outputs lines setting COLLECT_GCC_OPTIONS, COMPILER_PATH,
 # LIBRARY_PATH; skip all such settings.
 ac_fc_v_output=`eval $ac_link 5>&1 2>&1 |
-  grep -v 'Driving:' | grep -v "^[_$as_cr_Letters][_$as_cr_alnum]*="`
+  sed '/^Driving:/d; /^Configured with:/d;
+      '"/^[_$as_cr_Letters][_$as_cr_alnum]*=/d"`
 $as_echo "$ac_fc_v_output" >&5
 FCFLAGS=$ac_save_FCFLAGS
 
@@ -5038,7 +4947,7 @@ fi
 	  ;;
 	  # Ignore these flags.
 	-lang* | -lcrt*.o | -lc | -lgcc* | -lSystem | -libmil | -little \
-	  |-LANG:=* | -LIST:* | -LNO:*)
+	  |-LANG:=* | -LIST:* | -LNO:* | -link)
 	  ;;
 	-lkernel32)
 	  test x"$CYGWIN" != xyes && ac_cv_fc_libs="$ac_cv_fc_libs $ac_arg"
@@ -5138,7 +5047,7 @@ if test "${enable_debug+set}" = set; then :
     case "${enableval}" in
       yes) debug=true ;;
       no)  debug=false ;;
-      *)   as_fn_error "bad value ${enableval} for --enable-debug" "$LINENO" 5 ;;
+      *)   as_fn_error $? "bad value ${enableval} for --enable-debug" "$LINENO" 5 ;;
     esac
 
 else
@@ -5155,7 +5064,7 @@ if test "${enable_auto_flags+set}" = set; then :
     case "${enableval}" in
       yes) auto_flags=true ;;
       no)  auto_flags=false ;;
-      *)   as_fn_error "bad value ${enableval} for --enable-auto-flags" "$LINENO" 5 ;;
+      *)   as_fn_error $? "bad value ${enableval} for --enable-auto-flags" "$LINENO" 5 ;;
     esac
 
 else
@@ -5172,7 +5081,7 @@ if test "${enable_french+set}" = set; then :
     case "${enableval}" in
       yes) french=true ;;
       no)  french=false ;;
-      *)   as_fn_error "bad value ${enableval} for --enable-french" "$LINENO" 5 ;;
+      *)   as_fn_error $? "bad value ${enableval} for --enable-french" "$LINENO" 5 ;;
     esac
 
 else
@@ -5269,7 +5178,11 @@ fi
 # Fortran flags for French translation
 
 if test "x$french" = "xtrue"; then
-  FCFLAGS="${FCFLAGS} -D_CS_LANG_FR"
+  if test "x$cs_ibm_bg_type" != "x" ; then
+    FCFLAGS="${FCFLAGS} -WF,-D_CS_LANG_FR"
+  else
+    FCFLAGS="${FCFLAGS} -D_CS_LANG_FR"
+  fi
 fi
 
 # We may only turn on processing for libtool now that the basic compiler
@@ -5281,7 +5194,7 @@ fi
 # take effect whether the result is true or not (maybe due to a bug),
 # so we directly use autoconf's enable_shared variable.
 
-if test "x$cs_disable_shared" = "xyes" ; then
+if test "x$cs_ibm_bg_type" != "x" ; then
    enable_shared=no
 fi
 
@@ -5293,8 +5206,8 @@ esac
 
 
 
-macro_version='2.2.6b'
-macro_revision='1.3017'
+macro_version='2.4'
+macro_revision='1.3293'
 
 
 
@@ -5310,9 +5223,78 @@ macro_revision='1.3017'
 
 ltmain="$ac_aux_dir/ltmain.sh"
 
+# Backslashify metacharacters that are still active within
+# double-quoted strings.
+sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
+
+# Same as above, but do not quote variable references.
+double_quote_subst='s/\(["`\\]\)/\\\1/g'
+
+# Sed substitution to delay expansion of an escaped shell variable in a
+# double_quote_subst'ed string.
+delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
+
+# Sed substitution to delay expansion of an escaped single quote.
+delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
+
+# Sed substitution to avoid accidental globbing in evaled expressions
+no_glob_subst='s/\*/\\\*/g'
+
+ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
+ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
+$as_echo_n "checking how to print strings... " >&6; }
+# Test print first, because it will be a builtin if present.
+if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
+   test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
+  ECHO='print -r --'
+elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
+  ECHO='printf %s\n'
+else
+  # Use this function as a fallback that always works.
+  func_fallback_echo ()
+  {
+    eval 'cat <<_LTECHO_EOF
+$1
+_LTECHO_EOF'
+  }
+  ECHO='func_fallback_echo'
+fi
+
+# func_echo_all arg...
+# Invoke $ECHO with all args, space-separated.
+func_echo_all ()
+{
+    $ECHO ""
+}
+
+case "$ECHO" in
+  printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
+$as_echo "printf" >&6; } ;;
+  print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
+$as_echo "print -r" >&6; } ;;
+  *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
+$as_echo "cat" >&6; } ;;
+esac
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if test "${ac_cv_path_SED+set}" = set; then :
+if ${ac_cv_path_SED+:} false; then :
   $as_echo_n "(cached) " >&6
 else
             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
@@ -5367,7 +5349,7 @@ esac
   done
 IFS=$as_save_IFS
   if test -z "$ac_cv_path_SED"; then
-    as_fn_error "no acceptable sed could be found in \$PATH" "$LINENO" 5
+    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
   fi
 else
   ac_cv_path_SED=$SED
@@ -5394,7 +5376,7 @@ Xsed="$SED -e 1s/^X//"
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if test "${ac_cv_path_GREP+set}" = set; then :
+if ${ac_cv_path_GREP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -z "$GREP"; then
@@ -5443,7 +5425,7 @@ esac
   done
 IFS=$as_save_IFS
   if test -z "$ac_cv_path_GREP"; then
-    as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
   fi
 else
   ac_cv_path_GREP=$GREP
@@ -5457,7 +5439,7 @@ $as_echo "$ac_cv_path_GREP" >&6; }
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
 $as_echo_n "checking for egrep... " >&6; }
-if test "${ac_cv_path_EGREP+set}" = set; then :
+if ${ac_cv_path_EGREP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
@@ -5509,7 +5491,7 @@ esac
   done
 IFS=$as_save_IFS
   if test -z "$ac_cv_path_EGREP"; then
-    as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
   fi
 else
   ac_cv_path_EGREP=$EGREP
@@ -5524,7 +5506,7 @@ $as_echo "$ac_cv_path_EGREP" >&6; }
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
 $as_echo_n "checking for fgrep... " >&6; }
-if test "${ac_cv_path_FGREP+set}" = set; then :
+if ${ac_cv_path_FGREP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
@@ -5576,7 +5558,7 @@ esac
   done
 IFS=$as_save_IFS
   if test -z "$ac_cv_path_FGREP"; then
-    as_fn_error "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+    as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
   fi
 else
   ac_cv_path_FGREP=$FGREP
@@ -5655,7 +5637,7 @@ else
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
 $as_echo_n "checking for non-GNU ld... " >&6; }
 fi
-if test "${lt_cv_path_LD+set}" = set; then :
+if ${lt_cv_path_LD+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -z "$LD"; then
@@ -5692,10 +5674,10 @@ else
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 fi
-test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5
+test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if test "${lt_cv_prog_gnu_ld+set}" = set; then :
+if ${lt_cv_prog_gnu_ld+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   # I'd rather use --version here, but apparently some GNU lds only accept -v.
@@ -5722,7 +5704,7 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if test "${lt_cv_path_NM+set}" = set; then :
+if ${lt_cv_path_NM+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$NM"; then
@@ -5775,14 +5757,17 @@ if test "$lt_cv_path_NM" != "no"; then
   NM="$lt_cv_path_NM"
 else
   # Didn't find any BSD compatible name lister, look for dumpbin.
-  if test -n "$ac_tool_prefix"; then
-  for ac_prog in "dumpbin -symbols" "link -dump -symbols"
+  if test -n "$DUMPBIN"; then :
+    # Let the user override the test.
+  else
+    if test -n "$ac_tool_prefix"; then
+  for ac_prog in dumpbin "link -dump"
   do
     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_DUMPBIN+set}" = set; then :
+if ${ac_cv_prog_DUMPBIN+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$DUMPBIN"; then
@@ -5820,13 +5805,13 @@ fi
 fi
 if test -z "$DUMPBIN"; then
   ac_ct_DUMPBIN=$DUMPBIN
-  for ac_prog in "dumpbin -symbols" "link -dump -symbols"
+  for ac_prog in dumpbin "link -dump"
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_DUMPBIN+set}" = set; then :
+if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_DUMPBIN"; then
@@ -5875,6 +5860,15 @@ esac
   fi
 fi
 
+    case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
+    *COFF*)
+      DUMPBIN="$DUMPBIN -symbols"
+      ;;
+    *)
+      DUMPBIN=:
+      ;;
+    esac
+  fi
 
   if test "$DUMPBIN" != ":"; then
     NM="$DUMPBIN"
@@ -5889,18 +5883,18 @@ test -z "$NM" && NM=nm
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if test "${lt_cv_nm_interface+set}" = set; then :
+if ${lt_cv_nm_interface+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_nm_interface="BSD nm"
   echo "int some_variable = 0;" > conftest.$ac_ext
-  (eval echo "\"\$as_me:5897: $ac_compile\"" >&5)
+  (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
   (eval "$ac_compile" 2>conftest.err)
   cat conftest.err >&5
-  (eval echo "\"\$as_me:5900: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
+  (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
   cat conftest.err >&5
-  (eval echo "\"\$as_me:5903: output\"" >&5)
+  (eval echo "\"\$as_me:$LINENO: output\"" >&5)
   cat conftest.out >&5
   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
     lt_cv_nm_interface="MS dumpbin"
@@ -5913,7 +5907,7 @@ $as_echo "$lt_cv_nm_interface" >&6; }
 # find the maximum length of command line arguments
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if test "${lt_cv_sys_max_cmd_len+set}" = set; then :
+if ${lt_cv_sys_max_cmd_len+:} false; then :
   $as_echo_n "(cached) " >&6
 else
     i=0
@@ -5946,6 +5940,11 @@ else
     lt_cv_sys_max_cmd_len=8192;
     ;;
 
+  mint*)
+    # On MiNT this can take a long time and run out of memory.
+    lt_cv_sys_max_cmd_len=8192;
+    ;;
+
   amigaos*)
     # On AmigaOS with pdksh, this test takes hours, literally.
     # So we just punt and use a minimum line length of 8192.
@@ -6010,8 +6009,8 @@ else
       # If test is not a shell built-in, we'll probably end up computing a
       # maximum length that is only half of the actual maximum length, but
       # we can't tell.
-      while { test "X"`$SHELL $0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
-	         = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
+      while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
+	         = "X$teststring$teststring"; } >/dev/null 2>&1 &&
 	      test $i != 17 # 1/2 MB should be enough
       do
         i=`expr $i + 1`
@@ -6053,8 +6052,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
 # Try some XSI features
 xsi_shell=no
 ( _lt_dummy="a/b/c"
-  test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
-      = c,a/b,, \
+  test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
+      = c,a/b,b/c, \
     && eval 'test $(( 1 + 1 )) -eq 2 \
     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
   && xsi_shell=yes
@@ -6103,9 +6102,83 @@ esac
 
 
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
+$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
+if ${lt_cv_to_host_file_cmd+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  case $host in
+  *-*-mingw* )
+    case $build in
+      *-*-mingw* ) # actually msys
+        lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
+        ;;
+      *-*-cygwin* )
+        lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
+        ;;
+      * ) # otherwise, assume *nix
+        lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
+        ;;
+    esac
+    ;;
+  *-*-cygwin* )
+    case $build in
+      *-*-mingw* ) # actually msys
+        lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
+        ;;
+      *-*-cygwin* )
+        lt_cv_to_host_file_cmd=func_convert_file_noop
+        ;;
+      * ) # otherwise, assume *nix
+        lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
+        ;;
+    esac
+    ;;
+  * ) # unhandled hosts (and "normal" native builds)
+    lt_cv_to_host_file_cmd=func_convert_file_noop
+    ;;
+esac
+
+fi
+
+to_host_file_cmd=$lt_cv_to_host_file_cmd
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
+$as_echo "$lt_cv_to_host_file_cmd" >&6; }
+
+
+
+
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
+$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
+if ${lt_cv_to_tool_file_cmd+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  #assume ordinary cross tools, or native build.
+lt_cv_to_tool_file_cmd=func_convert_file_noop
+case $host in
+  *-*-mingw* )
+    case $build in
+      *-*-mingw* ) # actually msys
+        lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
+        ;;
+    esac
+    ;;
+esac
+
+fi
+
+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
+$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
+
+
+
+
+
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
 $as_echo_n "checking for $LD option to reload object files... " >&6; }
-if test "${lt_cv_ld_reload_flag+set}" = set; then :
+if ${lt_cv_ld_reload_flag+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_ld_reload_flag='-r'
@@ -6119,6 +6192,11 @@ case $reload_flag in
 esac
 reload_cmds='$LD$reload_flag -o $output$reload_objs'
 case $host_os in
+  cygwin* | mingw* | pw32* | cegcc*)
+    if test "$GCC" != yes; then
+      reload_cmds=false
+    fi
+    ;;
   darwin*)
     if test "$GCC" = yes; then
       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
@@ -6141,7 +6219,7 @@ if test -n "$ac_tool_prefix"; then
 set dummy ${ac_tool_prefix}objdump; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_OBJDUMP+set}" = set; then :
+if ${ac_cv_prog_OBJDUMP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$OBJDUMP"; then
@@ -6181,7 +6259,7 @@ if test -z "$ac_cv_prog_OBJDUMP"; then
 set dummy objdump; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then :
+if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_OBJDUMP"; then
@@ -6240,7 +6318,7 @@ test -z "$OBJDUMP" && OBJDUMP=objdump
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if test "${lt_cv_deplibs_check_method+set}" = set; then :
+if ${lt_cv_deplibs_check_method+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_file_magic_cmd='$MAGIC_CMD'
@@ -6282,16 +6360,18 @@ mingw* | pw32*)
   # Base MSYS/MinGW do not provide the 'file' command needed by
   # func_win32_libid shell function, so use a weaker test based on 'objdump',
   # unless we find 'file', for example because we are cross-compiling.
-  if ( file / ) >/dev/null 2>&1; then
+  # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
+  if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
     lt_cv_file_magic_cmd='func_win32_libid'
   else
-    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
+    # Keep this pattern in sync with the one in func_win32_libid.
+    lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
     lt_cv_file_magic_cmd='$OBJDUMP -f'
   fi
   ;;
 
-cegcc)
+cegcc*)
   # use the weaker test based on 'objdump'. See mingw*.
   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
   lt_cv_file_magic_cmd='$OBJDUMP -f'
@@ -6321,6 +6401,10 @@ gnu*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
+haiku*)
+  lt_cv_deplibs_check_method=pass_all
+  ;;
+
 hpux10.20* | hpux11*)
   lt_cv_file_magic_cmd=/usr/bin/file
   case $host_cpu in
@@ -6329,11 +6413,11 @@ hpux10.20* | hpux11*)
     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
     ;;
   hppa*64*)
-    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'
+    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
     ;;
   *)
-    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
+    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
     lt_cv_file_magic_test_file=/usr/lib/libc.sl
     ;;
   esac
@@ -6355,7 +6439,7 @@ irix5* | irix6* | nonstopux*)
   ;;
 
 # This must be Linux ELF.
-linux* | k*bsd*-gnu)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -6436,6 +6520,21 @@ esac
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
 $as_echo "$lt_cv_deplibs_check_method" >&6; }
+
+file_magic_glob=
+want_nocaseglob=no
+if test "$build" = "$host"; then
+  case $host_os in
+  mingw* | pw32*)
+    if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
+      want_nocaseglob=yes
+    else
+      file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
+    fi
+    ;;
+  esac
+fi
+
 file_magic_cmd=$lt_cv_file_magic_cmd
 deplibs_check_method=$lt_cv_deplibs_check_method
 test -z "$deplibs_check_method" && deplibs_check_method=unknown
@@ -6451,16 +6550,26 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
 
 
 
+
+
+
+
+
+
+
+
+
+
 if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
+  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_AR+set}" = set; then :
+if ${ac_cv_prog_DLLTOOL+:} false; then :
   $as_echo_n "(cached) " >&6
 else
-  if test -n "$AR"; then
-  ac_cv_prog_AR="$AR" # Let the user override the test.
+  if test -n "$DLLTOOL"; then
+  ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
 else
 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 for as_dir in $PATH
@@ -6469,7 +6578,7 @@ do
   test -z "$as_dir" && as_dir=.
     for ac_exec_ext in '' $ac_executable_extensions; do
   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_AR="${ac_tool_prefix}ar"
+    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
@@ -6479,10 +6588,10 @@ IFS=$as_save_IFS
 
 fi
 fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
+DLLTOOL=$ac_cv_prog_DLLTOOL
+if test -n "$DLLTOOL"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
+$as_echo "$DLLTOOL" >&6; }
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
@@ -6490,17 +6599,17 @@ fi
 
 
 fi
-if test -z "$ac_cv_prog_AR"; then
-  ac_ct_AR=$AR
-  # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
+if test -z "$ac_cv_prog_DLLTOOL"; then
+  ac_ct_DLLTOOL=$DLLTOOL
+  # Extract the first word of "dlltool", so it can be a program name with args.
+set dummy dlltool; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
+if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
   $as_echo_n "(cached) " >&6
 else
-  if test -n "$ac_ct_AR"; then
-  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
+  if test -n "$ac_ct_DLLTOOL"; then
+  ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
 else
 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 for as_dir in $PATH
@@ -6509,7 +6618,7 @@ do
   test -z "$as_dir" && as_dir=.
     for ac_exec_ext in '' $ac_executable_extensions; do
   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_AR="ar"
+    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
@@ -6519,17 +6628,17 @@ IFS=$as_save_IFS
 
 fi
 fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
+if test -n "$ac_ct_DLLTOOL"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
+$as_echo "$ac_ct_DLLTOOL" >&6; }
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 fi
 
-  if test "x$ac_ct_AR" = x; then
-    AR="false"
+  if test "x$ac_ct_DLLTOOL" = x; then
+    DLLTOOL="false"
   else
     case $cross_compiling:$ac_tool_warned in
 yes:)
@@ -6537,17 +6646,54 @@ yes:)
 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
 ac_tool_warned=yes ;;
 esac
-    AR=$ac_ct_AR
+    DLLTOOL=$ac_ct_DLLTOOL
   fi
 else
-  AR="$ac_cv_prog_AR"
+  DLLTOOL="$ac_cv_prog_DLLTOOL"
 fi
 
-test -z "$AR" && AR=ar
-test -z "$AR_FLAGS" && AR_FLAGS=cru
+test -z "$DLLTOOL" && DLLTOOL=dlltool
+
+
+
+
+
+
+
+
+
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
+$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
+if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_sharedlib_from_linklib_cmd='unknown'
 
+case $host_os in
+cygwin* | mingw* | pw32* | cegcc*)
+  # two different shell functions defined in ltmain.sh
+  # decide which to use based on capabilities of $DLLTOOL
+  case `$DLLTOOL --help 2>&1` in
+  *--identify-strict*)
+    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
+    ;;
+  *)
+    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
+    ;;
+  esac
+  ;;
+*)
+  # fallback: assume linklib IS sharedlib
+  lt_cv_sharedlib_from_linklib_cmd="$ECHO"
+  ;;
+esac
 
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
+$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
+sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
+test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
 
 
 
@@ -6557,15 +6703,17 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
 
 
 if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
+  for ac_prog in ar
+  do
+    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_STRIP+set}" = set; then :
+if ${ac_cv_prog_AR+:} false; then :
   $as_echo_n "(cached) " >&6
 else
-  if test -n "$STRIP"; then
-  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
+  if test -n "$AR"; then
+  ac_cv_prog_AR="$AR" # Let the user override the test.
 else
 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 for as_dir in $PATH
@@ -6574,7 +6722,7 @@ do
   test -z "$as_dir" && as_dir=.
     for ac_exec_ext in '' $ac_executable_extensions; do
   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
+    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
@@ -6584,10 +6732,179 @@ IFS=$as_save_IFS
 
 fi
 fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
+AR=$ac_cv_prog_AR
+if test -n "$AR"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
+$as_echo "$AR" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+    test -n "$AR" && break
+  done
+fi
+if test -z "$AR"; then
+  ac_ct_AR=$AR
+  for ac_prog in ar
+do
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_prog_ac_ct_AR+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$ac_ct_AR"; then
+  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_AR="$ac_prog"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_AR=$ac_cv_prog_ac_ct_AR
+if test -n "$ac_ct_AR"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
+$as_echo "$ac_ct_AR" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+  test -n "$ac_ct_AR" && break
+done
+
+  if test "x$ac_ct_AR" = x; then
+    AR="false"
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+    AR=$ac_ct_AR
+  fi
+fi
+
+: ${AR=ar}
+: ${AR_FLAGS=cru}
+
+
+
+
+
+
+
+
+
+
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
+$as_echo_n "checking for archiver @FILE support... " >&6; }
+if ${lt_cv_ar_at_file+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_ar_at_file=no
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  echo conftest.$ac_objext > conftest.lst
+      lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
+      { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
+  (eval $lt_ar_try) 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }
+      if test "$ac_status" -eq 0; then
+	# Ensure the archiver fails upon bogus file names.
+	rm -f conftest.$ac_objext libconftest.a
+	{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
+  (eval $lt_ar_try) 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }
+	if test "$ac_status" -ne 0; then
+          lt_cv_ar_at_file=@
+        fi
+      fi
+      rm -f conftest.* libconftest.a
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
+$as_echo "$lt_cv_ar_at_file" >&6; }
+
+if test "x$lt_cv_ar_at_file" = xno; then
+  archiver_list_spec=
+else
+  archiver_list_spec=$lt_cv_ar_at_file
+fi
+
+
+
+
+
+
+
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
+set dummy ${ac_tool_prefix}strip; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_prog_STRIP+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$STRIP"; then
+  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+STRIP=$ac_cv_prog_STRIP
+if test -n "$STRIP"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
+$as_echo "$STRIP" >&6; }
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
@@ -6601,7 +6918,7 @@ if test -z "$ac_cv_prog_STRIP"; then
 set dummy strip; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
+if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_STRIP"; then
@@ -6660,7 +6977,7 @@ if test -n "$ac_tool_prefix"; then
 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_RANLIB+set}" = set; then :
+if ${ac_cv_prog_RANLIB+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$RANLIB"; then
@@ -6700,7 +7017,7 @@ if test -z "$ac_cv_prog_RANLIB"; then
 set dummy ranlib; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
+if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_RANLIB"; then
@@ -6771,6 +7088,18 @@ if test -n "$RANLIB"; then
   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
 fi
 
+case $host_os in
+  darwin*)
+    lock_old_archive_extraction=yes ;;
+  *)
+    lock_old_archive_extraction=no ;;
+esac
+
+
+
+
+
+
 
 
 
@@ -6817,7 +7146,7 @@ compiler=$CC
 # Check for command to grab the raw symbol name followed by C symbol from nm.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then :
+if ${lt_cv_sys_global_symbol_pipe+:} false; then :
   $as_echo_n "(cached) " >&6
 else
 
@@ -6878,8 +7207,8 @@ esac
 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
 
 # Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
+lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (void *) \&\2},/p'"
+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
 
 # Handle CRLF in mingw tool chain
 opt_cr=
@@ -6915,6 +7244,7 @@ for ac_symprfx in "" "_"; do
   else
     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
   fi
+  lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
 
   # Check to see that the pipe works correctly.
   pipe_works=no
@@ -6940,8 +7270,8 @@ _LT_EOF
   test $ac_status = 0; }; then
     # Now try to grab the symbols.
     nlist=conftest.nm
-    if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\""; } >&5
-  (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
+    if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
+  (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; } && test -s "$nlist"; then
@@ -6956,6 +7286,18 @@ _LT_EOF
       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
 	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
 	  cat <<_LT_EOF > conftest.$ac_ext
+/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
+#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
+/* DATA imports from DLLs on WIN32 con't be const, because runtime
+   relocations are performed -- see ld's documentation on pseudo-relocs.  */
+# define LT_DLSYM_CONST
+#elif defined(__osf__)
+/* This system does not cope well with relocations in const data.  */
+# define LT_DLSYM_CONST
+#else
+# define LT_DLSYM_CONST const
+#endif
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -6967,7 +7309,7 @@ _LT_EOF
 	  cat <<_LT_EOF >> conftest.$ac_ext
 
 /* The mapping between symbol names and symbols.  */
-const struct {
+LT_DLSYM_CONST struct {
   const char *name;
   void       *address;
 }
@@ -6993,8 +7335,8 @@ static const void *lt_preloaded_setup() {
 _LT_EOF
 	  # Now try linking the two files.
 	  mv conftest.$ac_objext conftstm.$ac_objext
-	  lt_save_LIBS="$LIBS"
-	  lt_save_CFLAGS="$CFLAGS"
+	  lt_globsym_save_LIBS=$LIBS
+	  lt_globsym_save_CFLAGS=$CFLAGS
 	  LIBS="conftstm.$ac_objext"
 	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
 	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
@@ -7004,8 +7346,8 @@ _LT_EOF
   test $ac_status = 0; } && test -s conftest${ac_exeext}; then
 	    pipe_works=yes
 	  fi
-	  LIBS="$lt_save_LIBS"
-	  CFLAGS="$lt_save_CFLAGS"
+	  LIBS=$lt_globsym_save_LIBS
+	  CFLAGS=$lt_globsym_save_CFLAGS
 	else
 	  echo "cannot find nm_test_func in $nlist" >&5
 	fi
@@ -7042,6 +7384,12 @@ else
 $as_echo "ok" >&6; }
 fi
 
+# Response file support.
+if test "$lt_cv_nm_interface" = "MS dumpbin"; then
+  nm_file_list_spec='@'
+elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
+  nm_file_list_spec='@'
+fi
 
 
 
@@ -7064,6 +7412,48 @@ fi
 
 
 
+
+
+
+
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
+$as_echo_n "checking for sysroot... " >&6; }
+
+# Check whether --with-sysroot was given.
+if test "${with_sysroot+set}" = set; then :
+  withval=$with_sysroot;
+else
+  with_sysroot=no
+fi
+
+
+lt_sysroot=
+case ${with_sysroot} in #(
+ yes)
+   if test "$GCC" = yes; then
+     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
+   fi
+   ;; #(
+ /*)
+   lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
+   ;; #(
+ no|'')
+   ;; #(
+ *)
+   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5
+$as_echo "${with_sysroot}" >&6; }
+   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
+   ;;
+esac
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
+$as_echo "${lt_sysroot:-no}" >&6; }
+
+
+
+
+
 # Check whether --enable-libtool-lock was given.
 if test "${enable_libtool_lock+set}" = set; then :
   enableval=$enable_libtool_lock;
@@ -7095,7 +7485,7 @@ ia64-*-hpux*)
   ;;
 *-*-irix6*)
   # Find out which ABI we are using.
-  echo '#line 7098 "configure"' > conftest.$ac_ext
+  echo '#line '$LINENO' "configure"' > conftest.$ac_ext
   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
@@ -7189,7 +7579,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
   CFLAGS="$CFLAGS -belf"
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if test "${lt_cv_cc_needs_belf+set}" = set; then :
+if ${lt_cv_cc_needs_belf+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_ext=c
@@ -7257,6 +7647,123 @@ esac
 
 need_locks="$enable_libtool_lock"
 
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
+set dummy ${ac_tool_prefix}mt; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$MANIFEST_TOOL"; then
+  ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
+if test -n "$MANIFEST_TOOL"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
+$as_echo "$MANIFEST_TOOL" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+fi
+if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
+  ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
+  # Extract the first word of "mt", so it can be a program name with args.
+set dummy mt; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$ac_ct_MANIFEST_TOOL"; then
+  ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
+if test -n "$ac_ct_MANIFEST_TOOL"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
+$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+  if test "x$ac_ct_MANIFEST_TOOL" = x; then
+    MANIFEST_TOOL=":"
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+    MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
+  fi
+else
+  MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
+fi
+
+test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
+$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
+if ${lt_cv_path_mainfest_tool+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_path_mainfest_tool=no
+  echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
+  $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
+  cat conftest.err >&5
+  if $GREP 'Manifest Tool' conftest.out > /dev/null; then
+    lt_cv_path_mainfest_tool=yes
+  fi
+  rm -f conftest*
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
+$as_echo "$lt_cv_path_mainfest_tool" >&6; }
+if test "x$lt_cv_path_mainfest_tool" != xyes; then
+  MANIFEST_TOOL=:
+fi
+
+
+
+
+
 
   case $host_os in
     rhapsody* | darwin*)
@@ -7265,7 +7772,7 @@ need_locks="$enable_libtool_lock"
 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_DSYMUTIL+set}" = set; then :
+if ${ac_cv_prog_DSYMUTIL+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$DSYMUTIL"; then
@@ -7305,7 +7812,7 @@ if test -z "$ac_cv_prog_DSYMUTIL"; then
 set dummy dsymutil; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then :
+if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_DSYMUTIL"; then
@@ -7357,7 +7864,7 @@ fi
 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_NMEDIT+set}" = set; then :
+if ${ac_cv_prog_NMEDIT+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$NMEDIT"; then
@@ -7397,7 +7904,7 @@ if test -z "$ac_cv_prog_NMEDIT"; then
 set dummy nmedit; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then :
+if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_NMEDIT"; then
@@ -7449,7 +7956,7 @@ fi
 set dummy ${ac_tool_prefix}lipo; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_LIPO+set}" = set; then :
+if ${ac_cv_prog_LIPO+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$LIPO"; then
@@ -7489,7 +7996,7 @@ if test -z "$ac_cv_prog_LIPO"; then
 set dummy lipo; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_LIPO+set}" = set; then :
+if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_LIPO"; then
@@ -7541,7 +8048,7 @@ fi
 set dummy ${ac_tool_prefix}otool; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_OTOOL+set}" = set; then :
+if ${ac_cv_prog_OTOOL+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$OTOOL"; then
@@ -7581,7 +8088,7 @@ if test -z "$ac_cv_prog_OTOOL"; then
 set dummy otool; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_OTOOL+set}" = set; then :
+if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_OTOOL"; then
@@ -7633,7 +8140,7 @@ fi
 set dummy ${ac_tool_prefix}otool64; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_OTOOL64+set}" = set; then :
+if ${ac_cv_prog_OTOOL64+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$OTOOL64"; then
@@ -7673,7 +8180,7 @@ if test -z "$ac_cv_prog_OTOOL64"; then
 set dummy otool64; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_OTOOL64+set}" = set; then :
+if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_OTOOL64"; then
@@ -7748,7 +8255,7 @@ fi
 
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
 $as_echo_n "checking for -single_module linker flag... " >&6; }
-if test "${lt_cv_apple_cc_single_mod+set}" = set; then :
+if ${lt_cv_apple_cc_single_mod+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_apple_cc_single_mod=no
@@ -7777,7 +8284,7 @@ fi
 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if test "${lt_cv_ld_exported_symbols_list+set}" = set; then :
+if ${lt_cv_ld_exported_symbols_list+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_ld_exported_symbols_list=no
@@ -7807,6 +8314,38 @@ rm -f core conftest.err conftest.$ac_objext \
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
+$as_echo_n "checking for -force_load linker flag... " >&6; }
+if ${lt_cv_ld_force_load+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_ld_force_load=no
+      cat > conftest.c << _LT_EOF
+int forced_loaded() { return 2;}
+_LT_EOF
+      echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
+      $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
+      echo "$AR cru libconftest.a conftest.o" >&5
+      $AR cru libconftest.a conftest.o 2>&5
+      echo "$RANLIB libconftest.a" >&5
+      $RANLIB libconftest.a 2>&5
+      cat > conftest.c << _LT_EOF
+int main() { return 0;}
+_LT_EOF
+      echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
+      $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
+      _lt_result=$?
+      if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
+	lt_cv_ld_force_load=yes
+      else
+	cat conftest.err >&5
+      fi
+        rm -f conftest.err libconftest.a conftest conftest.c
+        rm -rf conftest.dSYM
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
+$as_echo "$lt_cv_ld_force_load" >&6; }
     case $host_os in
     rhapsody* | darwin1.[012])
       _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
@@ -7834,7 +8373,7 @@ $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
     else
       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
     fi
-    if test "$DSYMUTIL" != ":"; then
+    if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
       _lt_dsymutil='~$DSYMUTIL $lib || :'
     else
       _lt_dsymutil=
@@ -7854,7 +8393,7 @@ if test -n "$CPP" && test -d "$CPP"; then
   CPP=
 fi
 if test -z "$CPP"; then
-  if test "${ac_cv_prog_CPP+set}" = set; then :
+  if ${ac_cv_prog_CPP+:} false; then :
   $as_echo_n "(cached) " >&6
 else
       # Double quotes because CPP needs to be expanded
@@ -7884,7 +8423,7 @@ else
   # Broken: fails on valid input.
 continue
 fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
 
   # OK, works on sane cases.  Now check whether nonexistent headers
   # can be detected and how.
@@ -7900,11 +8439,11 @@ else
 ac_preproc_ok=:
 break
 fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
 
 done
 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.i conftest.err conftest.$ac_ext
 if $ac_preproc_ok; then :
   break
 fi
@@ -7943,7 +8482,7 @@ else
   # Broken: fails on valid input.
 continue
 fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
 
   # OK, works on sane cases.  Now check whether nonexistent headers
   # can be detected and how.
@@ -7959,18 +8498,18 @@ else
 ac_preproc_ok=:
 break
 fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
 
 done
 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.i conftest.err conftest.$ac_ext
 if $ac_preproc_ok; then :
 
 else
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
+See \`config.log' for more details" "$LINENO" 5; }
 fi
 
 ac_ext=c
@@ -7982,7 +8521,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
 $as_echo_n "checking for ANSI C header files... " >&6; }
-if test "${ac_cv_header_stdc+set}" = set; then :
+if ${ac_cv_header_stdc+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -8059,282 +8598,80 @@ else
 		     || ('j' <= (c) && (c) <= 'r') \
 		     || ('s' <= (c) && (c) <= 'z'))
 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
-  int i;
-  for (i = 0; i < 256; i++)
-    if (XOR (islower (i), ISLOWER (i))
-	|| toupper (i) != TOUPPER (i))
-      return 2;
-  return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
-  ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
-  conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
-		  inttypes.h stdint.h unistd.h
-do :
-  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-eval as_val=\$$as_ac_Header
-   if test "x$as_val" = x""yes; then :
-  cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-for ac_header in dlfcn.h
-do :
-  ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = x""yes; then :
-  cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-
-
-ac_ext=${ac_fc_srcext-f}
-ac_compile='$FC -c $FCFLAGS $ac_fcflags_srcext conftest.$ac_ext >&5'
-ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_fc_compiler_gnu
-if test -n "$ac_tool_prefix"; then
-  for ac_prog in gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn xlf90 f90 pgf90 pghpf epcf90 g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77
-  do
-    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_FC+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  if test -n "$FC"; then
-  ac_cv_prog_FC="$FC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-    for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_FC="$ac_tool_prefix$ac_prog"
-    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-  done
-IFS=$as_save_IFS
-
-fi
-fi
-FC=$ac_cv_prog_FC
-if test -n "$FC"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FC" >&5
-$as_echo "$FC" >&6; }
-else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-    test -n "$FC" && break
-  done
-fi
-if test -z "$FC"; then
-  ac_ct_FC=$FC
-  for ac_prog in gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn xlf90 f90 pgf90 pghpf epcf90 g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_FC+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  if test -n "$ac_ct_FC"; then
-  ac_cv_prog_ac_ct_FC="$ac_ct_FC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-    for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_FC="$ac_prog"
-    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-  done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_FC=$ac_cv_prog_ac_ct_FC
-if test -n "$ac_ct_FC"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_FC" >&5
-$as_echo "$ac_ct_FC" >&6; }
-else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-  test -n "$ac_ct_FC" && break
-done
-
-  if test "x$ac_ct_FC" = x; then
-    FC=""
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
-    FC=$ac_ct_FC
-  fi
-fi
-
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for Fortran compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
-  { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
-  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
-  ac_status=$?
-  if test -s conftest.err; then
-    sed '10a\
-... rest of stderr output deleted ...
-         10q' conftest.err >conftest.er1
-    cat conftest.er1 >&5
-  fi
-  rm -f conftest.er1 conftest.err
-  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-  test $ac_status = 0; }
-done
-rm -f a.out
-
-# If we don't use `.F' as extension, the preprocessor is not run on the
-# input file.  (Note that this only needs to work for GNU compilers.)
-ac_save_ext=$ac_ext
-ac_ext=F
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Fortran compiler" >&5
-$as_echo_n "checking whether we are using the GNU Fortran compiler... " >&6; }
-if test "${ac_cv_fc_compiler_gnu+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  cat > conftest.$ac_ext <<_ACEOF
-      program main
-#ifndef __GNUC__
-       choke me
-#endif
-
-      end
-_ACEOF
-if ac_fn_fc_try_compile "$LINENO"; then :
-  ac_compiler_gnu=yes
-else
-  ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_fc_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_fc_compiler_gnu" >&5
-$as_echo "$ac_cv_fc_compiler_gnu" >&6; }
-ac_ext=$ac_save_ext
-ac_test_FCFLAGS=${FCFLAGS+set}
-ac_save_FCFLAGS=$FCFLAGS
-FCFLAGS=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $FC accepts -g" >&5
-$as_echo_n "checking whether $FC accepts -g... " >&6; }
-if test "${ac_cv_prog_fc_g+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  FCFLAGS=-g
-cat > conftest.$ac_ext <<_ACEOF
-      program main
+#endif
 
-      end
+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
+int
+main ()
+{
+  int i;
+  for (i = 0; i < 256; i++)
+    if (XOR (islower (i), ISLOWER (i))
+	|| toupper (i) != TOUPPER (i))
+      return 2;
+  return 0;
+}
 _ACEOF
-if ac_fn_fc_try_compile "$LINENO"; then :
-  ac_cv_prog_fc_g=yes
+if ac_fn_c_try_run "$LINENO"; then :
+
 else
-  ac_cv_prog_fc_g=no
+  ac_cv_header_stdc=no
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+  conftest.$ac_objext conftest.beam conftest.$ac_ext
 fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 
 fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_fc_g" >&5
-$as_echo "$ac_cv_prog_fc_g" >&6; }
-if test "$ac_test_FCFLAGS" = set; then
-  FCFLAGS=$ac_save_FCFLAGS
-elif test $ac_cv_prog_fc_g = yes; then
-  if test "x$ac_cv_fc_compiler_gnu" = xyes; then
-    FCFLAGS="-g -O2"
-  else
-    FCFLAGS="-g"
-  fi
-else
-  if test "x$ac_cv_fc_compiler_gnu" = xyes; then
-    FCFLAGS="-O2"
-  else
-    FCFLAGS=
-  fi
 fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
+$as_echo "$ac_cv_header_stdc" >&6; }
+if test $ac_cv_header_stdc = yes; then
 
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
+$as_echo "#define STDC_HEADERS 1" >>confdefs.h
+
+fi
+
+# On IRIX 5.3, sys/types and inttypes.h are conflicting.
+for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
+		  inttypes.h stdint.h unistd.h
+do :
+  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
+ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
+"
+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
+  cat >>confdefs.h <<_ACEOF
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+
+done
+
+
+for ac_header in dlfcn.h
+do :
+  ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
+"
+if test "x$ac_cv_header_dlfcn_h" = xyes; then :
+  cat >>confdefs.h <<_ACEOF
+#define HAVE_DLFCN_H 1
+_ACEOF
 
-if test -z "$FC" || test "X$FC" = "Xno"; then
-  _lt_disable_FC=yes
 fi
 
+done
+
+
+
+func_stripname_cnf ()
+{
+  case ${2} in
+  .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
+  *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
+  esac
+} # func_stripname_cnf
+
+
 
 
 
@@ -8490,6 +8827,7 @@ LIBTOOL='$(SHELL) $(top_builddir)/libtool'
 
 
 
+
 test -z "$LN_S" && LN_S="ln -s"
 
 
@@ -8511,7 +8849,7 @@ fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
 $as_echo_n "checking for objdir... " >&6; }
-if test "${lt_cv_objdir+set}" = set; then :
+if ${lt_cv_objdir+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   rm -f .libs 2>/dev/null
@@ -8539,19 +8877,6 @@ _ACEOF
 
 
 
-
-
-
-
-
-
-
-
-
-
-
-
-
 case $host_os in
 aix3*)
   # AIX sometimes has problems with the GCC collect2 program.  For some
@@ -8564,23 +8889,6 @@ aix3*)
   ;;
 esac
 
-# Sed substitution that helps us do robust quoting.  It backslashifies
-# metacharacters that are still active within double-quoted strings.
-sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\(["`\\]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
 # Global variables:
 ofile=libtool
 can_build_shared=yes
@@ -8609,7 +8917,7 @@ for cc_temp in $compiler""; do
     *) break;;
   esac
 done
-cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
+cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
 
 
 # Only perform the check for file, if the check method requires it
@@ -8619,7 +8927,7 @@ file_magic*)
   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if test "${lt_cv_path_MAGIC_CMD+set}" = set; then :
+if ${lt_cv_path_MAGIC_CMD+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $MAGIC_CMD in
@@ -8685,7 +8993,7 @@ if test -z "$lt_cv_path_MAGIC_CMD"; then
   if test -n "$ac_tool_prefix"; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
 $as_echo_n "checking for file... " >&6; }
-if test "${lt_cv_path_MAGIC_CMD+set}" = set; then :
+if ${lt_cv_path_MAGIC_CMD+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $MAGIC_CMD in
@@ -8809,16 +9117,25 @@ _lt_linker_boilerplate=`cat conftest.err`
 $RM -r conftest*
 
 
+## CAVEAT EMPTOR:
+## There is no encapsulation within the following macros, do not change
+## the running order or otherwise move them around unless you know exactly
+## what you are doing...
 if test -n "$compiler"; then
 
 lt_prog_compiler_no_builtin_flag=
 
 if test "$GCC" = yes; then
-  lt_prog_compiler_no_builtin_flag=' -fno-builtin'
+  case $cc_basename in
+  nvcc*)
+    lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
+  *)
+    lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
+  esac
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then :
+if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_rtti_exceptions=no
@@ -8834,15 +9151,15 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:8837: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:8841: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_rtti_exceptions=yes
@@ -8871,8 +9188,6 @@ fi
 lt_prog_compiler_pic=
 lt_prog_compiler_static=
 
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
 
   if test "$GCC" = yes; then
     lt_prog_compiler_wl='-Wl,'
@@ -8920,6 +9235,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic='-fno-common'
       ;;
 
+    haiku*)
+      # PIC is the default for Haiku.
+      # The "-static" flag exists, but is broken.
+      lt_prog_compiler_static=
+      ;;
+
     hpux*)
       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
@@ -8962,6 +9283,13 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic='-fPIC'
       ;;
     esac
+
+    case $cc_basename in
+    nvcc*) # Cuda Compiler Driver 2.2
+      lt_prog_compiler_wl='-Xlinker '
+      lt_prog_compiler_pic='-Xcompiler -fPIC'
+      ;;
+    esac
   else
     # PORTME Check for flag to pass linker flags through the system compiler.
     case $host_os in
@@ -9003,7 +9331,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_static='-non_shared'
       ;;
 
-    linux* | k*bsd*-gnu)
+    linux* | k*bsd*-gnu | kopensolaris*-gnu)
       case $cc_basename in
       # old Intel for x86_64 which still supported -KPIC.
       ecc*)
@@ -9024,7 +9352,13 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
 	lt_prog_compiler_pic='--shared'
 	lt_prog_compiler_static='--static'
 	;;
-      pgcc* | pgf77* | pgf90* | pgf95*)
+      nagfor*)
+	# NAG Fortran compiler
+	lt_prog_compiler_wl='-Wl,-Wl,,'
+	lt_prog_compiler_pic='-PIC'
+	lt_prog_compiler_static='-Bstatic'
+	;;
+      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
         # Portland Group compilers (*not* the Pentium gcc compiler,
 	# which looks to be a dead project)
 	lt_prog_compiler_wl='-Wl,'
@@ -9036,25 +9370,25 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
         # All Alpha code is PIC.
         lt_prog_compiler_static='-non_shared'
         ;;
-      xl*)
-	# IBM XL C 8.0/Fortran 10.1 on PPC
+      xl* | bgxl* | bgf* | mpixl*)
+	# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
 	lt_prog_compiler_wl='-Wl,'
 	lt_prog_compiler_pic='-qpic'
 	lt_prog_compiler_static='-qstaticlink'
 	;;
       *)
 	case `$CC -V 2>&1 | sed 5q` in
-	*Sun\ C*)
-	  # Sun C 5.9
+	*Sun\ F* | *Sun*Fortran*)
+	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
 	  lt_prog_compiler_pic='-KPIC'
 	  lt_prog_compiler_static='-Bstatic'
-	  lt_prog_compiler_wl='-Wl,'
+	  lt_prog_compiler_wl=''
 	  ;;
-	*Sun\ F*)
-	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
+	*Sun\ C*)
+	  # Sun C 5.9
 	  lt_prog_compiler_pic='-KPIC'
 	  lt_prog_compiler_static='-Bstatic'
-	  lt_prog_compiler_wl=''
+	  lt_prog_compiler_wl='-Wl,'
 	  ;;
 	esac
 	;;
@@ -9086,7 +9420,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic='-KPIC'
       lt_prog_compiler_static='-Bstatic'
       case $cc_basename in
-      f77* | f90* | f95*)
+      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
 	lt_prog_compiler_wl='-Qoption ld ';;
       *)
 	lt_prog_compiler_wl='-Wl,';;
@@ -9143,13 +9477,17 @@ case $host_os in
     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
     ;;
 esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
-$as_echo "$lt_prog_compiler_pic" >&6; }
-
-
-
-
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+if ${lt_cv_prog_compiler_pic+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
+$as_echo "$lt_cv_prog_compiler_pic" >&6; }
+lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
 
 #
 # Check to make sure the PIC flag actually works.
@@ -9157,7 +9495,7 @@ $as_echo "$lt_prog_compiler_pic" >&6; }
 if test -n "$lt_prog_compiler_pic"; then
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if test "${lt_cv_prog_compiler_pic_works+set}" = set; then :
+if ${lt_cv_prog_compiler_pic_works+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_pic_works=no
@@ -9173,15 +9511,15 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:9176: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:9180: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_pic_works=yes
@@ -9210,13 +9548,18 @@ fi
 
 
 
+
+
+
+
+
 #
 # Check to make sure the static flag actually works.
 #
 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if test "${lt_cv_prog_compiler_static_works+set}" = set; then :
+if ${lt_cv_prog_compiler_static_works+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_static_works=no
@@ -9229,7 +9572,7 @@ else
      if test -s conftest.err; then
        # Append any errors to the config.log.
        cat conftest.err 1>&5
-       $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
        if diff conftest.exp conftest.er2 >/dev/null; then
          lt_cv_prog_compiler_static_works=yes
@@ -9259,7 +9602,7 @@ fi
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if test "${lt_cv_prog_compiler_c_o+set}" = set; then :
+if ${lt_cv_prog_compiler_c_o+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_c_o=no
@@ -9278,16 +9621,16 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:9281: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:9285: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o=yes
@@ -9314,7 +9657,7 @@ $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if test "${lt_cv_prog_compiler_c_o+set}" = set; then :
+if ${lt_cv_prog_compiler_c_o+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_c_o=no
@@ -9333,16 +9676,16 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:9336: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:9340: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o=yes
@@ -9455,7 +9798,33 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
   esac
 
   ld_shlibs=yes
+
+  # On some targets, GNU ld is compatible enough with the native linker
+  # that we're better off using the native interface for both.
+  lt_use_gnu_ld_interface=no
   if test "$with_gnu_ld" = yes; then
+    case $host_os in
+      aix*)
+	# The AIX port of GNU ld has always aspired to compatibility
+	# with the native linker.  However, as the warning in the GNU ld
+	# block says, versions before 2.19.5* couldn't really create working
+	# shared libraries, regardless of the interface used.
+	case `$LD -v 2>&1` in
+	  *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
+	  *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
+	  *\ \(GNU\ Binutils\)\ [3-9]*) ;;
+	  *)
+	    lt_use_gnu_ld_interface=yes
+	    ;;
+	esac
+	;;
+      *)
+	lt_use_gnu_ld_interface=yes
+	;;
+    esac
+  fi
+
+  if test "$lt_use_gnu_ld_interface" = yes; then
     # If archive_cmds runs LD, not CC, wlarc should be empty
     wlarc='${wl}'
 
@@ -9473,6 +9842,7 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
     fi
     supports_anon_versioning=no
     case `$LD -v 2>&1` in
+      *GNU\ gold*) supports_anon_versioning=yes ;;
       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
@@ -9488,11 +9858,12 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
 	ld_shlibs=no
 	cat <<_LT_EOF 1>&2
 
-*** Warning: the GNU linker, at least up to release 2.9.1, is reported
+*** Warning: the GNU linker, at least up to release 2.19, is reported
 *** to be unable to reliably create shared libraries on AIX.
 *** Therefore, libtool is disabling shared libraries support.  If you
-*** really care for shared libraries, you may want to modify your PATH
-*** so that a non-GNU linker is found, and then restart.
+*** really care for shared libraries, you may want to install binutils
+*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
+*** You will then need to restart the configuration process.
 
 _LT_EOF
       fi
@@ -9528,10 +9899,12 @@ _LT_EOF
       # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
       # as there is no search path for DLLs.
       hardcode_libdir_flag_spec='-L$libdir'
+      export_dynamic_flag_spec='${wl}--export-all-symbols'
       allow_undefined_flag=unsupported
       always_export_symbols=no
       enable_shared_with_static_runtimes=yes
-      export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
+      export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
+      exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
 
       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
@@ -9549,6 +9922,11 @@ _LT_EOF
       fi
       ;;
 
+    haiku*)
+      archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+      link_all_deplibs=yes
+      ;;
+
     interix[3-9]*)
       hardcode_direct=no
       hardcode_shlibpath_var=no
@@ -9564,7 +9942,7 @@ _LT_EOF
       archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
       ;;
 
-    gnu* | linux* | tpf* | k*bsd*-gnu)
+    gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
       tmp_diet=no
       if test "$host_os" = linux-dietlibc; then
 	case $cc_basename in
@@ -9574,15 +9952,16 @@ _LT_EOF
       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
 	 && test "$tmp_diet" = no
       then
-	tmp_addflag=
+	tmp_addflag=' $pic_flag'
 	tmp_sharedflag='-shared'
 	case $cc_basename,$host_cpu in
         pgcc*)				# Portland Group C compiler
-	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag'
 	  ;;
-	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
-	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	pgf77* | pgf90* | pgf95* | pgfortran*)
+					# Portland Group f77 and f90 compilers
+	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag -Mnomain' ;;
 	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
 	  tmp_addflag=' -i_dynamic' ;;
@@ -9593,13 +9972,17 @@ _LT_EOF
 	lf95*)				# Lahey Fortran 8.1
 	  whole_archive_flag_spec=
 	  tmp_sharedflag='--shared' ;;
-	xl[cC]*)			# IBM XL C 8.0 on PPC (deal with xlf below)
+	xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
 	  tmp_sharedflag='-qmkshrobj'
 	  tmp_addflag= ;;
+	nvcc*)	# Cuda Compiler Driver 2.2
+	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
+	  compiler_needs_object=yes
+	  ;;
 	esac
 	case `$CC -V 2>&1 | sed 5q` in
 	*Sun\ C*)			# Sun C 5.9
-	  whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  compiler_needs_object=yes
 	  tmp_sharedflag='-G' ;;
 	*Sun\ F*)			# Sun Fortran 8.3
@@ -9615,17 +9998,17 @@ _LT_EOF
         fi
 
 	case $cc_basename in
-	xlf*)
+	xlf* | bgf* | bgxlf* | mpixlf*)
 	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
 	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
 	  hardcode_libdir_flag_spec=
 	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
-	  archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
+	  archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
 	  if test "x$supports_anon_versioning" = xyes; then
 	    archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
 	      cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
 	      echo "local: *; };" >> $output_objdir/$libname.ver~
-	      $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
+	      $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
 	  fi
 	  ;;
 	esac
@@ -9639,8 +10022,8 @@ _LT_EOF
 	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
 	wlarc=
       else
-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       fi
       ;;
 
@@ -9658,8 +10041,8 @@ _LT_EOF
 
 _LT_EOF
       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	ld_shlibs=no
       fi
@@ -9705,8 +10088,8 @@ _LT_EOF
 
     *)
       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	ld_shlibs=no
       fi
@@ -9746,8 +10129,10 @@ _LT_EOF
       else
 	# If we're using GNU nm, then we don't want the "-C" option.
 	# -C means demangle to AIX nm, but means don't demangle with GNU nm
+	# Also, AIX nm treats weak defined symbols like other global
+	# defined symbols, whereas GNU nm marks them as "W".
 	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
-	  export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
+	  export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	else
 	  export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	fi
@@ -9834,7 +10219,13 @@ _LT_EOF
 	allow_undefined_flag='-berok'
         # Determine the default libpath from the value encoded in an
         # empty executable.
-        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+        if test "${lt_cv_aix_libpath+set}" = set; then
+  aix_libpath=$lt_cv_aix_libpath
+else
+  if ${lt_cv_aix_libpath_+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
 int
@@ -9847,25 +10238,32 @@ main ()
 _ACEOF
 if ac_fn_c_try_link "$LINENO"; then :
 
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
+  lt_aix_libpath_sed='
+      /Import File Strings/,/^$/ {
+	  /^0/ {
+	      s/^0  *\([^ ]*\) *$/\1/
+	      p
+	  }
+      }'
+  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  # Check for a 64-bit object if we didn't find anything.
+  if test -z "$lt_cv_aix_libpath_"; then
+    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+  if test -z "$lt_cv_aix_libpath_"; then
+    lt_cv_aix_libpath_="/usr/lib:/lib"
+  fi
+
+fi
+
+  aix_libpath=$lt_cv_aix_libpath_
+fi
 
         hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
-        archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+        archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
       else
 	if test "$host_cpu" = ia64; then
 	  hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
@@ -9874,7 +10272,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	else
 	 # Determine the default libpath from the value encoded in an
 	 # empty executable.
-	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+	 if test "${lt_cv_aix_libpath+set}" = set; then
+  aix_libpath=$lt_cv_aix_libpath
+else
+  if ${lt_cv_aix_libpath_+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
 int
@@ -9887,30 +10291,42 @@ main ()
 _ACEOF
 if ac_fn_c_try_link "$LINENO"; then :
 
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
+  lt_aix_libpath_sed='
+      /Import File Strings/,/^$/ {
+	  /^0/ {
+	      s/^0  *\([^ ]*\) *$/\1/
+	      p
+	  }
+      }'
+  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  # Check for a 64-bit object if we didn't find anything.
+  if test -z "$lt_cv_aix_libpath_"; then
+    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+  if test -z "$lt_cv_aix_libpath_"; then
+    lt_cv_aix_libpath_="/usr/lib:/lib"
+  fi
+
+fi
+
+  aix_libpath=$lt_cv_aix_libpath_
+fi
 
 	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
 	  # Warning - without using the other run time loading flags,
 	  # -berok will link without error, but may produce a broken library.
 	  no_undefined_flag=' ${wl}-bernotok'
 	  allow_undefined_flag=' ${wl}-berok'
-	  # Exported symbols can be pulled into shared objects from archives
-	  whole_archive_flag_spec='$convenience'
+	  if test "$with_gnu_ld" = yes; then
+	    # We only use this code for GNU lds that support --whole-archive.
+	    whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
+	  else
+	    # Exported symbols can be pulled into shared objects from archives
+	    whole_archive_flag_spec='$convenience'
+	  fi
 	  archive_cmds_need_lc=yes
 	  # This is similar to how AIX traditionally builds its shared libraries.
 	  archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
@@ -9942,20 +10358,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       # Microsoft Visual C++.
       # hardcode_libdir_flag_spec is actually meaningless, as there is
       # no search path for DLLs.
-      hardcode_libdir_flag_spec=' '
-      allow_undefined_flag=unsupported
-      # Tell ltmain to make .lib files, not .a files.
-      libext=lib
-      # Tell ltmain to make .dll files, not .so files.
-      shrext_cmds=".dll"
-      # FIXME: Setting linknames here is a bad hack.
-      archive_cmds='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
-      # The linker will automatically build a .lib file if we build a DLL.
-      old_archive_from_new_cmds='true'
-      # FIXME: Should let the user specify the lib program.
-      old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
-      fix_srcfile_path='`cygpath -w "$srcfile"`'
-      enable_shared_with_static_runtimes=yes
+      case $cc_basename in
+      cl*)
+	# Native MSVC
+	hardcode_libdir_flag_spec=' '
+	allow_undefined_flag=unsupported
+	always_export_symbols=yes
+	file_list_spec='@'
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
+	archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
+	    sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
+	  else
+	    sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
+	  fi~
+	  $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
+	  linknames='
+	# The linker will not automatically build a static lib if we build a DLL.
+	# _LT_TAGVAR(old_archive_from_new_cmds, )='true'
+	enable_shared_with_static_runtimes=yes
+	export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
+	# Don't use ranlib
+	old_postinstall_cmds='chmod 644 $oldlib'
+	postlink_cmds='lt_outputfile="@OUTPUT@"~
+	  lt_tool_outputfile="@TOOL_OUTPUT@"~
+	  case $lt_outputfile in
+	    *.exe|*.EXE) ;;
+	    *)
+	      lt_outputfile="$lt_outputfile.exe"
+	      lt_tool_outputfile="$lt_tool_outputfile.exe"
+	      ;;
+	  esac~
+	  if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
+	    $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
+	    $RM "$lt_outputfile.manifest";
+	  fi'
+	;;
+      *)
+	# Assume MSVC wrapper
+	hardcode_libdir_flag_spec=' '
+	allow_undefined_flag=unsupported
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
+	# The linker will automatically build a .lib file if we build a DLL.
+	old_archive_from_new_cmds='true'
+	# FIXME: Should let the user specify the lib program.
+	old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
+	enable_shared_with_static_runtimes=yes
+	;;
+      esac
       ;;
 
     darwin* | rhapsody*)
@@ -9965,7 +10424,11 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
   hardcode_direct=no
   hardcode_automatic=yes
   hardcode_shlibpath_var=unsupported
-  whole_archive_flag_spec=''
+  if test "$lt_cv_ld_force_load" = "yes"; then
+    whole_archive_flag_spec='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+  else
+    whole_archive_flag_spec=''
+  fi
   link_all_deplibs=yes
   allow_undefined_flag="$_lt_dar_allow_undefined"
   case $cc_basename in
@@ -9973,7 +10436,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
      *) _lt_dar_can_shared=$GCC ;;
   esac
   if test "$_lt_dar_can_shared" = "yes"; then
-    output_verbose_link_cmd=echo
+    output_verbose_link_cmd=func_echo_all
     archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
     module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
     archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
@@ -10016,7 +10479,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
     freebsd* | dragonfly*)
-      archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
+      archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
       hardcode_libdir_flag_spec='-R$libdir'
       hardcode_direct=yes
       hardcode_shlibpath_var=no
@@ -10024,7 +10487,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     hpux9*)
       if test "$GCC" = yes; then
-	archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
+	archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       else
 	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       fi
@@ -10039,8 +10502,8 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     hpux10*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
-	archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
+	archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
       else
 	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
       fi
@@ -10057,29 +10520,68 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       fi
       ;;
 
-    hpux11*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
-	case $host_cpu in
-	hppa*64*)
-	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	ia64*)
-	  archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	*)
-	  archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	esac
-      else
-	case $host_cpu in
-	hppa*64*)
-	  archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	ia64*)
-	  archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
-	  ;;
-	*)
-	  archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+    hpux11*)
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
+	case $host_cpu in
+	hppa*64*)
+	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	ia64*)
+	  archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	*)
+	  archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	esac
+      else
+	case $host_cpu in
+	hppa*64*)
+	  archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	ia64*)
+	  archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	*)
+
+	  # Older versions of the 11.00 compiler do not understand -b yet
+	  # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
+	  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
+$as_echo_n "checking if $CC understands -b... " >&6; }
+if ${lt_cv_prog_compiler__b+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_prog_compiler__b=no
+   save_LDFLAGS="$LDFLAGS"
+   LDFLAGS="$LDFLAGS -b"
+   echo "$lt_simple_link_test_code" > conftest.$ac_ext
+   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
+     # The linker can only warn and ignore the option if not recognized
+     # So say no if there are warnings
+     if test -s conftest.err; then
+       # Append any errors to the config.log.
+       cat conftest.err 1>&5
+       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
+       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+       if diff conftest.exp conftest.er2 >/dev/null; then
+         lt_cv_prog_compiler__b=yes
+       fi
+     else
+       lt_cv_prog_compiler__b=yes
+     fi
+   fi
+   $RM -r conftest*
+   LDFLAGS="$save_LDFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
+$as_echo "$lt_cv_prog_compiler__b" >&6; }
+
+if test x"$lt_cv_prog_compiler__b" = xyes; then
+    archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+else
+    archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+fi
+
 	  ;;
 	esac
       fi
@@ -10107,26 +10609,39 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     irix5* | irix6* | nonstopux*)
       if test "$GCC" = yes; then
-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	# Try to use the -exported_symbol ld option, if it does not
 	# work, assume that -exports_file does not work either and
 	# implicitly export all symbols.
-        save_LDFLAGS="$LDFLAGS"
-        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
-        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+	# This should be the same for all languages, so no per-tag cache variable.
+	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
+if ${lt_cv_irix_exported_symbol+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  save_LDFLAGS="$LDFLAGS"
+	   LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
+	   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-int foo(void) {}
+int foo (void) { return 0; }
 _ACEOF
 if ac_fn_c_try_link "$LINENO"; then :
-  archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
+  lt_cv_irix_exported_symbol=yes
+else
+  lt_cv_irix_exported_symbol=no
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-        LDFLAGS="$save_LDFLAGS"
+           LDFLAGS="$save_LDFLAGS"
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
+	if test "$lt_cv_irix_exported_symbol" = yes; then
+          archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
+	fi
       else
-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
+	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
       fi
       archive_cmds_need_lc='no'
       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
@@ -10188,17 +10703,17 @@ rm -f core conftest.err conftest.$ac_objext \
       hardcode_libdir_flag_spec='-L$libdir'
       hardcode_minus_L=yes
       allow_undefined_flag=unsupported
-      archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
+      archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
       old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
       ;;
 
     osf3*)
       if test "$GCC" = yes; then
 	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
-	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
       else
 	allow_undefined_flag=' -expect_unresolved \*'
-	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
       fi
       archive_cmds_need_lc='no'
       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
@@ -10208,13 +10723,13 @@ rm -f core conftest.err conftest.$ac_objext \
     osf4* | osf5*)	# as osf3* with the addition of -msym flag
       if test "$GCC" = yes; then
 	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
-	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
       else
 	allow_undefined_flag=' -expect_unresolved \*'
-	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 	archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
-	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
+	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
 
 	# Both c and cxx compiler support -rpath directly
 	hardcode_libdir_flag_spec='-rpath $libdir'
@@ -10227,9 +10742,9 @@ rm -f core conftest.err conftest.$ac_objext \
       no_undefined_flag=' -z defs'
       if test "$GCC" = yes; then
 	wlarc='${wl}'
-	archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	  $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
+	  $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
       else
 	case `$CC -V 2>&1` in
 	*"Compilers 5.0"*)
@@ -10417,44 +10932,50 @@ x|xyes)
       # to ld, don't add -lc before -lgcc.
       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-      $RM conftest*
-      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
+if ${lt_cv_archive_cmds_need_lc+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  $RM conftest*
+	echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
-      if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+	if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; } 2>conftest.err; then
-        soname=conftest
-        lib=conftest
-        libobjs=conftest.$ac_objext
-        deplibs=
-        wl=$lt_prog_compiler_wl
-	pic_flag=$lt_prog_compiler_pic
-        compiler_flags=-v
-        linker_flags=-v
-        verstring=
-        output_objdir=.
-        libname=conftest
-        lt_save_allow_undefined_flag=$allow_undefined_flag
-        allow_undefined_flag=
-        if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
+	  soname=conftest
+	  lib=conftest
+	  libobjs=conftest.$ac_objext
+	  deplibs=
+	  wl=$lt_prog_compiler_wl
+	  pic_flag=$lt_prog_compiler_pic
+	  compiler_flags=-v
+	  linker_flags=-v
+	  verstring=
+	  output_objdir=.
+	  libname=conftest
+	  lt_save_allow_undefined_flag=$allow_undefined_flag
+	  allow_undefined_flag=
+	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
   (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; }
-        then
-	  archive_cmds_need_lc=no
-        else
-	  archive_cmds_need_lc=yes
-        fi
-        allow_undefined_flag=$lt_save_allow_undefined_flag
-      else
-        cat conftest.err 1>&5
-      fi
-      $RM conftest*
-      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc" >&5
-$as_echo "$archive_cmds_need_lc" >&6; }
+	  then
+	    lt_cv_archive_cmds_need_lc=no
+	  else
+	    lt_cv_archive_cmds_need_lc=yes
+	  fi
+	  allow_undefined_flag=$lt_save_allow_undefined_flag
+	else
+	  cat conftest.err 1>&5
+	fi
+	$RM conftest*
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
+$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
+      archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
       ;;
     esac
   fi
@@ -10625,16 +11146,23 @@ if test "$GCC" = yes; then
     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
     *) lt_awk_arg="/^libraries:/" ;;
   esac
-  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-  if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
+  case $host_os in
+    mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
+    *) lt_sed_strip_eq="s,=/,/,g" ;;
+  esac
+  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
+  case $lt_search_path_spec in
+  *\;*)
     # if the path contains ";" then we assume it to be the separator
     # otherwise default to the standard path separator (i.e. ":") - it is
     # assumed that no part of a normal pathname contains ";" but that should
     # okay in the real world where ";" in dirpaths is itself problematic.
-    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
-  else
-    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-  fi
+    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
+    ;;
+  *)
+    lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
+    ;;
+  esac
   # Ok, now we have the path, separated by spaces, we can step through it
   # and add multilib dir if necessary.
   lt_tmp_lt_search_path_spec=
@@ -10647,7 +11175,7 @@ if test "$GCC" = yes; then
 	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
     fi
   done
-  lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
+  lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
 BEGIN {RS=" "; FS="/|\n";} {
   lt_foo="";
   lt_count=0;
@@ -10667,7 +11195,13 @@ BEGIN {RS=" "; FS="/|\n";} {
   if (lt_foo != "") { lt_freq[lt_foo]++; }
   if (lt_freq[lt_foo] == 1) { print lt_foo; }
 }'`
-  sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
+  # AWK program above erroneously prepends '/' to C:/dos/paths
+  # for these hosts.
+  case $host_os in
+    mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
+      $SED 's,/\([A-Za-z]:\),\1,g'` ;;
+  esac
+  sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
 else
   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
 fi
@@ -10755,7 +11289,7 @@ amigaos*)
   m68k)
     library_names_spec='$libname.ixlibrary $libname.a'
     # Create ${libname}_ixlibrary.a entries in /sys/libs.
-    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
+    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
     ;;
   esac
   ;;
@@ -10786,8 +11320,9 @@ cygwin* | mingw* | pw32* | cegcc*)
   need_version=no
   need_lib_prefix=no
 
-  case $GCC,$host_os in
-  yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
+  case $GCC,$cc_basename in
+  yes,*)
+    # gcc
     library_names_spec='$libname.dll.a'
     # DLL is installed to $(libdir)/../bin by postinstall_cmds
     postinstall_cmds='base_file=`basename \${file}`~
@@ -10808,36 +11343,83 @@ cygwin* | mingw* | pw32* | cegcc*)
     cygwin*)
       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+
+      sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
       ;;
     mingw* | cegcc*)
       # MinGW DLLs use traditional 'lib' prefix
       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
-        # It is most probably a Windows format PATH printed by
-        # mingw gcc, but we are running on Cygwin. Gcc prints its search
-        # path with ; separators, and with drive letters. We can handle the
-        # drive letters (cygwin fileutils understands them), so leave them,
-        # especially as we might pass files found there to a mingw objdump,
-        # which wouldn't understand a cygwinified path. Ahh.
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
-      else
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-      fi
       ;;
     pw32*)
       # pw32 DLLs use 'pw' prefix rather than 'lib'
       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
       ;;
     esac
+    dynamic_linker='Win32 ld.exe'
+    ;;
+
+  *,cl*)
+    # Native MSVC
+    libname_spec='$name'
+    soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+    library_names_spec='${libname}.dll.lib'
+
+    case $build_os in
+    mingw*)
+      sys_lib_search_path_spec=
+      lt_save_ifs=$IFS
+      IFS=';'
+      for lt_path in $LIB
+      do
+        IFS=$lt_save_ifs
+        # Let DOS variable expansion print the short 8.3 style file name.
+        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
+        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
+      done
+      IFS=$lt_save_ifs
+      # Convert to MSYS style.
+      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
+      ;;
+    cygwin*)
+      # Convert to unix form, then to dos form, then back to unix form
+      # but this time dos style (no spaces!) so that the unix form looks
+      # like /cygdrive/c/PROGRA~1:/cygdr...
+      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
+      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
+      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      ;;
+    *)
+      sys_lib_search_path_spec="$LIB"
+      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
+        # It is most probably a Windows format PATH.
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
+      else
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      fi
+      # FIXME: find the short name or the path components, as spaces are
+      # common. (e.g. "Program Files" -> "PROGRA~1")
+      ;;
+    esac
+
+    # DLL is installed to $(libdir)/../bin by postinstall_cmds
+    postinstall_cmds='base_file=`basename \${file}`~
+      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
+      dldir=$destdir/`dirname \$dlpath`~
+      test -d \$dldir || mkdir -p \$dldir~
+      $install_prog $dir/$dlname \$dldir/$dlname'
+    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
+      dlpath=$dir/\$dldll~
+       $RM \$dlpath'
+    shlibpath_overrides_runpath=yes
+    dynamic_linker='Win32 link.exe'
     ;;
 
   *)
+    # Assume MSVC wrapper
     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
+    dynamic_linker='Win32 ld.exe'
     ;;
   esac
-  dynamic_linker='Win32 ld.exe'
   # FIXME: first we should search . and the directory the executable is in
   shlibpath_var=PATH
   ;;
@@ -10924,6 +11506,19 @@ gnu*)
   hardcode_into_libs=yes
   ;;
 
+haiku*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  dynamic_linker="$host_os runtime_loader"
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LIBRARY_PATH
+  shlibpath_overrides_runpath=yes
+  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
+  hardcode_into_libs=yes
+  ;;
+
 hpux9* | hpux10* | hpux11*)
   # Give a soname corresponding to the major version so that dld.sl refuses to
   # link against other versions.
@@ -10966,8 +11561,10 @@ hpux9* | hpux10* | hpux11*)
     soname_spec='${libname}${release}${shared_ext}$major'
     ;;
   esac
-  # HP-UX runs *really* slowly unless shared libraries are mode 555.
+  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
   postinstall_cmds='chmod 555 $lib'
+  # or fails outright, so override atomically:
+  install_override_mode=555
   ;;
 
 interix[3-9]*)
@@ -11025,7 +11622,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux* | k*bsd*-gnu)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -11034,12 +11631,17 @@ linux* | k*bsd*-gnu)
   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
   shlibpath_var=LD_LIBRARY_PATH
   shlibpath_overrides_runpath=no
+
   # Some binutils ld are patched to set DT_RUNPATH
-  save_LDFLAGS=$LDFLAGS
-  save_libdir=$libdir
-  eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
-       LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
-  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+  if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_shlibpath_overrides_runpath=no
+    save_LDFLAGS=$LDFLAGS
+    save_libdir=$libdir
+    eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
+	 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
+    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
 int
@@ -11052,13 +11654,17 @@ main ()
 _ACEOF
 if ac_fn_c_try_link "$LINENO"; then :
   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
-  shlibpath_overrides_runpath=yes
+  lt_cv_shlibpath_overrides_runpath=yes
 fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-  LDFLAGS=$save_LDFLAGS
-  libdir=$save_libdir
+    LDFLAGS=$save_LDFLAGS
+    libdir=$save_libdir
+
+fi
+
+  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
 
   # This implies no fast_install, which is unacceptable.
   # Some rework will be needed to allow for fast_install
@@ -11067,7 +11673,7 @@ rm -f core conftest.err conftest.$ac_objext \
 
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
@@ -11370,6 +11976,11 @@ fi
 
 
 
+
+
+
+
+
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
 hardcode_action=
@@ -11442,7 +12053,7 @@ else
   # if libdl is installed we need to link against it
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
 $as_echo_n "checking for dlopen in -ldl... " >&6; }
-if test "${ac_cv_lib_dl_dlopen+set}" = set; then :
+if ${ac_cv_lib_dl_dlopen+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -11476,7 +12087,7 @@ LIBS=$ac_check_lib_save_LIBS
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = x""yes; then :
+if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
 else
 
@@ -11490,12 +12101,12 @@ fi
 
   *)
     ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = x""yes; then :
+if test "x$ac_cv_func_shl_load" = xyes; then :
   lt_cv_dlopen="shl_load"
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
 $as_echo_n "checking for shl_load in -ldld... " >&6; }
-if test "${ac_cv_lib_dld_shl_load+set}" = set; then :
+if ${ac_cv_lib_dld_shl_load+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -11529,16 +12140,16 @@ LIBS=$ac_check_lib_save_LIBS
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = x""yes; then :
+if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
 else
   ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = x""yes; then :
+if test "x$ac_cv_func_dlopen" = xyes; then :
   lt_cv_dlopen="dlopen"
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
 $as_echo_n "checking for dlopen in -ldl... " >&6; }
-if test "${ac_cv_lib_dl_dlopen+set}" = set; then :
+if ${ac_cv_lib_dl_dlopen+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -11572,12 +12183,12 @@ LIBS=$ac_check_lib_save_LIBS
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = x""yes; then :
+if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if test "${ac_cv_lib_svld_dlopen+set}" = set; then :
+if ${ac_cv_lib_svld_dlopen+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -11611,12 +12222,12 @@ LIBS=$ac_check_lib_save_LIBS
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = x""yes; then :
+if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
 else
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
 $as_echo_n "checking for dld_link in -ldld... " >&6; }
-if test "${ac_cv_lib_dld_dld_link+set}" = set; then :
+if ${ac_cv_lib_dld_dld_link+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -11650,7 +12261,7 @@ LIBS=$ac_check_lib_save_LIBS
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = x""yes; then :
+if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
 fi
 
@@ -11691,7 +12302,7 @@ fi
 
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if test "${lt_cv_dlopen_self+set}" = set; then :
+if ${lt_cv_dlopen_self+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   	  if test "$cross_compiling" = yes; then :
@@ -11700,7 +12311,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11703 "configure"
+#line $LINENO "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11741,7 +12352,13 @@ else
 #  endif
 #endif
 
-void fnord() { int i=42;}
+/* When -fvisbility=hidden is used, assume the code has been annotated
+   correspondingly for the symbols needed.  */
+#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
+int fnord () __attribute__((visibility("default")));
+#endif
+
+int fnord () { return 42; }
 int main ()
 {
   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
@@ -11750,7 +12367,11 @@ int main ()
   if (self)
     {
       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
-      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
+      else
+        {
+	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
+          else puts (dlerror ());
+	}
       /* dlclose (self); */
     }
   else
@@ -11787,7 +12408,7 @@ $as_echo "$lt_cv_dlopen_self" >&6; }
       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if test "${lt_cv_dlopen_self_static+set}" = set; then :
+if ${lt_cv_dlopen_self_static+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   	  if test "$cross_compiling" = yes; then :
@@ -11796,7 +12417,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 11799 "configure"
+#line $LINENO "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11837,7 +12458,13 @@ else
 #  endif
 #endif
 
-void fnord() { int i=42;}
+/* When -fvisbility=hidden is used, assume the code has been annotated
+   correspondingly for the symbols needed.  */
+#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
+int fnord () __attribute__((visibility("default")));
+#endif
+
+int fnord () { return 42; }
 int main ()
 {
   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
@@ -11846,7 +12473,11 @@ int main ()
   if (self)
     {
       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
-      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
+      else
+        {
+	  if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
+          else puts (dlerror ());
+	}
       /* dlclose (self); */
     }
   else
@@ -12013,6 +12644,10 @@ ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest
 ac_compiler_gnu=$ac_cv_fc_compiler_gnu
 
 
+if test -z "$FC" || test "X$FC" = "Xno"; then
+  _lt_disable_FC=yes
+fi
+
 archive_cmds_need_lc_FC=no
 allow_undefined_flag_FC=
 always_export_symbols_FC=no
@@ -12030,6 +12665,8 @@ module_cmds_FC=
 module_expsym_cmds_FC=
 link_all_deplibs_FC=unknown
 old_archive_cmds_FC=$old_archive_cmds
+reload_flag_FC=$reload_flag
+reload_cmds_FC=$reload_cmds
 no_undefined_flag_FC=
 whole_archive_flag_spec_FC=
 enable_shared_with_static_runtimes_FC=no
@@ -12093,7 +12730,9 @@ $RM -r conftest*
   # Allow CC to be a program name with arguments.
   lt_save_CC="$CC"
   lt_save_GCC=$GCC
+  lt_save_CFLAGS=$CFLAGS
   CC=${FC-"f95"}
+  CFLAGS=$FCFLAGS
   compiler=$CC
   GCC=$ac_cv_fc_compiler_gnu
 
@@ -12106,7 +12745,7 @@ $RM -r conftest*
     *) break;;
   esac
 done
-cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
+cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
 
 
   if test -n "$compiler"; then
@@ -12168,6 +12807,13 @@ cat > conftest.$ac_ext <<_LT_EOF
       end
 _LT_EOF
 
+
+_lt_libdeps_save_CFLAGS=$CFLAGS
+case "$CC $CFLAGS " in #(
+*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
+*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
+esac
+
 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
@@ -12181,7 +12827,7 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
   pre_test_object_deps_done=no
 
   for p in `eval "$output_verbose_link_cmd"`; do
-    case $p in
+    case ${prev}${p} in
 
     -L* | -R* | -l*)
        # Some compilers place space between "-{L,R}" and the path.
@@ -12190,13 +12836,22 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
           test $p = "-R"; then
 	 prev=$p
 	 continue
-       else
-	 prev=
        fi
 
+       # Expand the sysroot to ease extracting the directories later.
+       if test -z "$prev"; then
+         case $p in
+         -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
+         -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
+         -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
+         esac
+       fi
+       case $p in
+       =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
+       esac
        if test "$pre_test_object_deps_done" = no; then
-	 case $p in
-	 -L* | -R*)
+	 case ${prev} in
+	 -L | -R)
 	   # Internal compiler library paths should come after those
 	   # provided the user.  The postdeps already come after the
 	   # user supplied libs so there is no need to process them.
@@ -12216,8 +12871,10 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
 	   postdeps_FC="${postdeps_FC} ${prev}${p}"
 	 fi
        fi
+       prev=
        ;;
 
+    *.lto.$objext) ;; # Ignore GCC LTO objects
     *.$objext)
        # This assumes that the test object file only shows up
        # once in the compiler output.
@@ -12253,6 +12910,7 @@ else
 fi
 
 $RM -f confest.$objext
+CFLAGS=$_lt_libdeps_save_CFLAGS
 
 # PORTME: override above test on systems where it is broken
 
@@ -12299,8 +12957,6 @@ fi
 lt_prog_compiler_pic_FC=
 lt_prog_compiler_static_FC=
 
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
 
   if test "$GCC" = yes; then
     lt_prog_compiler_wl_FC='-Wl,'
@@ -12348,6 +13004,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic_FC='-fno-common'
       ;;
 
+    haiku*)
+      # PIC is the default for Haiku.
+      # The "-static" flag exists, but is broken.
+      lt_prog_compiler_static_FC=
+      ;;
+
     hpux*)
       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
@@ -12390,6 +13052,13 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic_FC='-fPIC'
       ;;
     esac
+
+    case $cc_basename in
+    nvcc*) # Cuda Compiler Driver 2.2
+      lt_prog_compiler_wl_FC='-Xlinker '
+      lt_prog_compiler_pic_FC='-Xcompiler -fPIC'
+      ;;
+    esac
   else
     # PORTME Check for flag to pass linker flags through the system compiler.
     case $host_os in
@@ -12431,7 +13100,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_static_FC='-non_shared'
       ;;
 
-    linux* | k*bsd*-gnu)
+    linux* | k*bsd*-gnu | kopensolaris*-gnu)
       case $cc_basename in
       # old Intel for x86_64 which still supported -KPIC.
       ecc*)
@@ -12452,7 +13121,13 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
 	lt_prog_compiler_pic_FC='--shared'
 	lt_prog_compiler_static_FC='--static'
 	;;
-      pgcc* | pgf77* | pgf90* | pgf95*)
+      nagfor*)
+	# NAG Fortran compiler
+	lt_prog_compiler_wl_FC='-Wl,-Wl,,'
+	lt_prog_compiler_pic_FC='-PIC'
+	lt_prog_compiler_static_FC='-Bstatic'
+	;;
+      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
         # Portland Group compilers (*not* the Pentium gcc compiler,
 	# which looks to be a dead project)
 	lt_prog_compiler_wl_FC='-Wl,'
@@ -12464,25 +13139,25 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
         # All Alpha code is PIC.
         lt_prog_compiler_static_FC='-non_shared'
         ;;
-      xl*)
-	# IBM XL C 8.0/Fortran 10.1 on PPC
+      xl* | bgxl* | bgf* | mpixl*)
+	# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
 	lt_prog_compiler_wl_FC='-Wl,'
 	lt_prog_compiler_pic_FC='-qpic'
 	lt_prog_compiler_static_FC='-qstaticlink'
 	;;
       *)
 	case `$CC -V 2>&1 | sed 5q` in
-	*Sun\ C*)
-	  # Sun C 5.9
+	*Sun\ F* | *Sun*Fortran*)
+	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
 	  lt_prog_compiler_pic_FC='-KPIC'
 	  lt_prog_compiler_static_FC='-Bstatic'
-	  lt_prog_compiler_wl_FC='-Wl,'
+	  lt_prog_compiler_wl_FC=''
 	  ;;
-	*Sun\ F*)
-	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
+	*Sun\ C*)
+	  # Sun C 5.9
 	  lt_prog_compiler_pic_FC='-KPIC'
 	  lt_prog_compiler_static_FC='-Bstatic'
-	  lt_prog_compiler_wl_FC=''
+	  lt_prog_compiler_wl_FC='-Wl,'
 	  ;;
 	esac
 	;;
@@ -12514,7 +13189,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic_FC='-KPIC'
       lt_prog_compiler_static_FC='-Bstatic'
       case $cc_basename in
-      f77* | f90* | f95*)
+      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
 	lt_prog_compiler_wl_FC='-Qoption ld ';;
       *)
 	lt_prog_compiler_wl_FC='-Wl,';;
@@ -12571,10 +13246,17 @@ case $host_os in
     lt_prog_compiler_pic_FC="$lt_prog_compiler_pic_FC"
     ;;
 esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_FC" >&5
-$as_echo "$lt_prog_compiler_pic_FC" >&6; }
-
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+if ${lt_cv_prog_compiler_pic_FC+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_prog_compiler_pic_FC=$lt_prog_compiler_pic_FC
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_FC" >&5
+$as_echo "$lt_cv_prog_compiler_pic_FC" >&6; }
+lt_prog_compiler_pic_FC=$lt_cv_prog_compiler_pic_FC
 
 #
 # Check to make sure the PIC flag actually works.
@@ -12582,7 +13264,7 @@ $as_echo "$lt_prog_compiler_pic_FC" >&6; }
 if test -n "$lt_prog_compiler_pic_FC"; then
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_FC works" >&5
 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_FC works... " >&6; }
-if test "${lt_cv_prog_compiler_pic_works_FC+set}" = set; then :
+if ${lt_cv_prog_compiler_pic_works_FC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_pic_works_FC=no
@@ -12598,15 +13280,15 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:12601: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:12605: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_pic_works_FC=yes
@@ -12632,13 +13314,15 @@ fi
 
 
 
+
+
 #
 # Check to make sure the static flag actually works.
 #
 wl=$lt_prog_compiler_wl_FC eval lt_tmp_static_flag=\"$lt_prog_compiler_static_FC\"
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if test "${lt_cv_prog_compiler_static_works_FC+set}" = set; then :
+if ${lt_cv_prog_compiler_static_works_FC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_static_works_FC=no
@@ -12651,7 +13335,7 @@ else
      if test -s conftest.err; then
        # Append any errors to the config.log.
        cat conftest.err 1>&5
-       $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
        if diff conftest.exp conftest.er2 >/dev/null; then
          lt_cv_prog_compiler_static_works_FC=yes
@@ -12678,7 +13362,7 @@ fi
 
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if test "${lt_cv_prog_compiler_c_o_FC+set}" = set; then :
+if ${lt_cv_prog_compiler_c_o_FC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_c_o_FC=no
@@ -12697,16 +13381,16 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:12700: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:12704: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o_FC=yes
@@ -12730,7 +13414,7 @@ $as_echo "$lt_cv_prog_compiler_c_o_FC" >&6; }
 
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if test "${lt_cv_prog_compiler_c_o_FC+set}" = set; then :
+if ${lt_cv_prog_compiler_c_o_FC+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_c_o_FC=no
@@ -12749,16 +13433,16 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:12752: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:12756: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o_FC=yes
@@ -12868,7 +13552,33 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
   esac
 
   ld_shlibs_FC=yes
+
+  # On some targets, GNU ld is compatible enough with the native linker
+  # that we're better off using the native interface for both.
+  lt_use_gnu_ld_interface=no
   if test "$with_gnu_ld" = yes; then
+    case $host_os in
+      aix*)
+	# The AIX port of GNU ld has always aspired to compatibility
+	# with the native linker.  However, as the warning in the GNU ld
+	# block says, versions before 2.19.5* couldn't really create working
+	# shared libraries, regardless of the interface used.
+	case `$LD -v 2>&1` in
+	  *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
+	  *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
+	  *\ \(GNU\ Binutils\)\ [3-9]*) ;;
+	  *)
+	    lt_use_gnu_ld_interface=yes
+	    ;;
+	esac
+	;;
+      *)
+	lt_use_gnu_ld_interface=yes
+	;;
+    esac
+  fi
+
+  if test "$lt_use_gnu_ld_interface" = yes; then
     # If archive_cmds runs LD, not CC, wlarc should be empty
     wlarc='${wl}'
 
@@ -12886,6 +13596,7 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
     fi
     supports_anon_versioning=no
     case `$LD -v 2>&1` in
+      *GNU\ gold*) supports_anon_versioning=yes ;;
       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
@@ -12901,11 +13612,12 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
 	ld_shlibs_FC=no
 	cat <<_LT_EOF 1>&2
 
-*** Warning: the GNU linker, at least up to release 2.9.1, is reported
+*** Warning: the GNU linker, at least up to release 2.19, is reported
 *** to be unable to reliably create shared libraries on AIX.
 *** Therefore, libtool is disabling shared libraries support.  If you
-*** really care for shared libraries, you may want to modify your PATH
-*** so that a non-GNU linker is found, and then restart.
+*** really care for shared libraries, you may want to install binutils
+*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
+*** You will then need to restart the configuration process.
 
 _LT_EOF
       fi
@@ -12941,10 +13653,12 @@ _LT_EOF
       # _LT_TAGVAR(hardcode_libdir_flag_spec, FC) is actually meaningless,
       # as there is no search path for DLLs.
       hardcode_libdir_flag_spec_FC='-L$libdir'
+      export_dynamic_flag_spec_FC='${wl}--export-all-symbols'
       allow_undefined_flag_FC=unsupported
       always_export_symbols_FC=no
       enable_shared_with_static_runtimes_FC=yes
-      export_symbols_cmds_FC='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
+      export_symbols_cmds_FC='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
+      exclude_expsyms_FC='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
 
       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
         archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
@@ -12962,6 +13676,11 @@ _LT_EOF
       fi
       ;;
 
+    haiku*)
+      archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+      link_all_deplibs_FC=yes
+      ;;
+
     interix[3-9]*)
       hardcode_direct_FC=no
       hardcode_shlibpath_var_FC=no
@@ -12977,7 +13696,7 @@ _LT_EOF
       archive_expsym_cmds_FC='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
       ;;
 
-    gnu* | linux* | tpf* | k*bsd*-gnu)
+    gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
       tmp_diet=no
       if test "$host_os" = linux-dietlibc; then
 	case $cc_basename in
@@ -12987,15 +13706,16 @@ _LT_EOF
       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
 	 && test "$tmp_diet" = no
       then
-	tmp_addflag=
+	tmp_addflag=' $pic_flag'
 	tmp_sharedflag='-shared'
 	case $cc_basename,$host_cpu in
         pgcc*)				# Portland Group C compiler
-	  whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag'
 	  ;;
-	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
-	  whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	pgf77* | pgf90* | pgf95* | pgfortran*)
+					# Portland Group f77 and f90 compilers
+	  whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag -Mnomain' ;;
 	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
 	  tmp_addflag=' -i_dynamic' ;;
@@ -13006,13 +13726,17 @@ _LT_EOF
 	lf95*)				# Lahey Fortran 8.1
 	  whole_archive_flag_spec_FC=
 	  tmp_sharedflag='--shared' ;;
-	xl[cC]*)			# IBM XL C 8.0 on PPC (deal with xlf below)
+	xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
 	  tmp_sharedflag='-qmkshrobj'
 	  tmp_addflag= ;;
+	nvcc*)	# Cuda Compiler Driver 2.2
+	  whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
+	  compiler_needs_object_FC=yes
+	  ;;
 	esac
 	case `$CC -V 2>&1 | sed 5q` in
 	*Sun\ C*)			# Sun C 5.9
-	  whole_archive_flag_spec_FC='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  whole_archive_flag_spec_FC='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  compiler_needs_object_FC=yes
 	  tmp_sharedflag='-G' ;;
 	*Sun\ F*)			# Sun Fortran 8.3
@@ -13028,17 +13752,17 @@ _LT_EOF
         fi
 
 	case $cc_basename in
-	xlf*)
+	xlf* | bgf* | bgxlf* | mpixlf*)
 	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
 	  whole_archive_flag_spec_FC='--whole-archive$convenience --no-whole-archive'
 	  hardcode_libdir_flag_spec_FC=
 	  hardcode_libdir_flag_spec_ld_FC='-rpath $libdir'
-	  archive_cmds_FC='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
+	  archive_cmds_FC='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
 	  if test "x$supports_anon_versioning" = xyes; then
 	    archive_expsym_cmds_FC='echo "{ global:" > $output_objdir/$libname.ver~
 	      cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
 	      echo "local: *; };" >> $output_objdir/$libname.ver~
-	      $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
+	      $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
 	  fi
 	  ;;
 	esac
@@ -13052,8 +13776,8 @@ _LT_EOF
 	archive_cmds_FC='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
 	wlarc=
       else
-	archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       fi
       ;;
 
@@ -13071,8 +13795,8 @@ _LT_EOF
 
 _LT_EOF
       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	ld_shlibs_FC=no
       fi
@@ -13118,8 +13842,8 @@ _LT_EOF
 
     *)
       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	ld_shlibs_FC=no
       fi
@@ -13159,8 +13883,10 @@ _LT_EOF
       else
 	# If we're using GNU nm, then we don't want the "-C" option.
 	# -C means demangle to AIX nm, but means don't demangle with GNU nm
+	# Also, AIX nm treats weak defined symbols like other global
+	# defined symbols, whereas GNU nm marks them as "W".
 	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
-	  export_symbols_cmds_FC='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
+	  export_symbols_cmds_FC='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	else
 	  export_symbols_cmds_FC='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	fi
@@ -13247,32 +13973,45 @@ _LT_EOF
 	allow_undefined_flag_FC='-berok'
         # Determine the default libpath from the value encoded in an
         # empty executable.
-        cat > conftest.$ac_ext <<_ACEOF
+        if test "${lt_cv_aix_libpath+set}" = set; then
+  aix_libpath=$lt_cv_aix_libpath
+else
+  if ${lt_cv_aix_libpath__FC+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat > conftest.$ac_ext <<_ACEOF
       program main
 
       end
 _ACEOF
 if ac_fn_fc_try_link "$LINENO"; then :
 
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
+  lt_aix_libpath_sed='
+      /Import File Strings/,/^$/ {
+	  /^0/ {
+	      s/^0  *\([^ ]*\) *$/\1/
+	      p
+	  }
+      }'
+  lt_cv_aix_libpath__FC=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  # Check for a 64-bit object if we didn't find anything.
+  if test -z "$lt_cv_aix_libpath__FC"; then
+    lt_cv_aix_libpath__FC=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+  if test -z "$lt_cv_aix_libpath__FC"; then
+    lt_cv_aix_libpath__FC="/usr/lib:/lib"
+  fi
+
+fi
+
+  aix_libpath=$lt_cv_aix_libpath__FC
+fi
 
         hardcode_libdir_flag_spec_FC='${wl}-blibpath:$libdir:'"$aix_libpath"
-        archive_expsym_cmds_FC='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+        archive_expsym_cmds_FC='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
       else
 	if test "$host_cpu" = ia64; then
 	  hardcode_libdir_flag_spec_FC='${wl}-R $libdir:/usr/lib:/lib'
@@ -13281,37 +14020,55 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	else
 	 # Determine the default libpath from the value encoded in an
 	 # empty executable.
-	 cat > conftest.$ac_ext <<_ACEOF
+	 if test "${lt_cv_aix_libpath+set}" = set; then
+  aix_libpath=$lt_cv_aix_libpath
+else
+  if ${lt_cv_aix_libpath__FC+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat > conftest.$ac_ext <<_ACEOF
       program main
 
       end
 _ACEOF
 if ac_fn_fc_try_link "$LINENO"; then :
 
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
+  lt_aix_libpath_sed='
+      /Import File Strings/,/^$/ {
+	  /^0/ {
+	      s/^0  *\([^ ]*\) *$/\1/
+	      p
+	  }
+      }'
+  lt_cv_aix_libpath__FC=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  # Check for a 64-bit object if we didn't find anything.
+  if test -z "$lt_cv_aix_libpath__FC"; then
+    lt_cv_aix_libpath__FC=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+  if test -z "$lt_cv_aix_libpath__FC"; then
+    lt_cv_aix_libpath__FC="/usr/lib:/lib"
+  fi
+
+fi
+
+  aix_libpath=$lt_cv_aix_libpath__FC
+fi
 
 	 hardcode_libdir_flag_spec_FC='${wl}-blibpath:$libdir:'"$aix_libpath"
 	  # Warning - without using the other run time loading flags,
 	  # -berok will link without error, but may produce a broken library.
 	  no_undefined_flag_FC=' ${wl}-bernotok'
 	  allow_undefined_flag_FC=' ${wl}-berok'
-	  # Exported symbols can be pulled into shared objects from archives
-	  whole_archive_flag_spec_FC='$convenience'
+	  if test "$with_gnu_ld" = yes; then
+	    # We only use this code for GNU lds that support --whole-archive.
+	    whole_archive_flag_spec_FC='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
+	  else
+	    # Exported symbols can be pulled into shared objects from archives
+	    whole_archive_flag_spec_FC='$convenience'
+	  fi
 	  archive_cmds_need_lc_FC=yes
 	  # This is similar to how AIX traditionally builds its shared libraries.
 	  archive_expsym_cmds_FC="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
@@ -13343,20 +14100,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       # Microsoft Visual C++.
       # hardcode_libdir_flag_spec is actually meaningless, as there is
       # no search path for DLLs.
-      hardcode_libdir_flag_spec_FC=' '
-      allow_undefined_flag_FC=unsupported
-      # Tell ltmain to make .lib files, not .a files.
-      libext=lib
-      # Tell ltmain to make .dll files, not .so files.
-      shrext_cmds=".dll"
-      # FIXME: Setting linknames here is a bad hack.
-      archive_cmds_FC='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
-      # The linker will automatically build a .lib file if we build a DLL.
-      old_archive_from_new_cmds_FC='true'
-      # FIXME: Should let the user specify the lib program.
-      old_archive_cmds_FC='lib -OUT:$oldlib$oldobjs$old_deplibs'
-      fix_srcfile_path_FC='`cygpath -w "$srcfile"`'
-      enable_shared_with_static_runtimes_FC=yes
+      case $cc_basename in
+      cl*)
+	# Native MSVC
+	hardcode_libdir_flag_spec_FC=' '
+	allow_undefined_flag_FC=unsupported
+	always_export_symbols_FC=yes
+	file_list_spec_FC='@'
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	archive_cmds_FC='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
+	archive_expsym_cmds_FC='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
+	    sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
+	  else
+	    sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
+	  fi~
+	  $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
+	  linknames='
+	# The linker will not automatically build a static lib if we build a DLL.
+	# _LT_TAGVAR(old_archive_from_new_cmds, FC)='true'
+	enable_shared_with_static_runtimes_FC=yes
+	export_symbols_cmds_FC='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
+	# Don't use ranlib
+	old_postinstall_cmds_FC='chmod 644 $oldlib'
+	postlink_cmds_FC='lt_outputfile="@OUTPUT@"~
+	  lt_tool_outputfile="@TOOL_OUTPUT@"~
+	  case $lt_outputfile in
+	    *.exe|*.EXE) ;;
+	    *)
+	      lt_outputfile="$lt_outputfile.exe"
+	      lt_tool_outputfile="$lt_tool_outputfile.exe"
+	      ;;
+	  esac~
+	  if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
+	    $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
+	    $RM "$lt_outputfile.manifest";
+	  fi'
+	;;
+      *)
+	# Assume MSVC wrapper
+	hardcode_libdir_flag_spec_FC=' '
+	allow_undefined_flag_FC=unsupported
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	archive_cmds_FC='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
+	# The linker will automatically build a .lib file if we build a DLL.
+	old_archive_from_new_cmds_FC='true'
+	# FIXME: Should let the user specify the lib program.
+	old_archive_cmds_FC='lib -OUT:$oldlib$oldobjs$old_deplibs'
+	enable_shared_with_static_runtimes_FC=yes
+	;;
+      esac
       ;;
 
     darwin* | rhapsody*)
@@ -13366,7 +14166,11 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
   hardcode_direct_FC=no
   hardcode_automatic_FC=yes
   hardcode_shlibpath_var_FC=unsupported
-  whole_archive_flag_spec_FC=''
+  if test "$lt_cv_ld_force_load" = "yes"; then
+    whole_archive_flag_spec_FC='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+  else
+    whole_archive_flag_spec_FC=''
+  fi
   link_all_deplibs_FC=yes
   allow_undefined_flag_FC="$_lt_dar_allow_undefined"
   case $cc_basename in
@@ -13374,7 +14178,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
      *) _lt_dar_can_shared=$GCC ;;
   esac
   if test "$_lt_dar_can_shared" = "yes"; then
-    output_verbose_link_cmd=echo
+    output_verbose_link_cmd=func_echo_all
     archive_cmds_FC="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
     module_cmds_FC="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
     archive_expsym_cmds_FC="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
@@ -13417,7 +14221,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
     freebsd* | dragonfly*)
-      archive_cmds_FC='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
+      archive_cmds_FC='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
       hardcode_libdir_flag_spec_FC='-R$libdir'
       hardcode_direct_FC=yes
       hardcode_shlibpath_var_FC=no
@@ -13425,7 +14229,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     hpux9*)
       if test "$GCC" = yes; then
-	archive_cmds_FC='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
+	archive_cmds_FC='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       else
 	archive_cmds_FC='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       fi
@@ -13440,8 +14244,8 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     hpux10*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
-	archive_cmds_FC='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
+	archive_cmds_FC='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
       else
 	archive_cmds_FC='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
       fi
@@ -13459,16 +14263,16 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     hpux11*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
 	case $host_cpu in
 	hppa*64*)
 	  archive_cmds_FC='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	ia64*)
-	  archive_cmds_FC='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  archive_cmds_FC='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  archive_cmds_FC='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+	  archive_cmds_FC='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       else
@@ -13480,7 +14284,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	  archive_cmds_FC='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  archive_cmds_FC='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+	archive_cmds_FC='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       fi
@@ -13508,25 +14312,40 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     irix5* | irix6* | nonstopux*)
       if test "$GCC" = yes; then
-	archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	# Try to use the -exported_symbol ld option, if it does not
 	# work, assume that -exports_file does not work either and
 	# implicitly export all symbols.
-        save_LDFLAGS="$LDFLAGS"
-        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
-        cat > conftest.$ac_ext <<_ACEOF
-int foo(void) {}
+	# This should be the same for all languages, so no per-tag cache variable.
+	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
+if ${lt_cv_irix_exported_symbol+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  save_LDFLAGS="$LDFLAGS"
+	   LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
+	   cat > conftest.$ac_ext <<_ACEOF
+
+      subroutine foo
+      end
 _ACEOF
 if ac_fn_fc_try_link "$LINENO"; then :
-  archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
+  lt_cv_irix_exported_symbol=yes
+else
+  lt_cv_irix_exported_symbol=no
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-        LDFLAGS="$save_LDFLAGS"
+           LDFLAGS="$save_LDFLAGS"
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
+	if test "$lt_cv_irix_exported_symbol" = yes; then
+          archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
+	fi
       else
-	archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
+	archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
       fi
       archive_cmds_need_lc_FC='no'
       hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
@@ -13588,17 +14407,17 @@ rm -f core conftest.err conftest.$ac_objext \
       hardcode_libdir_flag_spec_FC='-L$libdir'
       hardcode_minus_L_FC=yes
       allow_undefined_flag_FC=unsupported
-      archive_cmds_FC='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
+      archive_cmds_FC='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
       old_archive_from_new_cmds_FC='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
       ;;
 
     osf3*)
       if test "$GCC" = yes; then
 	allow_undefined_flag_FC=' ${wl}-expect_unresolved ${wl}\*'
-	archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
       else
 	allow_undefined_flag_FC=' -expect_unresolved \*'
-	archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
       fi
       archive_cmds_need_lc_FC='no'
       hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
@@ -13608,13 +14427,13 @@ rm -f core conftest.err conftest.$ac_objext \
     osf4* | osf5*)	# as osf3* with the addition of -msym flag
       if test "$GCC" = yes; then
 	allow_undefined_flag_FC=' ${wl}-expect_unresolved ${wl}\*'
-	archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds_FC='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
       else
 	allow_undefined_flag_FC=' -expect_unresolved \*'
-	archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 	archive_expsym_cmds_FC='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
-	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
+	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
 
 	# Both c and cxx compiler support -rpath directly
 	hardcode_libdir_flag_spec_FC='-rpath $libdir'
@@ -13627,9 +14446,9 @@ rm -f core conftest.err conftest.$ac_objext \
       no_undefined_flag_FC=' -z defs'
       if test "$GCC" = yes; then
 	wlarc='${wl}'
-	archive_cmds_FC='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_cmds_FC='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	archive_expsym_cmds_FC='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	  $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
+	  $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
       else
 	case `$CC -V 2>&1` in
 	*"Compilers 5.0"*)
@@ -13808,44 +14627,50 @@ x|xyes)
       # to ld, don't add -lc before -lgcc.
       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-      $RM conftest*
-      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
+if ${lt_cv_archive_cmds_need_lc_FC+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  $RM conftest*
+	echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
-      if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+	if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; } 2>conftest.err; then
-        soname=conftest
-        lib=conftest
-        libobjs=conftest.$ac_objext
-        deplibs=
-        wl=$lt_prog_compiler_wl_FC
-	pic_flag=$lt_prog_compiler_pic_FC
-        compiler_flags=-v
-        linker_flags=-v
-        verstring=
-        output_objdir=.
-        libname=conftest
-        lt_save_allow_undefined_flag=$allow_undefined_flag_FC
-        allow_undefined_flag_FC=
-        if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_FC 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
+	  soname=conftest
+	  lib=conftest
+	  libobjs=conftest.$ac_objext
+	  deplibs=
+	  wl=$lt_prog_compiler_wl_FC
+	  pic_flag=$lt_prog_compiler_pic_FC
+	  compiler_flags=-v
+	  linker_flags=-v
+	  verstring=
+	  output_objdir=.
+	  libname=conftest
+	  lt_save_allow_undefined_flag=$allow_undefined_flag_FC
+	  allow_undefined_flag_FC=
+	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_FC 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
   (eval $archive_cmds_FC 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; }
-        then
-	  archive_cmds_need_lc_FC=no
-        else
-	  archive_cmds_need_lc_FC=yes
-        fi
-        allow_undefined_flag_FC=$lt_save_allow_undefined_flag
-      else
-        cat conftest.err 1>&5
-      fi
-      $RM conftest*
-      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc_FC" >&5
-$as_echo "$archive_cmds_need_lc_FC" >&6; }
+	  then
+	    lt_cv_archive_cmds_need_lc_FC=no
+	  else
+	    lt_cv_archive_cmds_need_lc_FC=yes
+	  fi
+	  allow_undefined_flag_FC=$lt_save_allow_undefined_flag
+	else
+	  cat conftest.err 1>&5
+	fi
+	$RM conftest*
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_FC" >&5
+$as_echo "$lt_cv_archive_cmds_need_lc_FC" >&6; }
+      archive_cmds_need_lc_FC=$lt_cv_archive_cmds_need_lc_FC
       ;;
     esac
   fi
@@ -14002,7 +14827,7 @@ amigaos*)
   m68k)
     library_names_spec='$libname.ixlibrary $libname.a'
     # Create ${libname}_ixlibrary.a entries in /sys/libs.
-    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
+    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
     ;;
   esac
   ;;
@@ -14033,8 +14858,9 @@ cygwin* | mingw* | pw32* | cegcc*)
   need_version=no
   need_lib_prefix=no
 
-  case $GCC,$host_os in
-  yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
+  case $GCC,$cc_basename in
+  yes,*)
+    # gcc
     library_names_spec='$libname.dll.a'
     # DLL is installed to $(libdir)/../bin by postinstall_cmds
     postinstall_cmds='base_file=`basename \${file}`~
@@ -14055,36 +14881,82 @@ cygwin* | mingw* | pw32* | cegcc*)
     cygwin*)
       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+
       ;;
     mingw* | cegcc*)
       # MinGW DLLs use traditional 'lib' prefix
       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
-        # It is most probably a Windows format PATH printed by
-        # mingw gcc, but we are running on Cygwin. Gcc prints its search
-        # path with ; separators, and with drive letters. We can handle the
-        # drive letters (cygwin fileutils understands them), so leave them,
-        # especially as we might pass files found there to a mingw objdump,
-        # which wouldn't understand a cygwinified path. Ahh.
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
-      else
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-      fi
       ;;
     pw32*)
       # pw32 DLLs use 'pw' prefix rather than 'lib'
       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
       ;;
     esac
+    dynamic_linker='Win32 ld.exe'
+    ;;
+
+  *,cl*)
+    # Native MSVC
+    libname_spec='$name'
+    soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+    library_names_spec='${libname}.dll.lib'
+
+    case $build_os in
+    mingw*)
+      sys_lib_search_path_spec=
+      lt_save_ifs=$IFS
+      IFS=';'
+      for lt_path in $LIB
+      do
+        IFS=$lt_save_ifs
+        # Let DOS variable expansion print the short 8.3 style file name.
+        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
+        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
+      done
+      IFS=$lt_save_ifs
+      # Convert to MSYS style.
+      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
+      ;;
+    cygwin*)
+      # Convert to unix form, then to dos form, then back to unix form
+      # but this time dos style (no spaces!) so that the unix form looks
+      # like /cygdrive/c/PROGRA~1:/cygdr...
+      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
+      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
+      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      ;;
+    *)
+      sys_lib_search_path_spec="$LIB"
+      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
+        # It is most probably a Windows format PATH.
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
+      else
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      fi
+      # FIXME: find the short name or the path components, as spaces are
+      # common. (e.g. "Program Files" -> "PROGRA~1")
+      ;;
+    esac
+
+    # DLL is installed to $(libdir)/../bin by postinstall_cmds
+    postinstall_cmds='base_file=`basename \${file}`~
+      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
+      dldir=$destdir/`dirname \$dlpath`~
+      test -d \$dldir || mkdir -p \$dldir~
+      $install_prog $dir/$dlname \$dldir/$dlname'
+    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
+      dlpath=$dir/\$dldll~
+       $RM \$dlpath'
+    shlibpath_overrides_runpath=yes
+    dynamic_linker='Win32 link.exe'
     ;;
 
   *)
+    # Assume MSVC wrapper
     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
+    dynamic_linker='Win32 ld.exe'
     ;;
   esac
-  dynamic_linker='Win32 ld.exe'
   # FIXME: first we should search . and the directory the executable is in
   shlibpath_var=PATH
   ;;
@@ -14170,6 +15042,19 @@ gnu*)
   hardcode_into_libs=yes
   ;;
 
+haiku*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  dynamic_linker="$host_os runtime_loader"
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LIBRARY_PATH
+  shlibpath_overrides_runpath=yes
+  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
+  hardcode_into_libs=yes
+  ;;
+
 hpux9* | hpux10* | hpux11*)
   # Give a soname corresponding to the major version so that dld.sl refuses to
   # link against other versions.
@@ -14212,8 +15097,10 @@ hpux9* | hpux10* | hpux11*)
     soname_spec='${libname}${release}${shared_ext}$major'
     ;;
   esac
-  # HP-UX runs *really* slowly unless shared libraries are mode 555.
+  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
   postinstall_cmds='chmod 555 $lib'
+  # or fails outright, so override atomically:
+  install_override_mode=555
   ;;
 
 interix[3-9]*)
@@ -14271,7 +15158,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux* | k*bsd*-gnu)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -14280,25 +15167,34 @@ linux* | k*bsd*-gnu)
   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
   shlibpath_var=LD_LIBRARY_PATH
   shlibpath_overrides_runpath=no
+
   # Some binutils ld are patched to set DT_RUNPATH
-  save_LDFLAGS=$LDFLAGS
-  save_libdir=$libdir
-  eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_FC\"; \
-       LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_FC\""
-  cat > conftest.$ac_ext <<_ACEOF
+  if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_shlibpath_overrides_runpath=no
+    save_LDFLAGS=$LDFLAGS
+    save_libdir=$libdir
+    eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_FC\"; \
+	 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_FC\""
+    cat > conftest.$ac_ext <<_ACEOF
       program main
 
       end
 _ACEOF
 if ac_fn_fc_try_link "$LINENO"; then :
   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
-  shlibpath_overrides_runpath=yes
+  lt_cv_shlibpath_overrides_runpath=yes
 fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-  LDFLAGS=$save_LDFLAGS
-  libdir=$save_libdir
+    LDFLAGS=$save_LDFLAGS
+    libdir=$save_libdir
+
+fi
+
+  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
 
   # This implies no fast_install, which is unacceptable.
   # Some rework will be needed to allow for fast_install
@@ -14307,7 +15203,7 @@ rm -f core conftest.err conftest.$ac_objext \
 
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
@@ -14559,6 +15455,8 @@ fi
 
 
 
+
+
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
 hardcode_action_FC=
@@ -14606,7 +15504,8 @@ fi
   fi # test -n "$compiler"
 
   GCC=$lt_save_GCC
-  CC="$lt_save_CC"
+  CC=$lt_save_CC
+  CFLAGS=$lt_save_CFLAGS
 fi # test "$_lt_disable_FC" != yes
 
 ac_ext=c
@@ -14638,7 +15537,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
-if test "${ac_cv_c_const+set}" = set; then :
+if ${ac_cv_c_const+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -14718,7 +15617,7 @@ fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
 $as_echo_n "checking for inline... " >&6; }
-if test "${ac_cv_c_inline+set}" = set; then :
+if ${ac_cv_c_inline+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_cv_c_inline=no
@@ -14759,7 +15658,7 @@ _ACEOF
 esac
 
 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
-if test "x$ac_cv_type_size_t" = x""yes; then :
+if test "x$ac_cv_type_size_t" = xyes; then :
 
 else
 
@@ -14770,7 +15669,7 @@ _ACEOF
 fi
 
 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
-if test "x$ac_cv_type_pid_t" = x""yes; then :
+if test "x$ac_cv_type_pid_t" = xyes; then :
 
 else
 
@@ -14783,7 +15682,7 @@ fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
-if test "${ac_cv_header_time+set}" = set; then :
+if ${ac_cv_header_time+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -14818,7 +15717,7 @@ fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
-if test "${ac_cv_header_stdbool_h+set}" = set; then :
+if ${ac_cv_header_stdbool_h+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -14850,7 +15749,7 @@ else
 	char b[false == 0 ? 1 : -1];
 	char c[__bool_true_false_are_defined == 1 ? 1 : -1];
 	char d[(bool) 0.5 == true ? 1 : -1];
-	bool e = &s;
+	/* See body of main program for 'e'.  */
 	char f[(_Bool) 0.0 == false ? 1 : -1];
 	char g[true];
 	char h[sizeof (_Bool)];
@@ -14861,25 +15760,6 @@ else
 	_Bool n[m];
 	char o[sizeof n == m * sizeof n[0] ? 1 : -1];
 	char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
-#	if defined __xlc__ || defined __GNUC__
-	 /* Catch a bug in IBM AIX xlc compiler version 6.0.0.0
-	    reported by James Lemley on 2005-10-05; see
-	    http://lists.gnu.org/archive/html/bug-coreutils/2005-10/msg00086.html
-	    This test is not quite right, since xlc is allowed to
-	    reject this program, as the initializer for xlcbug is
-	    not one of the forms that C requires support for.
-	    However, doing the test right would require a runtime
-	    test, and that would make cross-compilation harder.
-	    Let us hope that IBM fixes the xlc bug, and also adds
-	    support for this kind of constant expression.  In the
-	    meantime, this test will reject xlc, which is OK, since
-	    our stdbool.h substitute should suffice.  We also test
-	    this with GCC, where it should work, to detect more
-	    quickly whether someone messes up the test in the
-	    future.  */
-	 char digs[] = "0123456789";
-	 int xlcbug = 1 / (&(digs + 5)[-2 + (bool) 1] == &digs[4] ? 1 : -1);
-#	endif
 	/* Catch a bug in an HP-UX C compiler.  See
 	   http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
 	   http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
@@ -14891,6 +15771,7 @@ int
 main ()
 {
 
+	bool e = &s;
 	*pq |= q;
 	*pq |= ! q;
 	/* Refer to every declared value, to avoid compiler optimizations.  */
@@ -14911,7 +15792,7 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
 $as_echo "$ac_cv_header_stdbool_h" >&6; }
 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
-if test "x$ac_cv_type__Bool" = x""yes; then :
+if test "x$ac_cv_type__Bool" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE__BOOL 1
@@ -14928,7 +15809,7 @@ fi
 
 
 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
-if test "x$ac_cv_type_long_long" = x""yes; then :
+if test "x$ac_cv_type_long_long" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_LONG_LONG 1
@@ -14937,7 +15818,7 @@ _ACEOF
 
 fi
 ac_fn_c_check_type "$LINENO" "unsigned long long" "ac_cv_type_unsigned_long_long" "$ac_includes_default"
-if test "x$ac_cv_type_unsigned_long_long" = x""yes; then :
+if test "x$ac_cv_type_unsigned_long_long" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_UNSIGNED_LONG_LONG 1
@@ -14947,7 +15828,7 @@ _ACEOF
 fi
 
 ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
-if test "x$ac_cv_type_int32_t" = x""yes; then :
+if test "x$ac_cv_type_int32_t" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_INT32_T 1
@@ -14957,7 +15838,7 @@ _ACEOF
 fi
 
 ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default"
-if test "x$ac_cv_type_int64_t" = x""yes; then :
+if test "x$ac_cv_type_int64_t" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_INT64_T 1
@@ -14967,7 +15848,7 @@ _ACEOF
 fi
 
 ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
-if test "x$ac_cv_type_uint32_t" = x""yes; then :
+if test "x$ac_cv_type_uint32_t" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_UINT32_T 1
@@ -14977,7 +15858,7 @@ _ACEOF
 fi
 
 ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "$ac_includes_default"
-if test "x$ac_cv_type_uint64_t" = x""yes; then :
+if test "x$ac_cv_type_uint64_t" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_UINT64_T 1
@@ -14987,7 +15868,7 @@ _ACEOF
 fi
 
 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
-if test "x$ac_cv_type_ptrdiff_t" = x""yes; then :
+if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_PTRDIFF_T 1
@@ -15003,7 +15884,7 @@ fi
 # This bug is HP SR number 8606223364.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
 $as_echo_n "checking size of void *... " >&6; }
-if test "${ac_cv_sizeof_void_p+set}" = set; then :
+if ${ac_cv_sizeof_void_p+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p"        "$ac_includes_default"; then :
@@ -15012,9 +15893,8 @@ else
   if test "$ac_cv_type_void_p" = yes; then
      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (void *)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (void *)
+See \`config.log' for more details" "$LINENO" 5; }
    else
      ac_cv_sizeof_void_p=0
    fi
@@ -15037,7 +15917,7 @@ _ACEOF
 # This bug is HP SR number 8606223364.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
 $as_echo_n "checking size of short... " >&6; }
-if test "${ac_cv_sizeof_short+set}" = set; then :
+if ${ac_cv_sizeof_short+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
@@ -15046,9 +15926,8 @@ else
   if test "$ac_cv_type_short" = yes; then
      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (short)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (short)
+See \`config.log' for more details" "$LINENO" 5; }
    else
      ac_cv_sizeof_short=0
    fi
@@ -15071,7 +15950,7 @@ _ACEOF
 # This bug is HP SR number 8606223364.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
 $as_echo_n "checking size of int... " >&6; }
-if test "${ac_cv_sizeof_int+set}" = set; then :
+if ${ac_cv_sizeof_int+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
@@ -15080,9 +15959,8 @@ else
   if test "$ac_cv_type_int" = yes; then
      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (int)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (int)
+See \`config.log' for more details" "$LINENO" 5; }
    else
      ac_cv_sizeof_int=0
    fi
@@ -15105,7 +15983,7 @@ _ACEOF
 # This bug is HP SR number 8606223364.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
 $as_echo_n "checking size of long... " >&6; }
-if test "${ac_cv_sizeof_long+set}" = set; then :
+if ${ac_cv_sizeof_long+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
@@ -15114,9 +15992,8 @@ else
   if test "$ac_cv_type_long" = yes; then
      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (long)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (long)
+See \`config.log' for more details" "$LINENO" 5; }
    else
      ac_cv_sizeof_long=0
    fi
@@ -15139,7 +16016,7 @@ _ACEOF
 # This bug is HP SR number 8606223364.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5
 $as_echo_n "checking size of float... " >&6; }
-if test "${ac_cv_sizeof_float+set}" = set; then :
+if ${ac_cv_sizeof_float+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (float))" "ac_cv_sizeof_float"        "$ac_includes_default"; then :
@@ -15148,9 +16025,8 @@ else
   if test "$ac_cv_type_float" = yes; then
      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (float)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (float)
+See \`config.log' for more details" "$LINENO" 5; }
    else
      ac_cv_sizeof_float=0
    fi
@@ -15173,7 +16049,7 @@ _ACEOF
 # This bug is HP SR number 8606223364.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5
 $as_echo_n "checking size of double... " >&6; }
-if test "${ac_cv_sizeof_double+set}" = set; then :
+if ${ac_cv_sizeof_double+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double"        "$ac_includes_default"; then :
@@ -15182,9 +16058,8 @@ else
   if test "$ac_cv_type_double" = yes; then
      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (double)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (double)
+See \`config.log' for more details" "$LINENO" 5; }
    else
      ac_cv_sizeof_double=0
    fi
@@ -15237,7 +16112,9 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
 
 
 if test "x$cs_fc_flush" = "xyes"; then
-  FCFLAGS="${FCFLAGS} -D_CS_FC_HAVE_FLUSH"
+  if test "x$cs_ibm_bg_type" = "x" ; then
+    FCFLAGS="${FCFLAGS} -D_CS_FC_HAVE_FLUSH"
+  fi
 fi
 
 unset $cs_fc_flush
@@ -15264,7 +16141,7 @@ if test "${enable_openmp+set}" = set; then :
     case "${enableval}" in
       yes) cs_have_openmp=yes ;;
       no)  cs_have_openmp=no ;;
-      *)   as_fn_error "bad value ${enableval} for --enable-openmp" "$LINENO" 5 ;;
+      *)   as_fn_error $? "bad value ${enableval} for --enable-openmp" "$LINENO" 5 ;;
     esac
 
 else
@@ -15434,8 +16311,8 @@ if test    "$bft_version_major_min" = "" \
         -o "$bft_version_release_min" = ""; then
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "bad BFT version definition in configure.ac: $bft_version_min
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "bad BFT version definition in configure.ac: $bft_version_min
+See \`config.log' for more details" "$LINENO" 5; }
 fi
 
 if test "x$bft_version_max" != "x" ; then
@@ -15447,8 +16324,8 @@ if test "x$bft_version_max" != "x" ; then
           -o "$bft_version_release_max" = ""; then
     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "bad BFT version definition in configure.ac: $bft_version_max
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "bad BFT version definition in configure.ac: $bft_version_max
+See \`config.log' for more details" "$LINENO" 5; }
   fi
 else
   bft_version_major_max=99999999
@@ -15504,8 +16381,8 @@ $as_echo "compatible bft version found" >&6; }
 else
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "compatible bft version not found
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "compatible bft version not found
+See \`config.log' for more details" "$LINENO" 5; }
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
@@ -15633,8 +16510,8 @@ if test    "$fvm_version_major_min" = "" \
         -o "$fvm_version_release_min" = ""; then
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "bad FVM version definition in configure.ac: $fvm_version_min
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "bad FVM version definition in configure.ac: $fvm_version_min
+See \`config.log' for more details" "$LINENO" 5; }
 fi
 
 if test "x$fvm_version_max" != "x" ; then
@@ -15646,8 +16523,8 @@ if test "x$fvm_version_max" != "x" ; then
           -o "$fvm_version_release_max" = ""; then
     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "bad FVM version definition in configure.ac: $fvm_version_max
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "bad FVM version definition in configure.ac: $fvm_version_max
+See \`config.log' for more details" "$LINENO" 5; }
   fi
 else
   fvm_version_major_max=99999999
@@ -15703,8 +16580,8 @@ $as_echo "compatible fvm version found" >&6; }
 else
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "compatible fvm version not found
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "compatible fvm version not found
+See \`config.log' for more details" "$LINENO" 5; }
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
@@ -15844,7 +16721,7 @@ if test "x$with_mei" != "xno" ; then
   LIBS="${LIBS} ${MEI_LIBS} -lbft"
 
   ac_fn_c_check_header_mongrel "$LINENO" "mei_evaluate.h" "ac_cv_header_mei_evaluate_h" "$ac_includes_default"
-if test "x$ac_cv_header_mei_evaluate_h" = x""yes; then :
+if test "x$ac_cv_header_mei_evaluate_h" = xyes; then :
 
 fi
 
@@ -15852,7 +16729,7 @@ fi
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mei_evaluate in -lmei" >&5
 $as_echo_n "checking for mei_evaluate in -lmei... " >&6; }
-if test "${ac_cv_lib_mei_mei_evaluate+set}" = set; then :
+if ${ac_cv_lib_mei_mei_evaluate+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -15886,7 +16763,7 @@ LIBS=$ac_check_lib_save_LIBS
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mei_mei_evaluate" >&5
 $as_echo "$ac_cv_lib_mei_mei_evaluate" >&6; }
-if test "x$ac_cv_lib_mei_mei_evaluate" = x""yes; then :
+if test "x$ac_cv_lib_mei_mei_evaluate" = xyes; then :
 
 $as_echo "#define HAVE_MEI 1" >>confdefs.h
 
@@ -15895,8 +16772,8 @@ $as_echo "#define HAVE_MEI 1" >>confdefs.h
 else
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "MEI support is requested, but test for MEI failed!
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "MEI support is requested, but test for MEI failed!
+See \`config.log' for more details" "$LINENO" 5; }
 
 fi
 
@@ -15994,7 +16871,7 @@ if test "x$with_libxml2" != "xno" ; then
   LIBS="${LIBS} ${LIBXML2_LIBS}"
 
   ac_fn_c_check_header_mongrel "$LINENO" "libxml/parser.h" "ac_cv_header_libxml_parser_h" "$ac_includes_default"
-if test "x$ac_cv_header_libxml_parser_h" = x""yes; then :
+if test "x$ac_cv_header_libxml_parser_h" = xyes; then :
 
 fi
 
@@ -16002,7 +16879,7 @@ fi
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xmlInitParser in -lxml2" >&5
 $as_echo_n "checking for xmlInitParser in -lxml2... " >&6; }
-if test "${ac_cv_lib_xml2_xmlInitParser+set}" = set; then :
+if ${ac_cv_lib_xml2_xmlInitParser+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -16036,7 +16913,7 @@ LIBS=$ac_check_lib_save_LIBS
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_xmlInitParser" >&5
 $as_echo "$ac_cv_lib_xml2_xmlInitParser" >&6; }
-if test "x$ac_cv_lib_xml2_xmlInitParser" = x""yes; then :
+if test "x$ac_cv_lib_xml2_xmlInitParser" = xyes; then :
 
 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
 
@@ -16046,8 +16923,8 @@ else
   if test "x$with_libxml2" != "xcheck" ; then
                   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "LIBXML2 support is requested, but test for LIBXML2 failed!
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "LIBXML2 support is requested, but test for LIBXML2 failed!
+See \`config.log' for more details" "$LINENO" 5; }
                 else
                   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no LIBXML2 support" >&5
 $as_echo "$as_me: WARNING: no LIBXML2 support" >&2;}
@@ -16152,12 +17029,6 @@ if test "x$with_blas" != "xno" ; then
 
   # Add known paths and libraries for Blue Gene/L or P if not given
 
-  if test "x$with_blas_type" = "x" ; then
-    if test "x$cs_ibm_bg_type" != "x" ; then
-      with_blas_type="ESSL"
-    fi
-  fi
-
   # Test for IBM ESSL BLAS
 
   if test "x$with_blas_type" = "x" -o "x$with_blas_type" = "xESSL" ; then
@@ -16166,22 +17037,6 @@ if test "x$with_blas" != "xno" ; then
     # Fortran libraries, and header is for C. Test library (link) first,
     # as header is only useful if library is present.
 
-    if test "x$BLAS_CPPFLAGS" = "x" ; then
-      if test "x$cs_ibm_bg_type" = "xL" ; then
-        BLAS_CPPFLAGS="-I/opt/ibmmath/essl/4.2/include"
-      elif test "x$cs_ibm_bg_type" = "xP" ; then
-        BLAS_CPPFLAGS="-I/opt/ibmmath/essl/4.4/include"
-      fi
-    fi
-
-    if test "x$BLAS_LDFLAGS" = "x" ; then
-      if test "x$cs_ibm_bg_type" = "xL" ; then
-        BLAS_LDFLAGS="-L/opt/ibmmath/essl/4.2/lib"
-      elif test "x$cs_ibm_bg_type" = "xP" ; then
-        BLAS_LDFLAGS="-L/opt/ibmmath/essl/4.4/lib"
-      fi
-    fi
-
     ac_ext=${ac_fc_srcext-f}
 ac_compile='$FC -c $FCFLAGS $ac_fcflags_srcext conftest.$ac_ext >&5'
 ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest.$ac_ext $LIBS >&5'
@@ -16575,8 +17430,8 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
     if test "x$with_blas" != "xcheck" ; then
       { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "BLAS support is requested, but test for BLAS failed!
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "BLAS support is requested, but test for BLAS failed!
+See \`config.log' for more details" "$LINENO" 5; }
     else
       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no BLAS support" >&5
 $as_echo "$as_me: WARNING: no BLAS support" >&2;}
@@ -16881,8 +17736,8 @@ $as_echo "$cs_have_mpi" >&6; }
     if test "x$with_mpi" != "xcheck" ; then
       { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "MPI support is requested, but test for MPI failed!
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "MPI support is requested, but test for MPI failed!
+See \`config.log' for more details" "$LINENO" 5; }
     else
       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no MPI support" >&5
 $as_echo "$as_me: WARNING: no MPI support" >&2;}
@@ -16895,9 +17750,9 @@ $as_echo "$as_me: WARNING: no MPI support" >&2;}
     CPPFLAGS="$saved_CPPFLAGS $MPI_CPPFLAGS"
     mpi_type=""
     if test "x$cs_ibm_bg_type" != "x" ; then
-      if test "x$cs_ibm_bg_type" = "L" ; then
+      if test "x$cs_ibm_bg_type" = "xL" ; then
         mpi_type=BGL_MPI
-      elif test "x$cs_ibm_bg_type" = "P" ; then
+      elif test "x$cs_ibm_bg_type" = "xP" ; then
         mpi_type=BGP_MPI
       fi
     fi
@@ -16951,286 +17806,68 @@ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
 fi
 rm -f conftest*
 
-    fi
-    if test "x$mpi_type" = "x"; then
-      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h.  */
-
-                    #include <mpi.h>
-                    #ifdef LAM_MPI
-                    lam_mpi
-                    #endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "lam_mpi" >/dev/null 2>&1; then :
-  mpi_type=LAM_MPI
-fi
-rm -f conftest*
-
-    fi
-    if test "x$mpi_type" = "x"; then
-      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h.  */
-
-                    #include <mpi.h>
-                    #ifdef HP_MPI
-                    hp_mpi
-                    #endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "hp_mpi" >/dev/null 2>&1; then :
-  mpi_type=HP_MPI
-fi
-rm -f conftest*
-
-    fi
-  fi
-
-  CPPFLAGS="$saved_CPPFLAGS"
-  LDFLAGS="$saved_LDFLAGS"
-  LIBS="$saved_LIBS"
-
-  unset saved_CPPFLAGS
-  unset saved_LDFLAGS
-  unset saved_LIBS
-
-fi
-
- if test x$cs_have_mpi = xyes; then
-  HAVE_MPI_TRUE=
-  HAVE_MPI_FALSE='#'
-else
-  HAVE_MPI_TRUE='#'
-  HAVE_MPI_FALSE=
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-ac_ext=f
-ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5'
-ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_f77_compiler_gnu
-if test -n "$ac_tool_prefix"; then
-  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn
-  do
-    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_F77+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  if test -n "$F77"; then
-  ac_cv_prog_F77="$F77" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-    for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_F77="$ac_tool_prefix$ac_prog"
-    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-  done
-IFS=$as_save_IFS
-
-fi
-fi
-F77=$ac_cv_prog_F77
-if test -n "$F77"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $F77" >&5
-$as_echo "$F77" >&6; }
-else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-    test -n "$F77" && break
-  done
-fi
-if test -z "$F77"; then
-  ac_ct_F77=$F77
-  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_F77+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  if test -n "$ac_ct_F77"; then
-  ac_cv_prog_ac_ct_F77="$ac_ct_F77" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-    for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_F77="$ac_prog"
-    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-  done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_F77=$ac_cv_prog_ac_ct_F77
-if test -n "$ac_ct_F77"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_F77" >&5
-$as_echo "$ac_ct_F77" >&6; }
-else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-  test -n "$ac_ct_F77" && break
-done
-
-  if test "x$ac_ct_F77" = x; then
-    F77=""
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
-    F77=$ac_ct_F77
-  fi
-fi
-
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for Fortran 77 compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
-  { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
-  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
-  ac_status=$?
-  if test -s conftest.err; then
-    sed '10a\
-... rest of stderr output deleted ...
-         10q' conftest.err >conftest.er1
-    cat conftest.er1 >&5
-  fi
-  rm -f conftest.er1 conftest.err
-  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-  test $ac_status = 0; }
-done
-rm -f a.out
-
-# If we don't use `.F' as extension, the preprocessor is not run on the
-# input file.  (Note that this only needs to work for GNU compilers.)
-ac_save_ext=$ac_ext
-ac_ext=F
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Fortran 77 compiler" >&5
-$as_echo_n "checking whether we are using the GNU Fortran 77 compiler... " >&6; }
-if test "${ac_cv_f77_compiler_gnu+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  cat > conftest.$ac_ext <<_ACEOF
-      program main
-#ifndef __GNUC__
-       choke me
-#endif
-
-      end
+    fi
+    if test "x$mpi_type" = "x"; then
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+                    #include <mpi.h>
+                    #ifdef LAM_MPI
+                    lam_mpi
+                    #endif
+
 _ACEOF
-if ac_fn_f77_try_compile "$LINENO"; then :
-  ac_compiler_gnu=yes
-else
-  ac_compiler_gnu=no
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "lam_mpi" >/dev/null 2>&1; then :
+  mpi_type=LAM_MPI
 fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_f77_compiler_gnu=$ac_compiler_gnu
+rm -f conftest*
 
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_f77_compiler_gnu" >&5
-$as_echo "$ac_cv_f77_compiler_gnu" >&6; }
-ac_ext=$ac_save_ext
-ac_test_FFLAGS=${FFLAGS+set}
-ac_save_FFLAGS=$FFLAGS
-FFLAGS=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $F77 accepts -g" >&5
-$as_echo_n "checking whether $F77 accepts -g... " >&6; }
-if test "${ac_cv_prog_f77_g+set}" = set; then :
-  $as_echo_n "(cached) " >&6
-else
-  FFLAGS=-g
-cat > conftest.$ac_ext <<_ACEOF
-      program main
+    fi
+    if test "x$mpi_type" = "x"; then
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+                    #include <mpi.h>
+                    #ifdef HP_MPI
+                    hp_mpi
+                    #endif
 
-      end
 _ACEOF
-if ac_fn_f77_try_compile "$LINENO"; then :
-  ac_cv_prog_f77_g=yes
-else
-  ac_cv_prog_f77_g=no
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "hp_mpi" >/dev/null 2>&1; then :
+  mpi_type=HP_MPI
 fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f conftest*
 
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_f77_g" >&5
-$as_echo "$ac_cv_prog_f77_g" >&6; }
-if test "$ac_test_FFLAGS" = set; then
-  FFLAGS=$ac_save_FFLAGS
-elif test $ac_cv_prog_f77_g = yes; then
-  if test "x$ac_cv_f77_compiler_gnu" = xyes; then
-    FFLAGS="-g -O2"
-  else
-    FFLAGS="-g"
-  fi
-else
-  if test "x$ac_cv_f77_compiler_gnu" = xyes; then
-    FFLAGS="-O2"
-  else
-    FFLAGS=
+    fi
   fi
+
+  CPPFLAGS="$saved_CPPFLAGS"
+  LDFLAGS="$saved_LDFLAGS"
+  LIBS="$saved_LIBS"
+
+  unset saved_CPPFLAGS
+  unset saved_LDFLAGS
+  unset saved_LIBS
+
 fi
 
-if test $ac_compiler_gnu = yes; then
-  G77=yes
+ if test x$cs_have_mpi = xyes; then
+  HAVE_MPI_TRUE=
+  HAVE_MPI_FALSE='#'
 else
-  G77=
+  HAVE_MPI_TRUE='#'
+  HAVE_MPI_FALSE=
 fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
 
-if test -z "$F77" || test "X$F77" = "Xno"; then
-  _lt_disable_F77=yes
-fi
+
+
+
+
+
+
+
 
 
 ac_ext=f
@@ -17238,13 +17875,13 @@ ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5'
 ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_f77_compiler_gnu
 if test -n "$ac_tool_prefix"; then
-  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn
+  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn
   do
     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_F77+set}" = set; then :
+if ${ac_cv_prog_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$F77"; then
@@ -17282,13 +17919,13 @@ fi
 fi
 if test -z "$F77"; then
   ac_ct_F77=$F77
-  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn
+  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_F77+set}" = set; then :
+if ${ac_cv_prog_ac_ct_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_F77"; then
@@ -17370,7 +18007,7 @@ ac_save_ext=$ac_ext
 ac_ext=F
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Fortran 77 compiler" >&5
 $as_echo_n "checking whether we are using the GNU Fortran 77 compiler... " >&6; }
-if test "${ac_cv_f77_compiler_gnu+set}" = set; then :
+if ${ac_cv_f77_compiler_gnu+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat > conftest.$ac_ext <<_ACEOF
@@ -17398,7 +18035,7 @@ ac_save_FFLAGS=$FFLAGS
 FFLAGS=
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $F77 accepts -g" >&5
 $as_echo_n "checking whether $F77 accepts -g... " >&6; }
-if test "${ac_cv_prog_f77_g+set}" = set; then :
+if ${ac_cv_prog_f77_g+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   FFLAGS=-g
@@ -17449,13 +18086,13 @@ ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5'
 ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_f77_compiler_gnu
 if test -n "$ac_tool_prefix"; then
-  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn
+  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn
   do
     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_F77+set}" = set; then :
+if ${ac_cv_prog_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$F77"; then
@@ -17493,13 +18130,13 @@ fi
 fi
 if test -z "$F77"; then
   ac_ct_F77=$F77
-  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn
+  for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_F77+set}" = set; then :
+if ${ac_cv_prog_ac_ct_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -n "$ac_ct_F77"; then
@@ -17581,7 +18218,7 @@ ac_save_ext=$ac_ext
 ac_ext=F
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Fortran 77 compiler" >&5
 $as_echo_n "checking whether we are using the GNU Fortran 77 compiler... " >&6; }
-if test "${ac_cv_f77_compiler_gnu+set}" = set; then :
+if ${ac_cv_f77_compiler_gnu+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat > conftest.$ac_ext <<_ACEOF
@@ -17609,7 +18246,7 @@ ac_save_FFLAGS=$FFLAGS
 FFLAGS=
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $F77 accepts -g" >&5
 $as_echo_n "checking whether $F77 accepts -g... " >&6; }
-if test "${ac_cv_prog_f77_g+set}" = set; then :
+if ${ac_cv_prog_f77_g+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   FFLAGS=-g
@@ -17659,6 +18296,9 @@ ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5'
 ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_f77_compiler_gnu
 
+if test -z "$F77" || test "X$F77" = "Xno"; then
+  _lt_disable_F77=yes
+fi
 
 archive_cmds_need_lc_F77=no
 allow_undefined_flag_F77=
@@ -17677,6 +18317,8 @@ module_cmds_F77=
 module_expsym_cmds_F77=
 link_all_deplibs_F77=unknown
 old_archive_cmds_F77=$old_archive_cmds
+reload_flag_F77=$reload_flag
+reload_cmds_F77=$reload_cmds
 no_undefined_flag_F77=
 whole_archive_flag_spec_F77=
 enable_shared_with_static_runtimes_F77=no
@@ -17740,7 +18382,9 @@ $RM -r conftest*
   # Allow CC to be a program name with arguments.
   lt_save_CC="$CC"
   lt_save_GCC=$GCC
+  lt_save_CFLAGS=$CFLAGS
   CC=${F77-"f77"}
+  CFLAGS=$FFLAGS
   compiler=$CC
   compiler_F77=$CC
   for cc_temp in $compiler""; do
@@ -17751,7 +18395,7 @@ $RM -r conftest*
     *) break;;
   esac
 done
-cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
+cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
 
   GCC=$G77
   if test -n "$compiler"; then
@@ -17801,8 +18445,6 @@ $as_echo "$enable_static" >&6; }
 lt_prog_compiler_pic_F77=
 lt_prog_compiler_static_F77=
 
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
 
   if test "$GCC" = yes; then
     lt_prog_compiler_wl_F77='-Wl,'
@@ -17850,6 +18492,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic_F77='-fno-common'
       ;;
 
+    haiku*)
+      # PIC is the default for Haiku.
+      # The "-static" flag exists, but is broken.
+      lt_prog_compiler_static_F77=
+      ;;
+
     hpux*)
       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
@@ -17892,6 +18540,13 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic_F77='-fPIC'
       ;;
     esac
+
+    case $cc_basename in
+    nvcc*) # Cuda Compiler Driver 2.2
+      lt_prog_compiler_wl_F77='-Xlinker '
+      lt_prog_compiler_pic_F77='-Xcompiler -fPIC'
+      ;;
+    esac
   else
     # PORTME Check for flag to pass linker flags through the system compiler.
     case $host_os in
@@ -17933,7 +18588,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_static_F77='-non_shared'
       ;;
 
-    linux* | k*bsd*-gnu)
+    linux* | k*bsd*-gnu | kopensolaris*-gnu)
       case $cc_basename in
       # old Intel for x86_64 which still supported -KPIC.
       ecc*)
@@ -17954,7 +18609,13 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
 	lt_prog_compiler_pic_F77='--shared'
 	lt_prog_compiler_static_F77='--static'
 	;;
-      pgcc* | pgf77* | pgf90* | pgf95*)
+      nagfor*)
+	# NAG Fortran compiler
+	lt_prog_compiler_wl_F77='-Wl,-Wl,,'
+	lt_prog_compiler_pic_F77='-PIC'
+	lt_prog_compiler_static_F77='-Bstatic'
+	;;
+      pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
         # Portland Group compilers (*not* the Pentium gcc compiler,
 	# which looks to be a dead project)
 	lt_prog_compiler_wl_F77='-Wl,'
@@ -17966,25 +18627,25 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
         # All Alpha code is PIC.
         lt_prog_compiler_static_F77='-non_shared'
         ;;
-      xl*)
-	# IBM XL C 8.0/Fortran 10.1 on PPC
+      xl* | bgxl* | bgf* | mpixl*)
+	# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
 	lt_prog_compiler_wl_F77='-Wl,'
 	lt_prog_compiler_pic_F77='-qpic'
 	lt_prog_compiler_static_F77='-qstaticlink'
 	;;
       *)
 	case `$CC -V 2>&1 | sed 5q` in
-	*Sun\ C*)
-	  # Sun C 5.9
+	*Sun\ F* | *Sun*Fortran*)
+	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
 	  lt_prog_compiler_pic_F77='-KPIC'
 	  lt_prog_compiler_static_F77='-Bstatic'
-	  lt_prog_compiler_wl_F77='-Wl,'
+	  lt_prog_compiler_wl_F77=''
 	  ;;
-	*Sun\ F*)
-	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
+	*Sun\ C*)
+	  # Sun C 5.9
 	  lt_prog_compiler_pic_F77='-KPIC'
 	  lt_prog_compiler_static_F77='-Bstatic'
-	  lt_prog_compiler_wl_F77=''
+	  lt_prog_compiler_wl_F77='-Wl,'
 	  ;;
 	esac
 	;;
@@ -18016,7 +18677,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
       lt_prog_compiler_pic_F77='-KPIC'
       lt_prog_compiler_static_F77='-Bstatic'
       case $cc_basename in
-      f77* | f90* | f95*)
+      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
 	lt_prog_compiler_wl_F77='-Qoption ld ';;
       *)
 	lt_prog_compiler_wl_F77='-Wl,';;
@@ -18073,10 +18734,17 @@ case $host_os in
     lt_prog_compiler_pic_F77="$lt_prog_compiler_pic_F77"
     ;;
 esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_F77" >&5
-$as_echo "$lt_prog_compiler_pic_F77" >&6; }
-
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
+$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+if ${lt_cv_prog_compiler_pic_F77+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_prog_compiler_pic_F77=$lt_prog_compiler_pic_F77
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_F77" >&5
+$as_echo "$lt_cv_prog_compiler_pic_F77" >&6; }
+lt_prog_compiler_pic_F77=$lt_cv_prog_compiler_pic_F77
 
 #
 # Check to make sure the PIC flag actually works.
@@ -18084,7 +18752,7 @@ $as_echo "$lt_prog_compiler_pic_F77" >&6; }
 if test -n "$lt_prog_compiler_pic_F77"; then
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5
 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... " >&6; }
-if test "${lt_cv_prog_compiler_pic_works_F77+set}" = set; then :
+if ${lt_cv_prog_compiler_pic_works_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_pic_works_F77=no
@@ -18100,15 +18768,15 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:18103: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:18107: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_pic_works_F77=yes
@@ -18134,13 +18802,15 @@ fi
 
 
 
+
+
 #
 # Check to make sure the static flag actually works.
 #
 wl=$lt_prog_compiler_wl_F77 eval lt_tmp_static_flag=\"$lt_prog_compiler_static_F77\"
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if test "${lt_cv_prog_compiler_static_works_F77+set}" = set; then :
+if ${lt_cv_prog_compiler_static_works_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_static_works_F77=no
@@ -18153,7 +18823,7 @@ else
      if test -s conftest.err; then
        # Append any errors to the config.log.
        cat conftest.err 1>&5
-       $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
        if diff conftest.exp conftest.er2 >/dev/null; then
          lt_cv_prog_compiler_static_works_F77=yes
@@ -18180,7 +18850,7 @@ fi
 
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then :
+if ${lt_cv_prog_compiler_c_o_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_c_o_F77=no
@@ -18199,16 +18869,16 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:18202: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:18206: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o_F77=yes
@@ -18232,7 +18902,7 @@ $as_echo "$lt_cv_prog_compiler_c_o_F77" >&6; }
 
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then :
+if ${lt_cv_prog_compiler_c_o_F77+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   lt_cv_prog_compiler_c_o_F77=no
@@ -18251,16 +18921,16 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:18254: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:18258: \$? = $ac_status" >&5
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o_F77=yes
@@ -18370,7 +19040,33 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
   esac
 
   ld_shlibs_F77=yes
+
+  # On some targets, GNU ld is compatible enough with the native linker
+  # that we're better off using the native interface for both.
+  lt_use_gnu_ld_interface=no
   if test "$with_gnu_ld" = yes; then
+    case $host_os in
+      aix*)
+	# The AIX port of GNU ld has always aspired to compatibility
+	# with the native linker.  However, as the warning in the GNU ld
+	# block says, versions before 2.19.5* couldn't really create working
+	# shared libraries, regardless of the interface used.
+	case `$LD -v 2>&1` in
+	  *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
+	  *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
+	  *\ \(GNU\ Binutils\)\ [3-9]*) ;;
+	  *)
+	    lt_use_gnu_ld_interface=yes
+	    ;;
+	esac
+	;;
+      *)
+	lt_use_gnu_ld_interface=yes
+	;;
+    esac
+  fi
+
+  if test "$lt_use_gnu_ld_interface" = yes; then
     # If archive_cmds runs LD, not CC, wlarc should be empty
     wlarc='${wl}'
 
@@ -18388,6 +19084,7 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
     fi
     supports_anon_versioning=no
     case `$LD -v 2>&1` in
+      *GNU\ gold*) supports_anon_versioning=yes ;;
       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
@@ -18403,11 +19100,12 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
 	ld_shlibs_F77=no
 	cat <<_LT_EOF 1>&2
 
-*** Warning: the GNU linker, at least up to release 2.9.1, is reported
+*** Warning: the GNU linker, at least up to release 2.19, is reported
 *** to be unable to reliably create shared libraries on AIX.
 *** Therefore, libtool is disabling shared libraries support.  If you
-*** really care for shared libraries, you may want to modify your PATH
-*** so that a non-GNU linker is found, and then restart.
+*** really care for shared libraries, you may want to install binutils
+*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
+*** You will then need to restart the configuration process.
 
 _LT_EOF
       fi
@@ -18443,10 +19141,12 @@ _LT_EOF
       # _LT_TAGVAR(hardcode_libdir_flag_spec, F77) is actually meaningless,
       # as there is no search path for DLLs.
       hardcode_libdir_flag_spec_F77='-L$libdir'
+      export_dynamic_flag_spec_F77='${wl}--export-all-symbols'
       allow_undefined_flag_F77=unsupported
       always_export_symbols_F77=no
       enable_shared_with_static_runtimes_F77=yes
-      export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
+      export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
+      exclude_expsyms_F77='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
 
       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
         archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
@@ -18464,6 +19164,11 @@ _LT_EOF
       fi
       ;;
 
+    haiku*)
+      archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+      link_all_deplibs_F77=yes
+      ;;
+
     interix[3-9]*)
       hardcode_direct_F77=no
       hardcode_shlibpath_var_F77=no
@@ -18479,7 +19184,7 @@ _LT_EOF
       archive_expsym_cmds_F77='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
       ;;
 
-    gnu* | linux* | tpf* | k*bsd*-gnu)
+    gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
       tmp_diet=no
       if test "$host_os" = linux-dietlibc; then
 	case $cc_basename in
@@ -18489,15 +19194,16 @@ _LT_EOF
       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
 	 && test "$tmp_diet" = no
       then
-	tmp_addflag=
+	tmp_addflag=' $pic_flag'
 	tmp_sharedflag='-shared'
 	case $cc_basename,$host_cpu in
         pgcc*)				# Portland Group C compiler
-	  whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag'
 	  ;;
-	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
-	  whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	pgf77* | pgf90* | pgf95* | pgfortran*)
+					# Portland Group f77 and f90 compilers
+	  whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag -Mnomain' ;;
 	ecc*,ia64* | icc*,ia64*)	# Intel C compiler on ia64
 	  tmp_addflag=' -i_dynamic' ;;
@@ -18508,13 +19214,17 @@ _LT_EOF
 	lf95*)				# Lahey Fortran 8.1
 	  whole_archive_flag_spec_F77=
 	  tmp_sharedflag='--shared' ;;
-	xl[cC]*)			# IBM XL C 8.0 on PPC (deal with xlf below)
+	xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
 	  tmp_sharedflag='-qmkshrobj'
 	  tmp_addflag= ;;
+	nvcc*)	# Cuda Compiler Driver 2.2
+	  whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
+	  compiler_needs_object_F77=yes
+	  ;;
 	esac
 	case `$CC -V 2>&1 | sed 5q` in
 	*Sun\ C*)			# Sun C 5.9
-	  whole_archive_flag_spec_F77='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
+	  whole_archive_flag_spec_F77='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
 	  compiler_needs_object_F77=yes
 	  tmp_sharedflag='-G' ;;
 	*Sun\ F*)			# Sun Fortran 8.3
@@ -18530,17 +19240,17 @@ _LT_EOF
         fi
 
 	case $cc_basename in
-	xlf*)
+	xlf* | bgf* | bgxlf* | mpixlf*)
 	  # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
 	  whole_archive_flag_spec_F77='--whole-archive$convenience --no-whole-archive'
 	  hardcode_libdir_flag_spec_F77=
 	  hardcode_libdir_flag_spec_ld_F77='-rpath $libdir'
-	  archive_cmds_F77='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
+	  archive_cmds_F77='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
 	  if test "x$supports_anon_versioning" = xyes; then
 	    archive_expsym_cmds_F77='echo "{ global:" > $output_objdir/$libname.ver~
 	      cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
 	      echo "local: *; };" >> $output_objdir/$libname.ver~
-	      $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
+	      $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
 	  fi
 	  ;;
 	esac
@@ -18554,8 +19264,8 @@ _LT_EOF
 	archive_cmds_F77='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
 	wlarc=
       else
-	archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       fi
       ;;
 
@@ -18573,8 +19283,8 @@ _LT_EOF
 
 _LT_EOF
       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	ld_shlibs_F77=no
       fi
@@ -18620,8 +19330,8 @@ _LT_EOF
 
     *)
       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
-	archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-	archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+	archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	archive_expsym_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
       else
 	ld_shlibs_F77=no
       fi
@@ -18661,8 +19371,10 @@ _LT_EOF
       else
 	# If we're using GNU nm, then we don't want the "-C" option.
 	# -C means demangle to AIX nm, but means don't demangle with GNU nm
+	# Also, AIX nm treats weak defined symbols like other global
+	# defined symbols, whereas GNU nm marks them as "W".
 	if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
-	  export_symbols_cmds_F77='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
+	  export_symbols_cmds_F77='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	else
 	  export_symbols_cmds_F77='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
 	fi
@@ -18749,32 +19461,45 @@ _LT_EOF
 	allow_undefined_flag_F77='-berok'
         # Determine the default libpath from the value encoded in an
         # empty executable.
-        cat > conftest.$ac_ext <<_ACEOF
+        if test "${lt_cv_aix_libpath+set}" = set; then
+  aix_libpath=$lt_cv_aix_libpath
+else
+  if ${lt_cv_aix_libpath__F77+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat > conftest.$ac_ext <<_ACEOF
       program main
 
       end
 _ACEOF
 if ac_fn_f77_try_link "$LINENO"; then :
 
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
+  lt_aix_libpath_sed='
+      /Import File Strings/,/^$/ {
+	  /^0/ {
+	      s/^0  *\([^ ]*\) *$/\1/
+	      p
+	  }
+      }'
+  lt_cv_aix_libpath__F77=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  # Check for a 64-bit object if we didn't find anything.
+  if test -z "$lt_cv_aix_libpath__F77"; then
+    lt_cv_aix_libpath__F77=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+  if test -z "$lt_cv_aix_libpath__F77"; then
+    lt_cv_aix_libpath__F77="/usr/lib:/lib"
+  fi
+
+fi
+
+  aix_libpath=$lt_cv_aix_libpath__F77
+fi
 
         hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath"
-        archive_expsym_cmds_F77='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+        archive_expsym_cmds_F77='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
       else
 	if test "$host_cpu" = ia64; then
 	  hardcode_libdir_flag_spec_F77='${wl}-R $libdir:/usr/lib:/lib'
@@ -18783,37 +19508,55 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	else
 	 # Determine the default libpath from the value encoded in an
 	 # empty executable.
-	 cat > conftest.$ac_ext <<_ACEOF
+	 if test "${lt_cv_aix_libpath+set}" = set; then
+  aix_libpath=$lt_cv_aix_libpath
+else
+  if ${lt_cv_aix_libpath__F77+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat > conftest.$ac_ext <<_ACEOF
       program main
 
       end
 _ACEOF
 if ac_fn_f77_try_link "$LINENO"; then :
 
-lt_aix_libpath_sed='
-    /Import File Strings/,/^$/ {
-	/^0/ {
-	    s/^0  *\(.*\)$/\1/
-	    p
-	}
-    }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
+  lt_aix_libpath_sed='
+      /Import File Strings/,/^$/ {
+	  /^0/ {
+	      s/^0  *\([^ ]*\) *$/\1/
+	      p
+	  }
+      }'
+  lt_cv_aix_libpath__F77=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  # Check for a 64-bit object if we didn't find anything.
+  if test -z "$lt_cv_aix_libpath__F77"; then
+    lt_cv_aix_libpath__F77=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+  fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+  if test -z "$lt_cv_aix_libpath__F77"; then
+    lt_cv_aix_libpath__F77="/usr/lib:/lib"
+  fi
+
+fi
+
+  aix_libpath=$lt_cv_aix_libpath__F77
+fi
 
 	 hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath"
 	  # Warning - without using the other run time loading flags,
 	  # -berok will link without error, but may produce a broken library.
 	  no_undefined_flag_F77=' ${wl}-bernotok'
 	  allow_undefined_flag_F77=' ${wl}-berok'
-	  # Exported symbols can be pulled into shared objects from archives
-	  whole_archive_flag_spec_F77='$convenience'
+	  if test "$with_gnu_ld" = yes; then
+	    # We only use this code for GNU lds that support --whole-archive.
+	    whole_archive_flag_spec_F77='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
+	  else
+	    # Exported symbols can be pulled into shared objects from archives
+	    whole_archive_flag_spec_F77='$convenience'
+	  fi
 	  archive_cmds_need_lc_F77=yes
 	  # This is similar to how AIX traditionally builds its shared libraries.
 	  archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
@@ -18845,20 +19588,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       # Microsoft Visual C++.
       # hardcode_libdir_flag_spec is actually meaningless, as there is
       # no search path for DLLs.
-      hardcode_libdir_flag_spec_F77=' '
-      allow_undefined_flag_F77=unsupported
-      # Tell ltmain to make .lib files, not .a files.
-      libext=lib
-      # Tell ltmain to make .dll files, not .so files.
-      shrext_cmds=".dll"
-      # FIXME: Setting linknames here is a bad hack.
-      archive_cmds_F77='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
-      # The linker will automatically build a .lib file if we build a DLL.
-      old_archive_from_new_cmds_F77='true'
-      # FIXME: Should let the user specify the lib program.
-      old_archive_cmds_F77='lib -OUT:$oldlib$oldobjs$old_deplibs'
-      fix_srcfile_path_F77='`cygpath -w "$srcfile"`'
-      enable_shared_with_static_runtimes_F77=yes
+      case $cc_basename in
+      cl*)
+	# Native MSVC
+	hardcode_libdir_flag_spec_F77=' '
+	allow_undefined_flag_F77=unsupported
+	always_export_symbols_F77=yes
+	file_list_spec_F77='@'
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	archive_cmds_F77='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
+	archive_expsym_cmds_F77='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
+	    sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
+	  else
+	    sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
+	  fi~
+	  $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
+	  linknames='
+	# The linker will not automatically build a static lib if we build a DLL.
+	# _LT_TAGVAR(old_archive_from_new_cmds, F77)='true'
+	enable_shared_with_static_runtimes_F77=yes
+	export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
+	# Don't use ranlib
+	old_postinstall_cmds_F77='chmod 644 $oldlib'
+	postlink_cmds_F77='lt_outputfile="@OUTPUT@"~
+	  lt_tool_outputfile="@TOOL_OUTPUT@"~
+	  case $lt_outputfile in
+	    *.exe|*.EXE) ;;
+	    *)
+	      lt_outputfile="$lt_outputfile.exe"
+	      lt_tool_outputfile="$lt_tool_outputfile.exe"
+	      ;;
+	  esac~
+	  if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
+	    $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
+	    $RM "$lt_outputfile.manifest";
+	  fi'
+	;;
+      *)
+	# Assume MSVC wrapper
+	hardcode_libdir_flag_spec_F77=' '
+	allow_undefined_flag_F77=unsupported
+	# Tell ltmain to make .lib files, not .a files.
+	libext=lib
+	# Tell ltmain to make .dll files, not .so files.
+	shrext_cmds=".dll"
+	# FIXME: Setting linknames here is a bad hack.
+	archive_cmds_F77='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
+	# The linker will automatically build a .lib file if we build a DLL.
+	old_archive_from_new_cmds_F77='true'
+	# FIXME: Should let the user specify the lib program.
+	old_archive_cmds_F77='lib -OUT:$oldlib$oldobjs$old_deplibs'
+	enable_shared_with_static_runtimes_F77=yes
+	;;
+      esac
       ;;
 
     darwin* | rhapsody*)
@@ -18868,7 +19654,11 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
   hardcode_direct_F77=no
   hardcode_automatic_F77=yes
   hardcode_shlibpath_var_F77=unsupported
-  whole_archive_flag_spec_F77=''
+  if test "$lt_cv_ld_force_load" = "yes"; then
+    whole_archive_flag_spec_F77='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+  else
+    whole_archive_flag_spec_F77=''
+  fi
   link_all_deplibs_F77=yes
   allow_undefined_flag_F77="$_lt_dar_allow_undefined"
   case $cc_basename in
@@ -18876,7 +19666,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
      *) _lt_dar_can_shared=$GCC ;;
   esac
   if test "$_lt_dar_can_shared" = "yes"; then
-    output_verbose_link_cmd=echo
+    output_verbose_link_cmd=func_echo_all
     archive_cmds_F77="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
     module_cmds_F77="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
     archive_expsym_cmds_F77="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
@@ -18919,7 +19709,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
     freebsd* | dragonfly*)
-      archive_cmds_F77='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
+      archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
       hardcode_libdir_flag_spec_F77='-R$libdir'
       hardcode_direct_F77=yes
       hardcode_shlibpath_var_F77=no
@@ -18927,7 +19717,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     hpux9*)
       if test "$GCC" = yes; then
-	archive_cmds_F77='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
+	archive_cmds_F77='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       else
 	archive_cmds_F77='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
       fi
@@ -18942,8 +19732,8 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     hpux10*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
-	archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
+	archive_cmds_F77='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
       else
 	archive_cmds_F77='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
       fi
@@ -18961,16 +19751,16 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     hpux11*)
-      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
+      if test "$GCC" = yes && test "$with_gnu_ld" = no; then
 	case $host_cpu in
 	hppa*64*)
 	  archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	ia64*)
-	  archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  archive_cmds_F77='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+	  archive_cmds_F77='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       else
@@ -18982,7 +19772,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	  archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+	archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       fi
@@ -19010,25 +19800,40 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
     irix5* | irix6* | nonstopux*)
       if test "$GCC" = yes; then
-	archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	# Try to use the -exported_symbol ld option, if it does not
 	# work, assume that -exports_file does not work either and
 	# implicitly export all symbols.
-        save_LDFLAGS="$LDFLAGS"
-        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
-        cat > conftest.$ac_ext <<_ACEOF
-int foo(void) {}
+	# This should be the same for all languages, so no per-tag cache variable.
+	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
+$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
+if ${lt_cv_irix_exported_symbol+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  save_LDFLAGS="$LDFLAGS"
+	   LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
+	   cat > conftest.$ac_ext <<_ACEOF
+
+      subroutine foo
+      end
 _ACEOF
 if ac_fn_f77_try_link "$LINENO"; then :
-  archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
+  lt_cv_irix_exported_symbol=yes
+else
+  lt_cv_irix_exported_symbol=no
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-        LDFLAGS="$save_LDFLAGS"
+           LDFLAGS="$save_LDFLAGS"
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
+$as_echo "$lt_cv_irix_exported_symbol" >&6; }
+	if test "$lt_cv_irix_exported_symbol" = yes; then
+          archive_expsym_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
+	fi
       else
-	archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
-	archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
+	archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
       fi
       archive_cmds_need_lc_F77='no'
       hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir'
@@ -19090,17 +19895,17 @@ rm -f core conftest.err conftest.$ac_objext \
       hardcode_libdir_flag_spec_F77='-L$libdir'
       hardcode_minus_L_F77=yes
       allow_undefined_flag_F77=unsupported
-      archive_cmds_F77='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
+      archive_cmds_F77='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
       old_archive_from_new_cmds_F77='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
       ;;
 
     osf3*)
       if test "$GCC" = yes; then
 	allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*'
-	archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
       else
 	allow_undefined_flag_F77=' -expect_unresolved \*'
-	archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
       fi
       archive_cmds_need_lc_F77='no'
       hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir'
@@ -19110,13 +19915,13 @@ rm -f core conftest.err conftest.$ac_objext \
     osf4* | osf5*)	# as osf3* with the addition of -msym flag
       if test "$GCC" = yes; then
 	allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*'
-	archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+	archive_cmds_F77='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
 	hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir'
       else
 	allow_undefined_flag_F77=' -expect_unresolved \*'
-	archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
+	archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
 	archive_expsym_cmds_F77='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
-	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
+	$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
 
 	# Both c and cxx compiler support -rpath directly
 	hardcode_libdir_flag_spec_F77='-rpath $libdir'
@@ -19129,9 +19934,9 @@ rm -f core conftest.err conftest.$ac_objext \
       no_undefined_flag_F77=' -z defs'
       if test "$GCC" = yes; then
 	wlarc='${wl}'
-	archive_cmds_F77='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_cmds_F77='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	archive_expsym_cmds_F77='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
-	  $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
+	  $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
       else
 	case `$CC -V 2>&1` in
 	*"Compilers 5.0"*)
@@ -19310,44 +20115,50 @@ x|xyes)
       # to ld, don't add -lc before -lgcc.
       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-      $RM conftest*
-      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
+if ${lt_cv_archive_cmds_need_lc_F77+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  $RM conftest*
+	echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
-      if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+	if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; } 2>conftest.err; then
-        soname=conftest
-        lib=conftest
-        libobjs=conftest.$ac_objext
-        deplibs=
-        wl=$lt_prog_compiler_wl_F77
-	pic_flag=$lt_prog_compiler_pic_F77
-        compiler_flags=-v
-        linker_flags=-v
-        verstring=
-        output_objdir=.
-        libname=conftest
-        lt_save_allow_undefined_flag=$allow_undefined_flag_F77
-        allow_undefined_flag_F77=
-        if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_F77 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
+	  soname=conftest
+	  lib=conftest
+	  libobjs=conftest.$ac_objext
+	  deplibs=
+	  wl=$lt_prog_compiler_wl_F77
+	  pic_flag=$lt_prog_compiler_pic_F77
+	  compiler_flags=-v
+	  linker_flags=-v
+	  verstring=
+	  output_objdir=.
+	  libname=conftest
+	  lt_save_allow_undefined_flag=$allow_undefined_flag_F77
+	  allow_undefined_flag_F77=
+	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_F77 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
   (eval $archive_cmds_F77 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; }
-        then
-	  archive_cmds_need_lc_F77=no
-        else
-	  archive_cmds_need_lc_F77=yes
-        fi
-        allow_undefined_flag_F77=$lt_save_allow_undefined_flag
-      else
-        cat conftest.err 1>&5
-      fi
-      $RM conftest*
-      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc_F77" >&5
-$as_echo "$archive_cmds_need_lc_F77" >&6; }
+	  then
+	    lt_cv_archive_cmds_need_lc_F77=no
+	  else
+	    lt_cv_archive_cmds_need_lc_F77=yes
+	  fi
+	  allow_undefined_flag_F77=$lt_save_allow_undefined_flag
+	else
+	  cat conftest.err 1>&5
+	fi
+	$RM conftest*
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_F77" >&5
+$as_echo "$lt_cv_archive_cmds_need_lc_F77" >&6; }
+      archive_cmds_need_lc_F77=$lt_cv_archive_cmds_need_lc_F77
       ;;
     esac
   fi
@@ -19504,7 +20315,7 @@ amigaos*)
   m68k)
     library_names_spec='$libname.ixlibrary $libname.a'
     # Create ${libname}_ixlibrary.a entries in /sys/libs.
-    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
+    finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
     ;;
   esac
   ;;
@@ -19535,8 +20346,9 @@ cygwin* | mingw* | pw32* | cegcc*)
   need_version=no
   need_lib_prefix=no
 
-  case $GCC,$host_os in
-  yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
+  case $GCC,$cc_basename in
+  yes,*)
+    # gcc
     library_names_spec='$libname.dll.a'
     # DLL is installed to $(libdir)/../bin by postinstall_cmds
     postinstall_cmds='base_file=`basename \${file}`~
@@ -19557,36 +20369,82 @@ cygwin* | mingw* | pw32* | cegcc*)
     cygwin*)
       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+
       ;;
     mingw* | cegcc*)
       # MinGW DLLs use traditional 'lib' prefix
       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-      sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
-        # It is most probably a Windows format PATH printed by
-        # mingw gcc, but we are running on Cygwin. Gcc prints its search
-        # path with ; separators, and with drive letters. We can handle the
-        # drive letters (cygwin fileutils understands them), so leave them,
-        # especially as we might pass files found there to a mingw objdump,
-        # which wouldn't understand a cygwinified path. Ahh.
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
-      else
-        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-      fi
       ;;
     pw32*)
       # pw32 DLLs use 'pw' prefix rather than 'lib'
       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
       ;;
     esac
+    dynamic_linker='Win32 ld.exe'
+    ;;
+
+  *,cl*)
+    # Native MSVC
+    libname_spec='$name'
+    soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+    library_names_spec='${libname}.dll.lib'
+
+    case $build_os in
+    mingw*)
+      sys_lib_search_path_spec=
+      lt_save_ifs=$IFS
+      IFS=';'
+      for lt_path in $LIB
+      do
+        IFS=$lt_save_ifs
+        # Let DOS variable expansion print the short 8.3 style file name.
+        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
+        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
+      done
+      IFS=$lt_save_ifs
+      # Convert to MSYS style.
+      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
+      ;;
+    cygwin*)
+      # Convert to unix form, then to dos form, then back to unix form
+      # but this time dos style (no spaces!) so that the unix form looks
+      # like /cygdrive/c/PROGRA~1:/cygdr...
+      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
+      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
+      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      ;;
+    *)
+      sys_lib_search_path_spec="$LIB"
+      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
+        # It is most probably a Windows format PATH.
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
+      else
+        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
+      fi
+      # FIXME: find the short name or the path components, as spaces are
+      # common. (e.g. "Program Files" -> "PROGRA~1")
+      ;;
+    esac
+
+    # DLL is installed to $(libdir)/../bin by postinstall_cmds
+    postinstall_cmds='base_file=`basename \${file}`~
+      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
+      dldir=$destdir/`dirname \$dlpath`~
+      test -d \$dldir || mkdir -p \$dldir~
+      $install_prog $dir/$dlname \$dldir/$dlname'
+    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
+      dlpath=$dir/\$dldll~
+       $RM \$dlpath'
+    shlibpath_overrides_runpath=yes
+    dynamic_linker='Win32 link.exe'
     ;;
 
   *)
+    # Assume MSVC wrapper
     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
+    dynamic_linker='Win32 ld.exe'
     ;;
   esac
-  dynamic_linker='Win32 ld.exe'
   # FIXME: first we should search . and the directory the executable is in
   shlibpath_var=PATH
   ;;
@@ -19668,7 +20526,20 @@ gnu*)
   need_version=no
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
   soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
+  shlibpath_var=LD_LIBRARY_PATH
+  hardcode_into_libs=yes
+  ;;
+
+haiku*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  dynamic_linker="$host_os runtime_loader"
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LIBRARY_PATH
+  shlibpath_overrides_runpath=yes
+  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
   hardcode_into_libs=yes
   ;;
 
@@ -19714,8 +20585,10 @@ hpux9* | hpux10* | hpux11*)
     soname_spec='${libname}${release}${shared_ext}$major'
     ;;
   esac
-  # HP-UX runs *really* slowly unless shared libraries are mode 555.
+  # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
   postinstall_cmds='chmod 555 $lib'
+  # or fails outright, so override atomically:
+  install_override_mode=555
   ;;
 
 interix[3-9]*)
@@ -19773,7 +20646,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux* | k*bsd*-gnu)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -19782,25 +20655,34 @@ linux* | k*bsd*-gnu)
   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
   shlibpath_var=LD_LIBRARY_PATH
   shlibpath_overrides_runpath=no
+
   # Some binutils ld are patched to set DT_RUNPATH
-  save_LDFLAGS=$LDFLAGS
-  save_libdir=$libdir
-  eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_F77\"; \
-       LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_F77\""
-  cat > conftest.$ac_ext <<_ACEOF
+  if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  lt_cv_shlibpath_overrides_runpath=no
+    save_LDFLAGS=$LDFLAGS
+    save_libdir=$libdir
+    eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_F77\"; \
+	 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_F77\""
+    cat > conftest.$ac_ext <<_ACEOF
       program main
 
       end
 _ACEOF
 if ac_fn_f77_try_link "$LINENO"; then :
   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
-  shlibpath_overrides_runpath=yes
+  lt_cv_shlibpath_overrides_runpath=yes
 fi
 fi
 rm -f core conftest.err conftest.$ac_objext \
     conftest$ac_exeext conftest.$ac_ext
-  LDFLAGS=$save_LDFLAGS
-  libdir=$save_libdir
+    LDFLAGS=$save_LDFLAGS
+    libdir=$save_libdir
+
+fi
+
+  shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
 
   # This implies no fast_install, which is unacceptable.
   # Some rework will be needed to allow for fast_install
@@ -19809,7 +20691,7 @@ rm -f core conftest.err conftest.$ac_objext \
 
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[	 ]*hwcap[	 ]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
@@ -20061,6 +20943,8 @@ fi
 
 
 
+
+
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
 hardcode_action_F77=
@@ -20109,6 +20993,7 @@ fi
 
   GCC=$lt_save_GCC
   CC="$lt_save_CC"
+  CFLAGS="$lt_save_CFLAGS"
 fi # test "$_lt_disable_F77" != yes
 
 ac_ext=c
@@ -20191,7 +21076,7 @@ ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_f77_compiler_gnu
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get verbose linking output from $F77" >&5
 $as_echo_n "checking how to get verbose linking output from $F77... " >&6; }
-if test "${ac_cv_prog_f77_v+set}" = set; then :
+if ${ac_cv_prog_f77_v+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat > conftest.$ac_ext <<_ACEOF
@@ -20221,7 +21106,8 @@ $as_echo "$as_me:${as_lineno-$LINENO}: $*" >&5
 # gfortran 4.3 outputs lines setting COLLECT_GCC_OPTIONS, COMPILER_PATH,
 # LIBRARY_PATH; skip all such settings.
 ac_f77_v_output=`eval $ac_link 5>&1 2>&1 |
-  grep -v 'Driving:' | grep -v "^[_$as_cr_Letters][_$as_cr_alnum]*="`
+  sed '/^Driving:/d; /^Configured with:/d;
+      '"/^[_$as_cr_Letters][_$as_cr_alnum]*=/d"`
 $as_echo "$ac_f77_v_output" >&5
 FFLAGS=$ac_save_FFLAGS
 
@@ -20286,7 +21172,7 @@ fi
 $as_echo "$ac_cv_prog_f77_v" >&6; }
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Fortran 77 libraries of $F77" >&5
 $as_echo_n "checking for Fortran 77 libraries of $F77... " >&6; }
-if test "${ac_cv_f77_libs+set}" = set; then :
+if ${ac_cv_f77_libs+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test "x$FLIBS" != "x"; then
@@ -20311,7 +21197,8 @@ $as_echo "$as_me:${as_lineno-$LINENO}: $*" >&5
 # gfortran 4.3 outputs lines setting COLLECT_GCC_OPTIONS, COMPILER_PATH,
 # LIBRARY_PATH; skip all such settings.
 ac_f77_v_output=`eval $ac_link 5>&1 2>&1 |
-  grep -v 'Driving:' | grep -v "^[_$as_cr_Letters][_$as_cr_alnum]*="`
+  sed '/^Driving:/d; /^Configured with:/d;
+      '"/^[_$as_cr_Letters][_$as_cr_alnum]*=/d"`
 $as_echo "$ac_f77_v_output" >&5
 FFLAGS=$ac_save_FFLAGS
 
@@ -20401,7 +21288,7 @@ fi
 	  ;;
 	  # Ignore these flags.
 	-lang* | -lcrt*.o | -lc | -lgcc* | -lSystem | -libmil | -little \
-	  |-LANG:=* | -LIST:* | -LNO:*)
+	  |-LANG:=* | -LIST:* | -LNO:* | -link)
 	  ;;
 	-lkernel32)
 	  test x"$CYGWIN" != xyes && ac_cv_f77_libs="$ac_cv_f77_libs $ac_arg"
@@ -20527,11 +21414,11 @@ if test "${with_prepro+set}" = set; then :
 fi
 
 
-# Extract the first word of "cs_preprocess", so it can be a program name with args.
-set dummy cs_preprocess; ac_word=$2
+# Extract the first word of "cs_preprocess$EXEEXT", so it can be a program name with args.
+set dummy cs_preprocess$EXEEXT; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_ecs+set}" = set; then :
+if ${ac_cv_path_ecs+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $ecs in
@@ -20572,8 +21459,8 @@ fi
 if test "x${ecs}" = "xno"; then
   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot find Code_Saturne preprocessor
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot find Code_Saturne preprocessor
+See \`config.log' for more details" "$LINENO" 5; }
 else
   ecs_bindir=`dirname ${ecs}`
 
@@ -20589,7 +21476,7 @@ if test "${enable_gui+set}" = set; then :
     case "${enableval}" in
       yes) have_gui=yes ;;
       no)  have_gui=no ;;
-      *)   as_fn_error "bad value ${enableval} for --enable-gui" "$LINENO" 5 ;;
+      *)   as_fn_error $? "bad value ${enableval} for --enable-gui" "$LINENO" 5 ;;
     esac
 
 else
@@ -20616,7 +21503,7 @@ if test "x${PYTHON_EXE}" == "xnone" ; then
 set dummy python; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_PYEXE+set}" = set; then :
+if ${ac_cv_path_PYEXE+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $PYEXE in
@@ -20659,7 +21546,7 @@ else
 set dummy python; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_PYEXE+set}" = set; then :
+if ${ac_cv_path_PYEXE+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $PYEXE in
@@ -20700,19 +21587,24 @@ fi
 
 
 PYTHON=${PYEXE}
+if test "x$have_gui" = xyes; then
+  cs_python_version="2.4"
+else
+  cs_python_version="2.3"
+fi
 
 
 
 
         if test -n "$PYTHON"; then
       # If the user set $PYTHON, use it and don't search something else.
-      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version >= 2.3" >&5
-$as_echo_n "checking whether $PYTHON version >= 2.3... " >&6; }
+      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version >= $cs_python_version" >&5
+$as_echo_n "checking whether $PYTHON version >= $cs_python_version... " >&6; }
       prog="import sys
 # split strings by '.' and convert to numeric.  Append some zeros
 # because we need at least 4 digits for the hex conversion.
 # map returns an iterator in Python 3.0 and a list in 2.x
-minver = list(map(int, '2.3'.split('.'))) + [0, 0, 0]
+minver = list(map(int, '$cs_python_version'.split('.'))) + [0, 0, 0]
 minverhex = 0
 # xrange is not present in Python 3.0 and range returns an iterator
 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
@@ -20725,15 +21617,15 @@ sys.exit(sys.hexversion < minverhex)"
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
 $as_echo "yes" >&6; }
 else
-  as_fn_error "too old" "$LINENO" 5
+  as_fn_error $? "too old" "$LINENO" 5
 fi
       am_display_PYTHON=$PYTHON
     else
       # Otherwise, try each interpreter until we find one that satisfies
       # VERSION.
-      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 2.3" >&5
-$as_echo_n "checking for a Python interpreter with version >= 2.3... " >&6; }
-if test "${am_cv_pathless_PYTHON+set}" = set; then :
+      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= $cs_python_version" >&5
+$as_echo_n "checking for a Python interpreter with version >= $cs_python_version... " >&6; }
+if ${am_cv_pathless_PYTHON+:} false; then :
   $as_echo_n "(cached) " >&6
 else
 
@@ -20743,7 +21635,7 @@ else
 # split strings by '.' and convert to numeric.  Append some zeros
 # because we need at least 4 digits for the hex conversion.
 # map returns an iterator in Python 3.0 and a list in 2.x
-minver = list(map(int, '2.3'.split('.'))) + [0, 0, 0]
+minver = list(map(int, '$cs_python_version'.split('.'))) + [0, 0, 0]
 minverhex = 0
 # xrange is not present in Python 3.0 and range returns an iterator
 for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
@@ -20767,7 +21659,7 @@ $as_echo "$am_cv_pathless_PYTHON" >&6; }
 set dummy $am_cv_pathless_PYTHON; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_PYTHON+set}" = set; then :
+if ${ac_cv_path_PYTHON+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $PYTHON in
@@ -20809,13 +21701,13 @@ fi
 
 
   if test "$PYTHON" = :; then
-      as_fn_error "no suitable Python interpreter found" "$LINENO" 5
+      as_fn_error $? "no suitable Python interpreter found" "$LINENO" 5
   else
 
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5
 $as_echo_n "checking for $am_display_PYTHON version... " >&6; }
-if test "${am_cv_python_version+set}" = set; then :
+if ${am_cv_python_version+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`
@@ -20834,7 +21726,7 @@ $as_echo "$am_cv_python_version" >&6; }
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5
 $as_echo_n "checking for $am_display_PYTHON platform... " >&6; }
-if test "${am_cv_python_platform+set}" = set; then :
+if ${am_cv_python_platform+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`
@@ -20848,7 +21740,7 @@ $as_echo "$am_cv_python_platform" >&6; }
 
                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory" >&5
 $as_echo_n "checking for $am_display_PYTHON script directory... " >&6; }
-if test "${am_cv_python_pythondir+set}" = set; then :
+if ${am_cv_python_pythondir+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test "x$prefix" = xNONE
@@ -20886,7 +21778,7 @@ $as_echo "$am_cv_python_pythondir" >&6; }
 
             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory" >&5
 $as_echo_n "checking for $am_display_PYTHON extension module directory... " >&6; }
-if test "${am_cv_python_pyexecdir+set}" = set; then :
+if ${am_cv_python_pyexecdir+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test "x$exec_prefix" = xNONE
@@ -20961,8 +21853,8 @@ sys.exit(0)"
 $as_echo "no" >&6; }
     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot find PyQt4 support (>= 4.3), Graphical User Interface cannot be installed
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot find PyQt4 support (>= 4.3), Graphical User Interface cannot be installed
+See \`config.log' for more details" "$LINENO" 5; }
     have_gui=no
   else
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
@@ -20993,7 +21885,7 @@ sys.stdout.write(path)"
 set dummy pyuic4; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_PYUIC4+set}" = set; then :
+if ${ac_cv_path_PYUIC4+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $PYUIC4 in
@@ -21002,7 +21894,8 @@ else
   ;;
   *)
   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in ${PYPATH}
+as_dummy="${PYPATH}:$PATH"
+for as_dir in $as_dummy
 do
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
@@ -21034,7 +21927,7 @@ fi
 set dummy pyrcc4; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_PYRCC4+set}" = set; then :
+if ${ac_cv_path_PYRCC4+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $PYRCC4 in
@@ -21043,7 +21936,8 @@ else
   ;;
   *)
   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in ${PYPATH}
+as_dummy="${PYPATH}:$PATH"
+for as_dir in $as_dummy
 do
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
@@ -21075,8 +21969,8 @@ fi
   if test "x$PYUIC4" == "xno" -o "x$PYRCC4" == "xno" ; then
     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot find PyQt4 dev tools, Graphical User Interface cannot be installed
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot find PyQt4 dev tools, Graphical User Interface cannot be installed
+See \`config.log' for more details" "$LINENO" 5; }
     have_gui=no
   fi
 
@@ -21097,7 +21991,7 @@ fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
 $as_echo_n "checking for ANSI C header files... " >&6; }
-if test "${ac_cv_header_stdc+set}" = set; then :
+if ${ac_cv_header_stdc+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -21211,8 +22105,7 @@ for ac_header in sys/types.h sys/utsname.h sys/stat.h stddef.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-eval as_val=\$$as_ac_Header
-   if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
   cat >>confdefs.h <<_ACEOF
 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
 _ACEOF
@@ -21221,6 +22114,18 @@ fi
 
 done
 
+for ac_header in sys/resource.h
+do :
+  ac_fn_c_check_header_mongrel "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" "$ac_includes_default"
+if test "x$ac_cv_header_sys_resource_h" = xyes; then :
+  cat >>confdefs.h <<_ACEOF
+#define HAVE_SYS_RESOURCE_H 1
+_ACEOF
+
+fi
+
+done
+
 
 #------------------------------------------------------------------------------
 # Checks for library functions.
@@ -21229,7 +22134,7 @@ done
 for ac_func in snprintf
 do :
   ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
-if test "x$ac_cv_func_snprintf" = x""yes; then :
+if test "x$ac_cv_func_snprintf" = xyes; then :
   cat >>confdefs.h <<_ACEOF
 #define HAVE_SNPRINTF 1
 _ACEOF
@@ -21241,8 +22146,7 @@ for ac_func in getcwd sleep
 do :
   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-eval as_val=\$$as_ac_var
-   if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
   cat >>confdefs.h <<_ACEOF
 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
 _ACEOF
@@ -21254,8 +22158,7 @@ for ac_func in getpwuid geteuid
 do :
   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-eval as_val=\$$as_ac_var
-   if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
   cat >>confdefs.h <<_ACEOF
 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
 _ACEOF
@@ -21266,7 +22169,7 @@ done
 for ac_func in uname
 do :
   ac_fn_c_check_func "$LINENO" "uname" "ac_cv_func_uname"
-if test "x$ac_cv_func_uname" = x""yes; then :
+if test "x$ac_cv_func_uname" = xyes; then :
   cat >>confdefs.h <<_ACEOF
 #define HAVE_UNAME 1
 _ACEOF
@@ -21290,7 +22193,7 @@ if test "${enable_sockets+set}" = set; then :
     case "${enableval}" in
       yes) have_socket=yes ;;
       no)  have_socket=no ;;
-      *)   as_fn_error "bad value ${enableval} for --enable-sockets" "$LINENO" 5 ;;
+      *)   as_fn_error $? "bad value ${enableval} for --enable-sockets" "$LINENO" 5 ;;
     esac
 
 else
@@ -21315,7 +22218,7 @@ if test "${enable_dlloader+set}" = set; then :
     case "${enableval}" in
       yes) have_dlloader=yes ;;
       no)  have_dlloader=no ;;
-      *)   as_fn_error "bad value ${enableval} for --enable-dlloader" "$LINENO" 5 ;;
+      *)   as_fn_error $? "bad value ${enableval} for --enable-dlloader" "$LINENO" 5 ;;
     esac
 
 else
@@ -21395,7 +22298,7 @@ $as_echo "$USE_NLS" >&6; }
 
 
 
-      GETTEXT_MACRO_VERSION=0.17
+      GETTEXT_MACRO_VERSION=0.18
 
 
 
@@ -21432,7 +22335,7 @@ rm -f conf$$.file
 set dummy msgfmt; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_MSGFMT+set}" = set; then :
+if ${ac_cv_path_MSGFMT+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case "$MSGFMT" in
@@ -21473,7 +22376,7 @@ fi
 set dummy gmsgfmt; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_GMSGFMT+set}" = set; then :
+if ${ac_cv_path_GMSGFMT+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case $GMSGFMT in
@@ -21555,7 +22458,7 @@ rm -f conf$$.file
 set dummy xgettext; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_XGETTEXT+set}" = set; then :
+if ${ac_cv_path_XGETTEXT+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case "$XGETTEXT" in
@@ -21633,7 +22536,7 @@ rm -f conf$$.file
 set dummy msgmerge; ac_word=$2
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 $as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_MSGMERGE+set}" = set; then :
+if ${ac_cv_path_MSGMERGE+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   case "$MSGMERGE" in
@@ -21735,7 +22638,7 @@ $as_echo_n "checking for ld used by GCC... " >&6; }
       # Canonicalize the path of ld
       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
-	ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
+        ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
       done
       test -z "$LD" && LD="$ac_prog"
       ;;
@@ -21755,7 +22658,7 @@ else
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
 $as_echo_n "checking for non-GNU ld... " >&6; }
 fi
-if test "${acl_cv_path_LD+set}" = set; then :
+if ${acl_cv_path_LD+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   if test -z "$LD"; then
@@ -21769,9 +22672,9 @@ else
       # Break only if it was the GNU/non-GNU ld that we prefer.
       case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in
       *GNU* | *'with BFD'*)
-	test "$with_gnu_ld" != no && break ;;
+        test "$with_gnu_ld" != no && break ;;
       *)
-	test "$with_gnu_ld" != yes && break ;;
+        test "$with_gnu_ld" != yes && break ;;
       esac
     fi
   done
@@ -21789,10 +22692,10 @@ else
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 fi
-test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5
+test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if test "${acl_cv_prog_gnu_ld+set}" = set; then :
+if ${acl_cv_prog_gnu_ld+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
@@ -21812,7 +22715,7 @@ with_gnu_ld=$acl_cv_prog_gnu_ld
 
                                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
 $as_echo_n "checking for shared library run path origin... " >&6; }
-if test "${acl_cv_rpath+set}" = set; then :
+if ${acl_cv_rpath+:} false; then :
   $as_echo_n "(cached) " >&6
 else
 
@@ -21843,23 +22746,70 @@ fi
 
 
 
-                  acl_libdirstem=lib
-  searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
-  if test -n "$searchpath"; then
-    acl_save_IFS="${IFS= 	}"; IFS=":"
-    for searchdir in $searchpath; do
-      if test -d "$searchdir"; then
-        case "$searchdir" in
-          */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
-          *) searchdir=`cd "$searchdir" && pwd`
-             case "$searchdir" in
-               */lib64 ) acl_libdirstem=lib64 ;;
-             esac ;;
+
+  acl_libdirstem=lib
+  acl_libdirstem2=
+  case "$host_os" in
+    solaris*)
+                                    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit host" >&5
+$as_echo_n "checking for 64-bit host... " >&6; }
+if ${gl_cv_solaris_64bit+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+#ifdef _LP64
+sixtyfour bits
+#endif
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "sixtyfour bits" >/dev/null 2>&1; then :
+  gl_cv_solaris_64bit=yes
+else
+  gl_cv_solaris_64bit=no
+fi
+rm -f conftest*
+
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_solaris_64bit" >&5
+$as_echo "$gl_cv_solaris_64bit" >&6; }
+      if test $gl_cv_solaris_64bit = yes; then
+        acl_libdirstem=lib/64
+        case "$host_cpu" in
+          sparc*)        acl_libdirstem2=lib/sparcv9 ;;
+          i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
         esac
       fi
-    done
-    IFS="$acl_save_IFS"
-  fi
+      ;;
+    *)
+      searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
+      if test -n "$searchpath"; then
+        acl_save_IFS="${IFS= 	}"; IFS=":"
+        for searchdir in $searchpath; do
+          if test -d "$searchdir"; then
+            case "$searchdir" in
+              */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
+              */../ | */.. )
+                # Better ignore directories of this form. They are misleading.
+                ;;
+              *) searchdir=`cd "$searchdir" && pwd`
+                 case "$searchdir" in
+                   */lib64 ) acl_libdirstem=lib64 ;;
+                 esac ;;
+            esac
+          fi
+        done
+        IFS="$acl_save_IFS"
+      fi
+      ;;
+  esac
+  test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
+
+
+
 
 
 
@@ -21905,6 +22855,10 @@ if test "${with_libiconv_prefix+set}" = set; then :
       else
         additional_includedir="$withval/include"
         additional_libdir="$withval/$acl_libdirstem"
+        if test "$acl_libdirstem2" != "$acl_libdirstem" \
+           && ! test -d "$withval/$acl_libdirstem"; then
+          additional_libdir="$withval/$acl_libdirstem2"
+        fi
       fi
     fi
 
@@ -21914,6 +22868,7 @@ fi
   LTLIBICONV=
   INCICONV=
   LIBICONV_PREFIX=
+      HAVE_LIBICONV=
   rpathdirs=
   ltrpathdirs=
   names_already_handled=
@@ -22056,7 +23011,9 @@ fi
           if test "X$found_dir" != "X"; then
                         LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
             if test "X$found_so" != "X"; then
-                                                        if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then
+                                                        if test "$enable_rpath" = no \
+                 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
+                 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
                                 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
               else
                                                                                 haveit=
@@ -22123,7 +23080,16 @@ fi
             case "$found_dir" in
               */$acl_libdirstem | */$acl_libdirstem/)
                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
-                LIBICONV_PREFIX="$basedir"
+                if test "$name" = 'iconv'; then
+                  LIBICONV_PREFIX="$basedir"
+                fi
+                additional_includedir="$basedir/include"
+                ;;
+              */$acl_libdirstem2 | */$acl_libdirstem2/)
+                basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
+                if test "$name" = 'iconv'; then
+                  LIBICONV_PREFIX="$basedir"
+                fi
                 additional_includedir="$basedir/include"
                 ;;
             esac
@@ -22172,9 +23138,11 @@ fi
                 case "$dep" in
                   -L*)
                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
-                                                                                                                                                                if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
+                                                                                                                                                                if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
+                       && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
                       haveit=
-                      if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
+                      if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
+                         || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
                         if test -n "$GCC"; then
                           case $host_os in
                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
@@ -22324,9 +23292,15 @@ fi
 
 
 
+
+
+
+
+
+
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if test "${gt_cv_func_CFPreferencesCopyAppValue+set}" = set; then :
+if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   gt_save_LIBS="$LIBS"
@@ -22360,7 +23334,7 @@ $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
   fi
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5
 $as_echo_n "checking for CFLocaleCopyCurrent... " >&6; }
-if test "${gt_cv_func_CFLocaleCopyCurrent+set}" = set; then :
+if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   gt_save_LIBS="$LIBS"
@@ -22436,7 +23410,7 @@ typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
 
         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
 $as_echo_n "checking for GNU gettext in libc... " >&6; }
-if { as_var=$gt_func_gnugettext_libc; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${$gt_func_gnugettext_libc+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -22499,7 +23473,7 @@ $as_echo "$ac_res" >&6; }
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
 $as_echo_n "checking for iconv... " >&6; }
-if test "${am_cv_func_iconv+set}" = set; then :
+if ${am_cv_func_iconv+:} false; then :
   $as_echo_n "(cached) " >&6
 else
 
@@ -22556,7 +23530,7 @@ $as_echo "$am_cv_func_iconv" >&6; }
   if test "$am_cv_func_iconv" = yes; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
 $as_echo_n "checking for working iconv... " >&6; }
-if test "${am_cv_func_iconv_works+set}" = set; then :
+if ${am_cv_func_iconv_works+:} false; then :
   $as_echo_n "(cached) " >&6
 else
 
@@ -22596,6 +23570,25 @@ int main ()
           return 1;
       }
   }
+  /* Test against Solaris 10 bug: Failures are not distinguishable from
+     successful returns.  */
+  {
+    iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
+    if (cd_ascii_to_88591 != (iconv_t)(-1))
+      {
+        static const char input[] = "\263";
+        char buf[10];
+        const char *inptr = input;
+        size_t inbytesleft = strlen (input);
+        char *outptr = buf;
+        size_t outbytesleft = sizeof (buf);
+        size_t res = iconv (cd_ascii_to_88591,
+                            (char **) &inptr, &inbytesleft,
+                            &outptr, &outbytesleft);
+        if (res == 0)
+          return 1;
+      }
+  }
 #if 0 /* This bug could be worked around by the caller.  */
   /* Test against HP-UX 11.11 bug: Positive return value instead of 0.  */
   {
@@ -22674,6 +23667,9 @@ $as_echo "$LIBICONV" >&6; }
 
 
 
+
+
+
     use_additional=yes
 
   acl_save_prefix="$prefix"
@@ -22710,6 +23706,10 @@ if test "${with_libintl_prefix+set}" = set; then :
       else
         additional_includedir="$withval/include"
         additional_libdir="$withval/$acl_libdirstem"
+        if test "$acl_libdirstem2" != "$acl_libdirstem" \
+           && ! test -d "$withval/$acl_libdirstem"; then
+          additional_libdir="$withval/$acl_libdirstem2"
+        fi
       fi
     fi
 
@@ -22719,6 +23719,7 @@ fi
   LTLIBINTL=
   INCINTL=
   LIBINTL_PREFIX=
+      HAVE_LIBINTL=
   rpathdirs=
   ltrpathdirs=
   names_already_handled=
@@ -22861,7 +23862,9 @@ fi
           if test "X$found_dir" != "X"; then
                         LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
             if test "X$found_so" != "X"; then
-                                                        if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then
+                                                        if test "$enable_rpath" = no \
+                 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
+                 || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
                                 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
               else
                                                                                 haveit=
@@ -22928,7 +23931,16 @@ fi
             case "$found_dir" in
               */$acl_libdirstem | */$acl_libdirstem/)
                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
-                LIBINTL_PREFIX="$basedir"
+                if test "$name" = 'intl'; then
+                  LIBINTL_PREFIX="$basedir"
+                fi
+                additional_includedir="$basedir/include"
+                ;;
+              */$acl_libdirstem2 | */$acl_libdirstem2/)
+                basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
+                if test "$name" = 'intl'; then
+                  LIBINTL_PREFIX="$basedir"
+                fi
                 additional_includedir="$basedir/include"
                 ;;
             esac
@@ -22977,9 +23989,11 @@ fi
                 case "$dep" in
                   -L*)
                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
-                                                                                                                                                                if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
+                                                                                                                                                                if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
+                       && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
                       haveit=
-                      if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
+                      if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
+                         || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
                         if test -n "$GCC"; then
                           case $host_os in
                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
@@ -23105,9 +24119,14 @@ fi
     done
   fi
 
+
+
+
+
+
           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
 $as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if { as_var=$gt_func_gnugettext_libintl; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval \${$gt_func_gnugettext_libintl+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   gt_save_CPPFLAGS="$CPPFLAGS"
@@ -23465,10 +24484,21 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
      :end' >>confcache
 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
   if test -w "$cache_file"; then
-    test "x$cache_file" != "x/dev/null" &&
+    if test "x$cache_file" != "x/dev/null"; then
       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
 $as_echo "$as_me: updating cache $cache_file" >&6;}
-    cat confcache >$cache_file
+      if test ! -f "$cache_file" || test -h "$cache_file"; then
+	cat confcache >"$cache_file"
+      else
+        case $cache_file in #(
+        */* | ?:*)
+	  mv -f confcache "$cache_file"$$ &&
+	  mv -f "$cache_file"$$ "$cache_file" ;; #(
+        *)
+	  mv -f confcache "$cache_file" ;;
+	esac
+      fi
+    fi
   else
     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
@@ -23484,6 +24514,7 @@ DEFS=-DHAVE_CONFIG_H
 
 ac_libobjs=
 ac_ltlibobjs=
+U=
 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
   # 1. Remove the extension, and $U if already installed.
   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
@@ -23507,35 +24538,35 @@ else
 fi
 
 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
-  as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
+  as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
-  as_fn_error "conditional \"AMDEP\" was never defined.
+  as_fn_error $? "conditional \"AMDEP\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
-  as_fn_error "conditional \"am__fastdepCC\" was never defined.
+  as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 if test -z "${HAVE_MEI_TRUE}" && test -z "${HAVE_MEI_FALSE}"; then
-  as_fn_error "conditional \"HAVE_MEI\" was never defined.
+  as_fn_error $? "conditional \"HAVE_MEI\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 if test -z "${HAVE_LIBXML2_TRUE}" && test -z "${HAVE_LIBXML2_FALSE}"; then
-  as_fn_error "conditional \"HAVE_LIBXML2\" was never defined.
+  as_fn_error $? "conditional \"HAVE_LIBXML2\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 if test -z "${HAVE_MPI_TRUE}" && test -z "${HAVE_MPI_FALSE}"; then
-  as_fn_error "conditional \"HAVE_MPI\" was never defined.
+  as_fn_error $? "conditional \"HAVE_MPI\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 if test -z "${HAVE_GUI_TRUE}" && test -z "${HAVE_GUI_FALSE}"; then
-  as_fn_error "conditional \"HAVE_GUI\" was never defined.
+  as_fn_error $? "conditional \"HAVE_GUI\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 
-: ${CONFIG_STATUS=./config.status}
+: "${CONFIG_STATUS=./config.status}"
 ac_write_fail=0
 ac_clean_files_save=$ac_clean_files
 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
@@ -23636,6 +24667,7 @@ fi
 IFS=" ""	$as_nl"
 
 # Find who we are.  Look in the path if we contain no directory separator.
+as_myself=
 case $0 in #((
   *[\\/]* ) as_myself=$0 ;;
   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -23681,19 +24713,19 @@ export LANGUAGE
 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
 
 
-# as_fn_error ERROR [LINENO LOG_FD]
-# ---------------------------------
+# as_fn_error STATUS ERROR [LINENO LOG_FD]
+# ----------------------------------------
 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with status $?, using 1 if that was 0.
+# script with STATUS, using 1 if that was 0.
 as_fn_error ()
 {
-  as_status=$?; test $as_status -eq 0 && as_status=1
-  if test "$3"; then
-    as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-    $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
+  as_status=$1; test $as_status -eq 0 && as_status=1
+  if test "$4"; then
+    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
   fi
-  $as_echo "$as_me: error: $1" >&2
+  $as_echo "$as_me: error: $2" >&2
   as_fn_exit $as_status
 } # as_fn_error
 
@@ -23889,7 +24921,7 @@ $as_echo X"$as_dir" |
       test -d "$as_dir" && break
     done
     test -z "$as_dirs" || eval "mkdir $as_dirs"
-  } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
+  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
 
 
 } # as_fn_mkdir_p
@@ -23942,8 +24974,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by ncs $as_me 2.0.0-rc1, which was
-generated by GNU Autoconf 2.65.  Invocation command line was
+This file was extended by ncs $as_me 2.0.1, which was
+generated by GNU Autoconf 2.68.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
   CONFIG_HEADERS  = $CONFIG_HEADERS
@@ -24008,11 +25040,11 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-ncs config.status 2.0.0-rc1
-configured by $0, generated by GNU Autoconf 2.65,
+ncs config.status 2.0.1
+configured by $0, generated by GNU Autoconf 2.68,
   with options \\"\$ac_cs_config\\"
 
-Copyright (C) 2009 Free Software Foundation, Inc.
+Copyright (C) 2010 Free Software Foundation, Inc.
 This config.status script is free software; the Free Software Foundation
 gives unlimited permission to copy, distribute and modify it."
 
@@ -24030,11 +25062,16 @@ ac_need_defaults=:
 while test $# != 0
 do
   case $1 in
-  --*=*)
+  --*=?*)
     ac_option=`expr "X$1" : 'X\([^=]*\)='`
     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
     ac_shift=:
     ;;
+  --*=)
+    ac_option=`expr "X$1" : 'X\([^=]*\)='`
+    ac_optarg=
+    ac_shift=:
+    ;;
   *)
     ac_option=$1
     ac_optarg=$2
@@ -24056,6 +25093,7 @@ do
     $ac_shift
     case $ac_optarg in
     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
+    '') as_fn_error $? "missing file argument" ;;
     esac
     as_fn_append CONFIG_FILES " '$ac_optarg'"
     ac_need_defaults=false;;
@@ -24068,7 +25106,7 @@ do
     ac_need_defaults=false;;
   --he | --h)
     # Conflict between --help and --header
-    as_fn_error "ambiguous option: \`$1'
+    as_fn_error $? "ambiguous option: \`$1'
 Try \`$0 --help' for more information.";;
   --help | --hel | -h )
     $as_echo "$ac_cs_usage"; exit ;;
@@ -24077,7 +25115,7 @@ Try \`$0 --help' for more information.";;
     ac_cs_silent=: ;;
 
   # This is an error.
-  -*) as_fn_error "unrecognized option: \`$1'
+  -*) as_fn_error $? "unrecognized option: \`$1'
 Try \`$0 --help' for more information." ;;
 
   *) as_fn_append ac_config_targets " $1"
@@ -24131,231 +25169,257 @@ AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
 sed_quote_subst='$sed_quote_subst'
 double_quote_subst='$double_quote_subst'
 delay_variable_subst='$delay_variable_subst'
-macro_version='`$ECHO "X$macro_version" | $Xsed -e "$delay_single_quote_subst"`'
-macro_revision='`$ECHO "X$macro_revision" | $Xsed -e "$delay_single_quote_subst"`'
-enable_shared='`$ECHO "X$enable_shared" | $Xsed -e "$delay_single_quote_subst"`'
-enable_static='`$ECHO "X$enable_static" | $Xsed -e "$delay_single_quote_subst"`'
-pic_mode='`$ECHO "X$pic_mode" | $Xsed -e "$delay_single_quote_subst"`'
-enable_fast_install='`$ECHO "X$enable_fast_install" | $Xsed -e "$delay_single_quote_subst"`'
-host_alias='`$ECHO "X$host_alias" | $Xsed -e "$delay_single_quote_subst"`'
-host='`$ECHO "X$host" | $Xsed -e "$delay_single_quote_subst"`'
-host_os='`$ECHO "X$host_os" | $Xsed -e "$delay_single_quote_subst"`'
-build_alias='`$ECHO "X$build_alias" | $Xsed -e "$delay_single_quote_subst"`'
-build='`$ECHO "X$build" | $Xsed -e "$delay_single_quote_subst"`'
-build_os='`$ECHO "X$build_os" | $Xsed -e "$delay_single_quote_subst"`'
-SED='`$ECHO "X$SED" | $Xsed -e "$delay_single_quote_subst"`'
-Xsed='`$ECHO "X$Xsed" | $Xsed -e "$delay_single_quote_subst"`'
-GREP='`$ECHO "X$GREP" | $Xsed -e "$delay_single_quote_subst"`'
-EGREP='`$ECHO "X$EGREP" | $Xsed -e "$delay_single_quote_subst"`'
-FGREP='`$ECHO "X$FGREP" | $Xsed -e "$delay_single_quote_subst"`'
-LD='`$ECHO "X$LD" | $Xsed -e "$delay_single_quote_subst"`'
-NM='`$ECHO "X$NM" | $Xsed -e "$delay_single_quote_subst"`'
-LN_S='`$ECHO "X$LN_S" | $Xsed -e "$delay_single_quote_subst"`'
-max_cmd_len='`$ECHO "X$max_cmd_len" | $Xsed -e "$delay_single_quote_subst"`'
-ac_objext='`$ECHO "X$ac_objext" | $Xsed -e "$delay_single_quote_subst"`'
-exeext='`$ECHO "X$exeext" | $Xsed -e "$delay_single_quote_subst"`'
-lt_unset='`$ECHO "X$lt_unset" | $Xsed -e "$delay_single_quote_subst"`'
-lt_SP2NL='`$ECHO "X$lt_SP2NL" | $Xsed -e "$delay_single_quote_subst"`'
-lt_NL2SP='`$ECHO "X$lt_NL2SP" | $Xsed -e "$delay_single_quote_subst"`'
-reload_flag='`$ECHO "X$reload_flag" | $Xsed -e "$delay_single_quote_subst"`'
-reload_cmds='`$ECHO "X$reload_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-OBJDUMP='`$ECHO "X$OBJDUMP" | $Xsed -e "$delay_single_quote_subst"`'
-deplibs_check_method='`$ECHO "X$deplibs_check_method" | $Xsed -e "$delay_single_quote_subst"`'
-file_magic_cmd='`$ECHO "X$file_magic_cmd" | $Xsed -e "$delay_single_quote_subst"`'
-AR='`$ECHO "X$AR" | $Xsed -e "$delay_single_quote_subst"`'
-AR_FLAGS='`$ECHO "X$AR_FLAGS" | $Xsed -e "$delay_single_quote_subst"`'
-STRIP='`$ECHO "X$STRIP" | $Xsed -e "$delay_single_quote_subst"`'
-RANLIB='`$ECHO "X$RANLIB" | $Xsed -e "$delay_single_quote_subst"`'
-old_postinstall_cmds='`$ECHO "X$old_postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-old_postuninstall_cmds='`$ECHO "X$old_postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_cmds='`$ECHO "X$old_archive_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-CC='`$ECHO "X$CC" | $Xsed -e "$delay_single_quote_subst"`'
-CFLAGS='`$ECHO "X$CFLAGS" | $Xsed -e "$delay_single_quote_subst"`'
-compiler='`$ECHO "X$compiler" | $Xsed -e "$delay_single_quote_subst"`'
-GCC='`$ECHO "X$GCC" | $Xsed -e "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_pipe='`$ECHO "X$lt_cv_sys_global_symbol_pipe" | $Xsed -e "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_cdecl='`$ECHO "X$lt_cv_sys_global_symbol_to_cdecl" | $Xsed -e "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address" | $Xsed -e "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`'
-objdir='`$ECHO "X$objdir" | $Xsed -e "$delay_single_quote_subst"`'
-SHELL='`$ECHO "X$SHELL" | $Xsed -e "$delay_single_quote_subst"`'
-ECHO='`$ECHO "X$ECHO" | $Xsed -e "$delay_single_quote_subst"`'
-MAGIC_CMD='`$ECHO "X$MAGIC_CMD" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag='`$ECHO "X$lt_prog_compiler_no_builtin_flag" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_wl='`$ECHO "X$lt_prog_compiler_wl" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_pic='`$ECHO "X$lt_prog_compiler_pic" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_static='`$ECHO "X$lt_prog_compiler_static" | $Xsed -e "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o='`$ECHO "X$lt_cv_prog_compiler_c_o" | $Xsed -e "$delay_single_quote_subst"`'
-need_locks='`$ECHO "X$need_locks" | $Xsed -e "$delay_single_quote_subst"`'
-DSYMUTIL='`$ECHO "X$DSYMUTIL" | $Xsed -e "$delay_single_quote_subst"`'
-NMEDIT='`$ECHO "X$NMEDIT" | $Xsed -e "$delay_single_quote_subst"`'
-LIPO='`$ECHO "X$LIPO" | $Xsed -e "$delay_single_quote_subst"`'
-OTOOL='`$ECHO "X$OTOOL" | $Xsed -e "$delay_single_quote_subst"`'
-OTOOL64='`$ECHO "X$OTOOL64" | $Xsed -e "$delay_single_quote_subst"`'
-libext='`$ECHO "X$libext" | $Xsed -e "$delay_single_quote_subst"`'
-shrext_cmds='`$ECHO "X$shrext_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-extract_expsyms_cmds='`$ECHO "X$extract_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-archive_cmds_need_lc='`$ECHO "X$archive_cmds_need_lc" | $Xsed -e "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes='`$ECHO "X$enable_shared_with_static_runtimes" | $Xsed -e "$delay_single_quote_subst"`'
-export_dynamic_flag_spec='`$ECHO "X$export_dynamic_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
-whole_archive_flag_spec='`$ECHO "X$whole_archive_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_needs_object='`$ECHO "X$compiler_needs_object" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_from_new_cmds='`$ECHO "X$old_archive_from_new_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds='`$ECHO "X$old_archive_from_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-archive_cmds='`$ECHO "X$archive_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-archive_expsym_cmds='`$ECHO "X$archive_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-module_cmds='`$ECHO "X$module_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-module_expsym_cmds='`$ECHO "X$module_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-with_gnu_ld='`$ECHO "X$with_gnu_ld" | $Xsed -e "$delay_single_quote_subst"`'
-allow_undefined_flag='`$ECHO "X$allow_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`'
-no_undefined_flag='`$ECHO "X$no_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec='`$ECHO "X$hardcode_libdir_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "X$hardcode_libdir_flag_spec_ld" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_separator='`$ECHO "X$hardcode_libdir_separator" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_direct='`$ECHO "X$hardcode_direct" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_direct_absolute='`$ECHO "X$hardcode_direct_absolute" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_minus_L='`$ECHO "X$hardcode_minus_L" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_shlibpath_var='`$ECHO "X$hardcode_shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_automatic='`$ECHO "X$hardcode_automatic" | $Xsed -e "$delay_single_quote_subst"`'
-inherit_rpath='`$ECHO "X$inherit_rpath" | $Xsed -e "$delay_single_quote_subst"`'
-link_all_deplibs='`$ECHO "X$link_all_deplibs" | $Xsed -e "$delay_single_quote_subst"`'
-fix_srcfile_path='`$ECHO "X$fix_srcfile_path" | $Xsed -e "$delay_single_quote_subst"`'
-always_export_symbols='`$ECHO "X$always_export_symbols" | $Xsed -e "$delay_single_quote_subst"`'
-export_symbols_cmds='`$ECHO "X$export_symbols_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-exclude_expsyms='`$ECHO "X$exclude_expsyms" | $Xsed -e "$delay_single_quote_subst"`'
-include_expsyms='`$ECHO "X$include_expsyms" | $Xsed -e "$delay_single_quote_subst"`'
-prelink_cmds='`$ECHO "X$prelink_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-file_list_spec='`$ECHO "X$file_list_spec" | $Xsed -e "$delay_single_quote_subst"`'
-variables_saved_for_relink='`$ECHO "X$variables_saved_for_relink" | $Xsed -e "$delay_single_quote_subst"`'
-need_lib_prefix='`$ECHO "X$need_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`'
-need_version='`$ECHO "X$need_version" | $Xsed -e "$delay_single_quote_subst"`'
-version_type='`$ECHO "X$version_type" | $Xsed -e "$delay_single_quote_subst"`'
-runpath_var='`$ECHO "X$runpath_var" | $Xsed -e "$delay_single_quote_subst"`'
-shlibpath_var='`$ECHO "X$shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`'
-shlibpath_overrides_runpath='`$ECHO "X$shlibpath_overrides_runpath" | $Xsed -e "$delay_single_quote_subst"`'
-libname_spec='`$ECHO "X$libname_spec" | $Xsed -e "$delay_single_quote_subst"`'
-library_names_spec='`$ECHO "X$library_names_spec" | $Xsed -e "$delay_single_quote_subst"`'
-soname_spec='`$ECHO "X$soname_spec" | $Xsed -e "$delay_single_quote_subst"`'
-postinstall_cmds='`$ECHO "X$postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-postuninstall_cmds='`$ECHO "X$postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-finish_cmds='`$ECHO "X$finish_cmds" | $Xsed -e "$delay_single_quote_subst"`'
-finish_eval='`$ECHO "X$finish_eval" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_into_libs='`$ECHO "X$hardcode_into_libs" | $Xsed -e "$delay_single_quote_subst"`'
-sys_lib_search_path_spec='`$ECHO "X$sys_lib_search_path_spec" | $Xsed -e "$delay_single_quote_subst"`'
-sys_lib_dlsearch_path_spec='`$ECHO "X$sys_lib_dlsearch_path_spec" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_action='`$ECHO "X$hardcode_action" | $Xsed -e "$delay_single_quote_subst"`'
-enable_dlopen='`$ECHO "X$enable_dlopen" | $Xsed -e "$delay_single_quote_subst"`'
-enable_dlopen_self='`$ECHO "X$enable_dlopen_self" | $Xsed -e "$delay_single_quote_subst"`'
-enable_dlopen_self_static='`$ECHO "X$enable_dlopen_self_static" | $Xsed -e "$delay_single_quote_subst"`'
-old_striplib='`$ECHO "X$old_striplib" | $Xsed -e "$delay_single_quote_subst"`'
-striplib='`$ECHO "X$striplib" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_lib_search_dirs='`$ECHO "X$compiler_lib_search_dirs" | $Xsed -e "$delay_single_quote_subst"`'
-predep_objects='`$ECHO "X$predep_objects" | $Xsed -e "$delay_single_quote_subst"`'
-postdep_objects='`$ECHO "X$postdep_objects" | $Xsed -e "$delay_single_quote_subst"`'
-predeps='`$ECHO "X$predeps" | $Xsed -e "$delay_single_quote_subst"`'
-postdeps='`$ECHO "X$postdeps" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_lib_search_path='`$ECHO "X$compiler_lib_search_path" | $Xsed -e "$delay_single_quote_subst"`'
-LD_FC='`$ECHO "X$LD_FC" | $Xsed -e "$delay_single_quote_subst"`'
-LD_F77='`$ECHO "X$LD_F77" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_cmds_FC='`$ECHO "X$old_archive_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_cmds_F77='`$ECHO "X$old_archive_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_FC='`$ECHO "X$compiler_FC" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_F77='`$ECHO "X$compiler_F77" | $Xsed -e "$delay_single_quote_subst"`'
-GCC_FC='`$ECHO "X$GCC_FC" | $Xsed -e "$delay_single_quote_subst"`'
-GCC_F77='`$ECHO "X$GCC_F77" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag_FC='`$ECHO "X$lt_prog_compiler_no_builtin_flag_FC" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag_F77='`$ECHO "X$lt_prog_compiler_no_builtin_flag_F77" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_wl_FC='`$ECHO "X$lt_prog_compiler_wl_FC" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_wl_F77='`$ECHO "X$lt_prog_compiler_wl_F77" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_pic_FC='`$ECHO "X$lt_prog_compiler_pic_FC" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_pic_F77='`$ECHO "X$lt_prog_compiler_pic_F77" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_static_FC='`$ECHO "X$lt_prog_compiler_static_FC" | $Xsed -e "$delay_single_quote_subst"`'
-lt_prog_compiler_static_F77='`$ECHO "X$lt_prog_compiler_static_F77" | $Xsed -e "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o_FC='`$ECHO "X$lt_cv_prog_compiler_c_o_FC" | $Xsed -e "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o_F77='`$ECHO "X$lt_cv_prog_compiler_c_o_F77" | $Xsed -e "$delay_single_quote_subst"`'
-archive_cmds_need_lc_FC='`$ECHO "X$archive_cmds_need_lc_FC" | $Xsed -e "$delay_single_quote_subst"`'
-archive_cmds_need_lc_F77='`$ECHO "X$archive_cmds_need_lc_F77" | $Xsed -e "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes_FC='`$ECHO "X$enable_shared_with_static_runtimes_FC" | $Xsed -e "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes_F77='`$ECHO "X$enable_shared_with_static_runtimes_F77" | $Xsed -e "$delay_single_quote_subst"`'
-export_dynamic_flag_spec_FC='`$ECHO "X$export_dynamic_flag_spec_FC" | $Xsed -e "$delay_single_quote_subst"`'
-export_dynamic_flag_spec_F77='`$ECHO "X$export_dynamic_flag_spec_F77" | $Xsed -e "$delay_single_quote_subst"`'
-whole_archive_flag_spec_FC='`$ECHO "X$whole_archive_flag_spec_FC" | $Xsed -e "$delay_single_quote_subst"`'
-whole_archive_flag_spec_F77='`$ECHO "X$whole_archive_flag_spec_F77" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_needs_object_FC='`$ECHO "X$compiler_needs_object_FC" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_needs_object_F77='`$ECHO "X$compiler_needs_object_F77" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_from_new_cmds_FC='`$ECHO "X$old_archive_from_new_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_from_new_cmds_F77='`$ECHO "X$old_archive_from_new_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds_FC='`$ECHO "X$old_archive_from_expsyms_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds_F77='`$ECHO "X$old_archive_from_expsyms_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-archive_cmds_FC='`$ECHO "X$archive_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-archive_cmds_F77='`$ECHO "X$archive_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-archive_expsym_cmds_FC='`$ECHO "X$archive_expsym_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-archive_expsym_cmds_F77='`$ECHO "X$archive_expsym_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-module_cmds_FC='`$ECHO "X$module_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-module_cmds_F77='`$ECHO "X$module_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-module_expsym_cmds_FC='`$ECHO "X$module_expsym_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-module_expsym_cmds_F77='`$ECHO "X$module_expsym_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-with_gnu_ld_FC='`$ECHO "X$with_gnu_ld_FC" | $Xsed -e "$delay_single_quote_subst"`'
-with_gnu_ld_F77='`$ECHO "X$with_gnu_ld_F77" | $Xsed -e "$delay_single_quote_subst"`'
-allow_undefined_flag_FC='`$ECHO "X$allow_undefined_flag_FC" | $Xsed -e "$delay_single_quote_subst"`'
-allow_undefined_flag_F77='`$ECHO "X$allow_undefined_flag_F77" | $Xsed -e "$delay_single_quote_subst"`'
-no_undefined_flag_FC='`$ECHO "X$no_undefined_flag_FC" | $Xsed -e "$delay_single_quote_subst"`'
-no_undefined_flag_F77='`$ECHO "X$no_undefined_flag_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_FC='`$ECHO "X$hardcode_libdir_flag_spec_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_F77='`$ECHO "X$hardcode_libdir_flag_spec_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld_FC='`$ECHO "X$hardcode_libdir_flag_spec_ld_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld_F77='`$ECHO "X$hardcode_libdir_flag_spec_ld_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_separator_FC='`$ECHO "X$hardcode_libdir_separator_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_libdir_separator_F77='`$ECHO "X$hardcode_libdir_separator_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_direct_FC='`$ECHO "X$hardcode_direct_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_direct_F77='`$ECHO "X$hardcode_direct_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_direct_absolute_FC='`$ECHO "X$hardcode_direct_absolute_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_direct_absolute_F77='`$ECHO "X$hardcode_direct_absolute_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_minus_L_FC='`$ECHO "X$hardcode_minus_L_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_minus_L_F77='`$ECHO "X$hardcode_minus_L_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_shlibpath_var_FC='`$ECHO "X$hardcode_shlibpath_var_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_shlibpath_var_F77='`$ECHO "X$hardcode_shlibpath_var_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_automatic_FC='`$ECHO "X$hardcode_automatic_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_automatic_F77='`$ECHO "X$hardcode_automatic_F77" | $Xsed -e "$delay_single_quote_subst"`'
-inherit_rpath_FC='`$ECHO "X$inherit_rpath_FC" | $Xsed -e "$delay_single_quote_subst"`'
-inherit_rpath_F77='`$ECHO "X$inherit_rpath_F77" | $Xsed -e "$delay_single_quote_subst"`'
-link_all_deplibs_FC='`$ECHO "X$link_all_deplibs_FC" | $Xsed -e "$delay_single_quote_subst"`'
-link_all_deplibs_F77='`$ECHO "X$link_all_deplibs_F77" | $Xsed -e "$delay_single_quote_subst"`'
-fix_srcfile_path_FC='`$ECHO "X$fix_srcfile_path_FC" | $Xsed -e "$delay_single_quote_subst"`'
-fix_srcfile_path_F77='`$ECHO "X$fix_srcfile_path_F77" | $Xsed -e "$delay_single_quote_subst"`'
-always_export_symbols_FC='`$ECHO "X$always_export_symbols_FC" | $Xsed -e "$delay_single_quote_subst"`'
-always_export_symbols_F77='`$ECHO "X$always_export_symbols_F77" | $Xsed -e "$delay_single_quote_subst"`'
-export_symbols_cmds_FC='`$ECHO "X$export_symbols_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-export_symbols_cmds_F77='`$ECHO "X$export_symbols_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-exclude_expsyms_FC='`$ECHO "X$exclude_expsyms_FC" | $Xsed -e "$delay_single_quote_subst"`'
-exclude_expsyms_F77='`$ECHO "X$exclude_expsyms_F77" | $Xsed -e "$delay_single_quote_subst"`'
-include_expsyms_FC='`$ECHO "X$include_expsyms_FC" | $Xsed -e "$delay_single_quote_subst"`'
-include_expsyms_F77='`$ECHO "X$include_expsyms_F77" | $Xsed -e "$delay_single_quote_subst"`'
-prelink_cmds_FC='`$ECHO "X$prelink_cmds_FC" | $Xsed -e "$delay_single_quote_subst"`'
-prelink_cmds_F77='`$ECHO "X$prelink_cmds_F77" | $Xsed -e "$delay_single_quote_subst"`'
-file_list_spec_FC='`$ECHO "X$file_list_spec_FC" | $Xsed -e "$delay_single_quote_subst"`'
-file_list_spec_F77='`$ECHO "X$file_list_spec_F77" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_action_FC='`$ECHO "X$hardcode_action_FC" | $Xsed -e "$delay_single_quote_subst"`'
-hardcode_action_F77='`$ECHO "X$hardcode_action_F77" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_lib_search_dirs_FC='`$ECHO "X$compiler_lib_search_dirs_FC" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_lib_search_dirs_F77='`$ECHO "X$compiler_lib_search_dirs_F77" | $Xsed -e "$delay_single_quote_subst"`'
-predep_objects_FC='`$ECHO "X$predep_objects_FC" | $Xsed -e "$delay_single_quote_subst"`'
-predep_objects_F77='`$ECHO "X$predep_objects_F77" | $Xsed -e "$delay_single_quote_subst"`'
-postdep_objects_FC='`$ECHO "X$postdep_objects_FC" | $Xsed -e "$delay_single_quote_subst"`'
-postdep_objects_F77='`$ECHO "X$postdep_objects_F77" | $Xsed -e "$delay_single_quote_subst"`'
-predeps_FC='`$ECHO "X$predeps_FC" | $Xsed -e "$delay_single_quote_subst"`'
-predeps_F77='`$ECHO "X$predeps_F77" | $Xsed -e "$delay_single_quote_subst"`'
-postdeps_FC='`$ECHO "X$postdeps_FC" | $Xsed -e "$delay_single_quote_subst"`'
-postdeps_F77='`$ECHO "X$postdeps_F77" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_lib_search_path_FC='`$ECHO "X$compiler_lib_search_path_FC" | $Xsed -e "$delay_single_quote_subst"`'
-compiler_lib_search_path_F77='`$ECHO "X$compiler_lib_search_path_F77" | $Xsed -e "$delay_single_quote_subst"`'
+macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
+macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
+enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
+enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
+pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
+enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
+SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
+ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
+host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
+host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
+host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
+build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
+build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
+build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
+SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
+Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
+GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
+EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
+FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
+LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
+NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
+LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
+max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
+ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
+exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
+lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
+lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
+lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
+lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
+reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
+reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
+OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
+deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
+file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
+file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
+want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
+DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
+sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
+AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
+AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
+archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
+STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
+RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
+old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
+old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
+old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
+lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
+CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
+CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
+compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
+GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
+lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
+lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
+lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
+lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
+nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
+lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
+objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
+MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
+lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
+need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
+MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
+DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
+NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
+LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
+OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
+OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
+libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
+shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
+extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
+archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
+enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
+export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
+whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
+compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
+old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
+old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
+archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
+archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
+module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
+module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
+with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
+allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
+no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
+hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
+hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
+hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
+hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
+hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
+inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
+link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
+always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
+export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
+exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
+include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
+prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
+postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
+file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
+variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
+need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
+need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
+version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
+runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
+shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
+shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
+libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
+library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
+soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
+install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
+postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
+postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
+finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
+finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
+hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
+sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
+sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
+hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
+enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
+enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
+enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
+old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
+striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
+compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`'
+predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`'
+postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`'
+predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`'
+postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`'
+compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`'
+LD_FC='`$ECHO "$LD_FC" | $SED "$delay_single_quote_subst"`'
+LD_F77='`$ECHO "$LD_F77" | $SED "$delay_single_quote_subst"`'
+reload_flag_FC='`$ECHO "$reload_flag_FC" | $SED "$delay_single_quote_subst"`'
+reload_flag_F77='`$ECHO "$reload_flag_F77" | $SED "$delay_single_quote_subst"`'
+reload_cmds_FC='`$ECHO "$reload_cmds_FC" | $SED "$delay_single_quote_subst"`'
+reload_cmds_F77='`$ECHO "$reload_cmds_F77" | $SED "$delay_single_quote_subst"`'
+old_archive_cmds_FC='`$ECHO "$old_archive_cmds_FC" | $SED "$delay_single_quote_subst"`'
+old_archive_cmds_F77='`$ECHO "$old_archive_cmds_F77" | $SED "$delay_single_quote_subst"`'
+compiler_FC='`$ECHO "$compiler_FC" | $SED "$delay_single_quote_subst"`'
+compiler_F77='`$ECHO "$compiler_F77" | $SED "$delay_single_quote_subst"`'
+GCC_FC='`$ECHO "$GCC_FC" | $SED "$delay_single_quote_subst"`'
+GCC_F77='`$ECHO "$GCC_F77" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_no_builtin_flag_FC='`$ECHO "$lt_prog_compiler_no_builtin_flag_FC" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_no_builtin_flag_F77='`$ECHO "$lt_prog_compiler_no_builtin_flag_F77" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_pic_FC='`$ECHO "$lt_prog_compiler_pic_FC" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_pic_F77='`$ECHO "$lt_prog_compiler_pic_F77" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_wl_FC='`$ECHO "$lt_prog_compiler_wl_FC" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_wl_F77='`$ECHO "$lt_prog_compiler_wl_F77" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_static_FC='`$ECHO "$lt_prog_compiler_static_FC" | $SED "$delay_single_quote_subst"`'
+lt_prog_compiler_static_F77='`$ECHO "$lt_prog_compiler_static_F77" | $SED "$delay_single_quote_subst"`'
+lt_cv_prog_compiler_c_o_FC='`$ECHO "$lt_cv_prog_compiler_c_o_FC" | $SED "$delay_single_quote_subst"`'
+lt_cv_prog_compiler_c_o_F77='`$ECHO "$lt_cv_prog_compiler_c_o_F77" | $SED "$delay_single_quote_subst"`'
+archive_cmds_need_lc_FC='`$ECHO "$archive_cmds_need_lc_FC" | $SED "$delay_single_quote_subst"`'
+archive_cmds_need_lc_F77='`$ECHO "$archive_cmds_need_lc_F77" | $SED "$delay_single_quote_subst"`'
+enable_shared_with_static_runtimes_FC='`$ECHO "$enable_shared_with_static_runtimes_FC" | $SED "$delay_single_quote_subst"`'
+enable_shared_with_static_runtimes_F77='`$ECHO "$enable_shared_with_static_runtimes_F77" | $SED "$delay_single_quote_subst"`'
+export_dynamic_flag_spec_FC='`$ECHO "$export_dynamic_flag_spec_FC" | $SED "$delay_single_quote_subst"`'
+export_dynamic_flag_spec_F77='`$ECHO "$export_dynamic_flag_spec_F77" | $SED "$delay_single_quote_subst"`'
+whole_archive_flag_spec_FC='`$ECHO "$whole_archive_flag_spec_FC" | $SED "$delay_single_quote_subst"`'
+whole_archive_flag_spec_F77='`$ECHO "$whole_archive_flag_spec_F77" | $SED "$delay_single_quote_subst"`'
+compiler_needs_object_FC='`$ECHO "$compiler_needs_object_FC" | $SED "$delay_single_quote_subst"`'
+compiler_needs_object_F77='`$ECHO "$compiler_needs_object_F77" | $SED "$delay_single_quote_subst"`'
+old_archive_from_new_cmds_FC='`$ECHO "$old_archive_from_new_cmds_FC" | $SED "$delay_single_quote_subst"`'
+old_archive_from_new_cmds_F77='`$ECHO "$old_archive_from_new_cmds_F77" | $SED "$delay_single_quote_subst"`'
+old_archive_from_expsyms_cmds_FC='`$ECHO "$old_archive_from_expsyms_cmds_FC" | $SED "$delay_single_quote_subst"`'
+old_archive_from_expsyms_cmds_F77='`$ECHO "$old_archive_from_expsyms_cmds_F77" | $SED "$delay_single_quote_subst"`'
+archive_cmds_FC='`$ECHO "$archive_cmds_FC" | $SED "$delay_single_quote_subst"`'
+archive_cmds_F77='`$ECHO "$archive_cmds_F77" | $SED "$delay_single_quote_subst"`'
+archive_expsym_cmds_FC='`$ECHO "$archive_expsym_cmds_FC" | $SED "$delay_single_quote_subst"`'
+archive_expsym_cmds_F77='`$ECHO "$archive_expsym_cmds_F77" | $SED "$delay_single_quote_subst"`'
+module_cmds_FC='`$ECHO "$module_cmds_FC" | $SED "$delay_single_quote_subst"`'
+module_cmds_F77='`$ECHO "$module_cmds_F77" | $SED "$delay_single_quote_subst"`'
+module_expsym_cmds_FC='`$ECHO "$module_expsym_cmds_FC" | $SED "$delay_single_quote_subst"`'
+module_expsym_cmds_F77='`$ECHO "$module_expsym_cmds_F77" | $SED "$delay_single_quote_subst"`'
+with_gnu_ld_FC='`$ECHO "$with_gnu_ld_FC" | $SED "$delay_single_quote_subst"`'
+with_gnu_ld_F77='`$ECHO "$with_gnu_ld_F77" | $SED "$delay_single_quote_subst"`'
+allow_undefined_flag_FC='`$ECHO "$allow_undefined_flag_FC" | $SED "$delay_single_quote_subst"`'
+allow_undefined_flag_F77='`$ECHO "$allow_undefined_flag_F77" | $SED "$delay_single_quote_subst"`'
+no_undefined_flag_FC='`$ECHO "$no_undefined_flag_FC" | $SED "$delay_single_quote_subst"`'
+no_undefined_flag_F77='`$ECHO "$no_undefined_flag_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_flag_spec_FC='`$ECHO "$hardcode_libdir_flag_spec_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_flag_spec_F77='`$ECHO "$hardcode_libdir_flag_spec_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_flag_spec_ld_FC='`$ECHO "$hardcode_libdir_flag_spec_ld_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_flag_spec_ld_F77='`$ECHO "$hardcode_libdir_flag_spec_ld_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_separator_FC='`$ECHO "$hardcode_libdir_separator_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_libdir_separator_F77='`$ECHO "$hardcode_libdir_separator_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_direct_FC='`$ECHO "$hardcode_direct_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_direct_F77='`$ECHO "$hardcode_direct_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_direct_absolute_FC='`$ECHO "$hardcode_direct_absolute_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_direct_absolute_F77='`$ECHO "$hardcode_direct_absolute_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_minus_L_FC='`$ECHO "$hardcode_minus_L_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_minus_L_F77='`$ECHO "$hardcode_minus_L_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_shlibpath_var_FC='`$ECHO "$hardcode_shlibpath_var_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_shlibpath_var_F77='`$ECHO "$hardcode_shlibpath_var_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_automatic_FC='`$ECHO "$hardcode_automatic_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_automatic_F77='`$ECHO "$hardcode_automatic_F77" | $SED "$delay_single_quote_subst"`'
+inherit_rpath_FC='`$ECHO "$inherit_rpath_FC" | $SED "$delay_single_quote_subst"`'
+inherit_rpath_F77='`$ECHO "$inherit_rpath_F77" | $SED "$delay_single_quote_subst"`'
+link_all_deplibs_FC='`$ECHO "$link_all_deplibs_FC" | $SED "$delay_single_quote_subst"`'
+link_all_deplibs_F77='`$ECHO "$link_all_deplibs_F77" | $SED "$delay_single_quote_subst"`'
+always_export_symbols_FC='`$ECHO "$always_export_symbols_FC" | $SED "$delay_single_quote_subst"`'
+always_export_symbols_F77='`$ECHO "$always_export_symbols_F77" | $SED "$delay_single_quote_subst"`'
+export_symbols_cmds_FC='`$ECHO "$export_symbols_cmds_FC" | $SED "$delay_single_quote_subst"`'
+export_symbols_cmds_F77='`$ECHO "$export_symbols_cmds_F77" | $SED "$delay_single_quote_subst"`'
+exclude_expsyms_FC='`$ECHO "$exclude_expsyms_FC" | $SED "$delay_single_quote_subst"`'
+exclude_expsyms_F77='`$ECHO "$exclude_expsyms_F77" | $SED "$delay_single_quote_subst"`'
+include_expsyms_FC='`$ECHO "$include_expsyms_FC" | $SED "$delay_single_quote_subst"`'
+include_expsyms_F77='`$ECHO "$include_expsyms_F77" | $SED "$delay_single_quote_subst"`'
+prelink_cmds_FC='`$ECHO "$prelink_cmds_FC" | $SED "$delay_single_quote_subst"`'
+prelink_cmds_F77='`$ECHO "$prelink_cmds_F77" | $SED "$delay_single_quote_subst"`'
+postlink_cmds_FC='`$ECHO "$postlink_cmds_FC" | $SED "$delay_single_quote_subst"`'
+postlink_cmds_F77='`$ECHO "$postlink_cmds_F77" | $SED "$delay_single_quote_subst"`'
+file_list_spec_FC='`$ECHO "$file_list_spec_FC" | $SED "$delay_single_quote_subst"`'
+file_list_spec_F77='`$ECHO "$file_list_spec_F77" | $SED "$delay_single_quote_subst"`'
+hardcode_action_FC='`$ECHO "$hardcode_action_FC" | $SED "$delay_single_quote_subst"`'
+hardcode_action_F77='`$ECHO "$hardcode_action_F77" | $SED "$delay_single_quote_subst"`'
+compiler_lib_search_dirs_FC='`$ECHO "$compiler_lib_search_dirs_FC" | $SED "$delay_single_quote_subst"`'
+compiler_lib_search_dirs_F77='`$ECHO "$compiler_lib_search_dirs_F77" | $SED "$delay_single_quote_subst"`'
+predep_objects_FC='`$ECHO "$predep_objects_FC" | $SED "$delay_single_quote_subst"`'
+predep_objects_F77='`$ECHO "$predep_objects_F77" | $SED "$delay_single_quote_subst"`'
+postdep_objects_FC='`$ECHO "$postdep_objects_FC" | $SED "$delay_single_quote_subst"`'
+postdep_objects_F77='`$ECHO "$postdep_objects_F77" | $SED "$delay_single_quote_subst"`'
+predeps_FC='`$ECHO "$predeps_FC" | $SED "$delay_single_quote_subst"`'
+predeps_F77='`$ECHO "$predeps_F77" | $SED "$delay_single_quote_subst"`'
+postdeps_FC='`$ECHO "$postdeps_FC" | $SED "$delay_single_quote_subst"`'
+postdeps_F77='`$ECHO "$postdeps_F77" | $SED "$delay_single_quote_subst"`'
+compiler_lib_search_path_FC='`$ECHO "$compiler_lib_search_path_FC" | $SED "$delay_single_quote_subst"`'
+compiler_lib_search_path_F77='`$ECHO "$compiler_lib_search_path_F77" | $SED "$delay_single_quote_subst"`'
 
 LTCC='$LTCC'
 LTCFLAGS='$LTCFLAGS'
 compiler='$compiler_DEFAULT'
 
+# A function that is used when there is no print builtin or printf.
+func_fallback_echo ()
+{
+  eval 'cat <<_LTECHO_EOF
+\$1
+_LTECHO_EOF'
+}
+
 # Quote evaled strings.
-for var in SED \
+for var in SHELL \
+ECHO \
+SED \
 GREP \
 EGREP \
 FGREP \
@@ -24368,8 +25432,13 @@ reload_flag \
 OBJDUMP \
 deplibs_check_method \
 file_magic_cmd \
+file_magic_glob \
+want_nocaseglob \
+DLLTOOL \
+sharedlib_from_linklib_cmd \
 AR \
 AR_FLAGS \
+archiver_list_spec \
 STRIP \
 RANLIB \
 CC \
@@ -24379,14 +25448,14 @@ lt_cv_sys_global_symbol_pipe \
 lt_cv_sys_global_symbol_to_cdecl \
 lt_cv_sys_global_symbol_to_c_name_address \
 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
-SHELL \
-ECHO \
+nm_file_list_spec \
 lt_prog_compiler_no_builtin_flag \
-lt_prog_compiler_wl \
 lt_prog_compiler_pic \
+lt_prog_compiler_wl \
 lt_prog_compiler_static \
 lt_cv_prog_compiler_c_o \
 need_locks \
+MANIFEST_TOOL \
 DSYMUTIL \
 NMEDIT \
 LIPO \
@@ -24402,7 +25471,6 @@ no_undefined_flag \
 hardcode_libdir_flag_spec \
 hardcode_libdir_flag_spec_ld \
 hardcode_libdir_separator \
-fix_srcfile_path \
 exclude_expsyms \
 include_expsyms \
 file_list_spec \
@@ -24410,6 +25478,7 @@ variables_saved_for_relink \
 libname_spec \
 library_names_spec \
 soname_spec \
+install_override_mode \
 finish_eval \
 old_striplib \
 striplib \
@@ -24421,14 +25490,16 @@ postdeps \
 compiler_lib_search_path \
 LD_FC \
 LD_F77 \
+reload_flag_FC \
+reload_flag_F77 \
 compiler_FC \
 compiler_F77 \
 lt_prog_compiler_no_builtin_flag_FC \
 lt_prog_compiler_no_builtin_flag_F77 \
-lt_prog_compiler_wl_FC \
-lt_prog_compiler_wl_F77 \
 lt_prog_compiler_pic_FC \
 lt_prog_compiler_pic_F77 \
+lt_prog_compiler_wl_FC \
+lt_prog_compiler_wl_F77 \
 lt_prog_compiler_static_FC \
 lt_prog_compiler_static_F77 \
 lt_cv_prog_compiler_c_o_FC \
@@ -24451,8 +25522,6 @@ hardcode_libdir_flag_spec_ld_FC \
 hardcode_libdir_flag_spec_ld_F77 \
 hardcode_libdir_separator_FC \
 hardcode_libdir_separator_F77 \
-fix_srcfile_path_FC \
-fix_srcfile_path_F77 \
 exclude_expsyms_FC \
 exclude_expsyms_F77 \
 include_expsyms_FC \
@@ -24471,9 +25540,9 @@ postdeps_FC \
 postdeps_F77 \
 compiler_lib_search_path_FC \
 compiler_lib_search_path_F77; do
-    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
+    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
     *[\\\\\\\`\\"\\\$]*)
-      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
+      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
       ;;
     *)
       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
@@ -24495,11 +25564,14 @@ module_cmds \
 module_expsym_cmds \
 export_symbols_cmds \
 prelink_cmds \
+postlink_cmds \
 postinstall_cmds \
 postuninstall_cmds \
 finish_cmds \
 sys_lib_search_path_spec \
 sys_lib_dlsearch_path_spec \
+reload_cmds_FC \
+reload_cmds_F77 \
 old_archive_cmds_FC \
 old_archive_cmds_F77 \
 old_archive_from_new_cmds_FC \
@@ -24517,10 +25589,12 @@ module_expsym_cmds_F77 \
 export_symbols_cmds_FC \
 export_symbols_cmds_F77 \
 prelink_cmds_FC \
-prelink_cmds_F77; do
-    case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
+prelink_cmds_F77 \
+postlink_cmds_FC \
+postlink_cmds_F77; do
+    case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
     *[\\\\\\\`\\"\\\$]*)
-      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
+      eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
       ;;
     *)
       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
@@ -24528,12 +25602,6 @@ prelink_cmds_F77; do
     esac
 done
 
-# Fix-up fallback echo if it was mangled by the above quoting rules.
-case \$lt_ECHO in
-*'\\\$0 --fallback-echo"')  lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\$0 --fallback-echo"\$/\$0 --fallback-echo"/'\`
-  ;;
-esac
-
 ac_aux_dir='$ac_aux_dir'
 xsi_shell='$xsi_shell'
 lt_shell_append='$lt_shell_append'
@@ -24616,7 +25684,7 @@ do
     "bin/runcase") CONFIG_FILES="$CONFIG_FILES bin/runcase" ;;
     "bin/SaturneGUI") CONFIG_FILES="$CONFIG_FILES bin/SaturneGUI" ;;
 
-  *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
+  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
   esac
 done
 
@@ -24639,9 +25707,10 @@ fi
 # after its creation but before its name has been assigned to `$tmp'.
 $debug ||
 {
-  tmp=
+  tmp= ac_tmp=
   trap 'exit_status=$?
-  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
+  : "${ac_tmp:=$tmp}"
+  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
 ' 0
   trap 'as_fn_exit 1' 1 2 13 15
 }
@@ -24649,12 +25718,13 @@ $debug ||
 
 {
   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
-  test -n "$tmp" && test -d "$tmp"
+  test -d "$tmp"
 }  ||
 {
   tmp=./conf$$-$RANDOM
   (umask 077 && mkdir "$tmp")
-} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
+} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
+ac_tmp=$tmp
 
 # Set up the scripts for CONFIG_FILES section.
 # No need to generate them if there are no CONFIG_FILES.
@@ -24688,24 +25758,24 @@ if test "x$ac_cr" = x; then
 fi
 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
-  ac_cs_awk_cr='\r'
+  ac_cs_awk_cr='\\r'
 else
   ac_cs_awk_cr=$ac_cr
 fi
 
-echo 'BEGIN {' >"$tmp/subs1.awk" &&
+echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
 _ACEOF
 
 # Create commands to substitute file output variables.
 {
   echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
-  echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
+  echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
   echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
   echo "_ACAWK" &&
   echo "_ACEOF"
 } >conf$$files.sh &&
 . ./conf$$files.sh ||
-  as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
+  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
 rm -f conf$$files.sh
 
 {
@@ -24713,18 +25783,18 @@ rm -f conf$$files.sh
   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
   echo "_ACEOF"
 } >conf$$subs.sh ||
-  as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
+  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
+ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
 ac_delim='%!_!# '
 for ac_last_try in false false false false false :; do
   . ./conf$$subs.sh ||
-    as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
+    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
 
   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
   if test $ac_delim_n = $ac_delim_num; then
     break
   elif $ac_last_try; then
-    as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
+    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
   else
     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
   fi
@@ -24732,7 +25802,7 @@ done
 rm -f conf$$subs.sh
 
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
+cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
 _ACEOF
 sed -n '
 h
@@ -24780,7 +25850,7 @@ t delim
 rm -f conf$$subs.awk
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 _ACAWK
-cat >>"\$tmp/subs1.awk" <<_ACAWK &&
+cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
   for (key in S) S_is_set[key] = 1
   FS = ""
   \$ac_cs_awk_pipe_init
@@ -24818,21 +25888,29 @@ if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
 else
   cat
-fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
-  || as_fn_error "could not setup config files machinery" "$LINENO" 5
+fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
+  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
 _ACEOF
 
-# VPATH may cause trouble with some makes, so we remove $(srcdir),
-# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
+# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
+# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
 # trailing colons and then remove the whole line if VPATH becomes empty
 # (actually we leave an empty line to preserve line numbers).
 if test "x$srcdir" = x.; then
-  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
-s/:*\$(srcdir):*/:/
-s/:*\${srcdir}:*/:/
-s/:*@srcdir@:*/:/
-s/^\([^=]*=[	 ]*\):*/\1/
+  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
+h
+s///
+s/^/:/
+s/[	 ]*$/:/
+s/:\$(srcdir):/:/g
+s/:\${srcdir}:/:/g
+s/:@srcdir@:/:/g
+s/^:*//
 s/:*$//
+x
+s/\(=[	 ]*\).*/\1/
+G
+s/\n//
 s/^[^=]*=[	 ]*$//
 }'
 fi
@@ -24844,7 +25922,7 @@ fi # test -n "$CONFIG_FILES"
 # No need to generate them if there are no CONFIG_HEADERS.
 # This happens for instance with `./config.status Makefile'.
 if test -n "$CONFIG_HEADERS"; then
-cat >"$tmp/defines.awk" <<\_ACAWK ||
+cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
 BEGIN {
 _ACEOF
 
@@ -24856,11 +25934,11 @@ _ACEOF
 # handling of long lines.
 ac_delim='%!_!# '
 for ac_last_try in false false :; do
-  ac_t=`sed -n "/$ac_delim/p" confdefs.h`
-  if test -z "$ac_t"; then
+  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
+  if test -z "$ac_tt"; then
     break
   elif $ac_last_try; then
-    as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
+    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
   else
     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
   fi
@@ -24945,7 +26023,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 _ACAWK
 _ACEOF
 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-  as_fn_error "could not setup config headers machinery" "$LINENO" 5
+  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
 fi # test -n "$CONFIG_HEADERS"
 
 
@@ -24958,7 +26036,7 @@ do
   esac
   case $ac_mode$ac_tag in
   :[FHL]*:*);;
-  :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
+  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
   :[FH]-) ac_tag=-:-;;
   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
   esac
@@ -24977,7 +26055,7 @@ do
     for ac_f
     do
       case $ac_f in
-      -) ac_f="$tmp/stdin";;
+      -) ac_f="$ac_tmp/stdin";;
       *) # Look for the file first in the build tree, then in the source tree
 	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
 	 # because $ac_f cannot contain `:'.
@@ -24986,7 +26064,7 @@ do
 	   [\\/$]*) false;;
 	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
 	   esac ||
-	   as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
+	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
       esac
       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
       as_fn_append ac_file_inputs " '$ac_f'"
@@ -25012,8 +26090,8 @@ $as_echo "$as_me: creating $ac_file" >&6;}
     esac
 
     case $ac_tag in
-    *:-:* | *:-) cat >"$tmp/stdin" \
-      || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
+    *:-:* | *:-) cat >"$ac_tmp/stdin" \
+      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
     esac
     ;;
   esac
@@ -25151,26 +26229,27 @@ $ac_datarootdir_hack
 "
 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
 if $ac_cs_awk_getline; then
-  $AWK -f "$tmp/subs.awk"
+  $AWK -f "$ac_tmp/subs.awk"
 else
-  $AWK -f "$tmp/subs.awk" | $SHELL
-fi >$tmp/out \
-  || as_fn_error "could not create $ac_file" "$LINENO" 5
+  $AWK -f "$ac_tmp/subs.awk" | $SHELL
+fi \
+  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
 
 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
-  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
-  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
+  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
+  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
+      "$ac_tmp/out"`; test -z "$ac_out"; } &&
   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined.  Please make sure it is defined." >&5
+which seems to be undefined.  Please make sure it is defined" >&5
 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined.  Please make sure it is defined." >&2;}
+which seems to be undefined.  Please make sure it is defined" >&2;}
 
-  rm -f "$tmp/stdin"
+  rm -f "$ac_tmp/stdin"
   case $ac_file in
-  -) cat "$tmp/out" && rm -f "$tmp/out";;
-  *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
+  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
+  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
   esac \
-  || as_fn_error "could not create $ac_file" "$LINENO" 5
+  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  ;;
   :H)
   #
@@ -25179,21 +26258,21 @@ which seems to be undefined.  Please make sure it is defined." >&2;}
   if test x"$ac_file" != x-; then
     {
       $as_echo "/* $configure_input  */" \
-      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
-    } >"$tmp/config.h" \
-      || as_fn_error "could not create $ac_file" "$LINENO" 5
-    if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
+      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
+    } >"$ac_tmp/config.h" \
+      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
+    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
 $as_echo "$as_me: $ac_file is unchanged" >&6;}
     else
       rm -f "$ac_file"
-      mv "$tmp/config.h" "$ac_file" \
-	|| as_fn_error "could not create $ac_file" "$LINENO" 5
+      mv "$ac_tmp/config.h" "$ac_file" \
+	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
     fi
   else
     $as_echo "/* $configure_input  */" \
-      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
-      || as_fn_error "could not create -" "$LINENO" 5
+      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
+      || as_fn_error $? "could not create -" "$LINENO" 5
   fi
 # Compute "$ac_file"'s index in $config_headers.
 _am_arg="$ac_file"
@@ -25354,7 +26433,8 @@ $as_echo X"$file" |
 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
 #
 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-#                 2006, 2007, 2008 Free Software Foundation, Inc.
+#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
+#                 Inc.
 #   Written by Gordon Matzigkeit, 1996
 #
 #   This file is part of GNU Libtool.
@@ -25402,6 +26482,12 @@ pic_mode=$pic_mode
 # Whether or not to optimize for fast installation.
 fast_install=$enable_fast_install
 
+# Shell to use when invoking shell scripts.
+SHELL=$lt_SHELL
+
+# An echo program that protects backslashes.
+ECHO=$lt_ECHO
+
 # The host system.
 host_alias=$host_alias
 host=$host
@@ -25451,9 +26537,11 @@ SP2NL=$lt_lt_SP2NL
 # turn newlines into spaces.
 NL2SP=$lt_lt_NL2SP
 
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag
-reload_cmds=$lt_reload_cmds
+# convert \$build file names to \$host format.
+to_host_file_cmd=$lt_cv_to_host_file_cmd
+
+# convert \$build files to toolchain format.
+to_tool_file_cmd=$lt_cv_to_tool_file_cmd
 
 # An object symbol dumper.
 OBJDUMP=$lt_OBJDUMP
@@ -25461,13 +26549,30 @@ OBJDUMP=$lt_OBJDUMP
 # Method to check whether dependent libraries are shared objects.
 deplibs_check_method=$lt_deplibs_check_method
 
-# Command to use when deplibs_check_method == "file_magic".
+# Command to use when deplibs_check_method = "file_magic".
 file_magic_cmd=$lt_file_magic_cmd
 
+# How to find potential files when deplibs_check_method = "file_magic".
+file_magic_glob=$lt_file_magic_glob
+
+# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
+want_nocaseglob=$lt_want_nocaseglob
+
+# DLL creation program.
+DLLTOOL=$lt_DLLTOOL
+
+# Command to associate shared and link libraries.
+sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
+
 # The archiver.
 AR=$lt_AR
+
+# Flags to create an archive.
 AR_FLAGS=$lt_AR_FLAGS
 
+# How to feed a file listing to the archiver.
+archiver_list_spec=$lt_archiver_list_spec
+
 # A symbol stripping program.
 STRIP=$lt_STRIP
 
@@ -25476,6 +26581,9 @@ RANLIB=$lt_RANLIB
 old_postinstall_cmds=$lt_old_postinstall_cmds
 old_postuninstall_cmds=$lt_old_postuninstall_cmds
 
+# Whether to use a lock for old archive extraction.
+lock_old_archive_extraction=$lock_old_archive_extraction
+
 # A C compiler.
 LTCC=$lt_CC
 
@@ -25494,14 +26602,14 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
 # Transform the output of nm in a C name address pair when lib prefix is needed.
 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
 
-# The name of the directory that contains temporary libtool files.
-objdir=$objdir
+# Specify filename containing input files for \$NM.
+nm_file_list_spec=$lt_nm_file_list_spec
 
-# Shell to use when invoking shell scripts.
-SHELL=$lt_SHELL
+# The root where to search for dependent libraries,and in which our libraries should be installed.
+lt_sysroot=$lt_sysroot
 
-# An echo program that does not interpret backslashes.
-ECHO=$lt_ECHO
+# The name of the directory that contains temporary libtool files.
+objdir=$objdir
 
 # Used to examine libraries when file_magic_cmd begins with "file".
 MAGIC_CMD=$MAGIC_CMD
@@ -25509,6 +26617,9 @@ MAGIC_CMD=$MAGIC_CMD
 # Must we lock files when doing compilation?
 need_locks=$lt_need_locks
 
+# Manifest tool.
+MANIFEST_TOOL=$lt_MANIFEST_TOOL
+
 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
 DSYMUTIL=$lt_DSYMUTIL
 
@@ -25565,6 +26676,9 @@ library_names_spec=$lt_library_names_spec
 # The coded name of the library, if different from the real name.
 soname_spec=$lt_soname_spec
 
+# Permission mode override for installation of shared libraries.
+install_override_mode=$lt_install_override_mode
+
 # Command to use after installation of a shared archive.
 postinstall_cmds=$lt_postinstall_cmds
 
@@ -25604,6 +26718,10 @@ striplib=$lt_striplib
 # The linker used to build libraries.
 LD=$lt_LD
 
+# How to create reloadable object files.
+reload_flag=$lt_reload_flag
+reload_cmds=$lt_reload_cmds
+
 # Commands used to build an old-style archive.
 old_archive_cmds=$lt_old_archive_cmds
 
@@ -25616,12 +26734,12 @@ with_gcc=$GCC
 # Compiler flag to turn off builtin functions.
 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
 
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl
-
 # Additional compiler flags for building library objects.
 pic_flag=$lt_lt_prog_compiler_pic
 
+# How to pass a linker flag through the compiler.
+wl=$lt_lt_prog_compiler_wl
+
 # Compiler flag to prevent dynamic linking.
 link_static_flag=$lt_lt_prog_compiler_static
 
@@ -25708,9 +26826,6 @@ inherit_rpath=$inherit_rpath
 # Whether libtool must link a program against all its dependency libraries.
 link_all_deplibs=$link_all_deplibs
 
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path
-
 # Set to "yes" if exported symbols are required.
 always_export_symbols=$always_export_symbols
 
@@ -25726,6 +26841,9 @@ include_expsyms=$lt_include_expsyms
 # Commands necessary for linking programs (against libraries) with templates.
 prelink_cmds=$lt_prelink_cmds
 
+# Commands necessary for finishing linking programs.
+postlink_cmds=$lt_postlink_cmds
+
 # Specify filename containing input files.
 file_list_spec=$lt_file_list_spec
 
@@ -25772,212 +26890,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
   # text mode, it properly converts lines to CR/LF.  This bash problem
   # is reportedly fixed, but why not run on old versions too?
-  sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
-    || (rm -f "$cfgfile"; exit 1)
-
-  case $xsi_shell in
-  yes)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
-  case ${1} in
-    */*) func_dirname_result="${1%/*}${2}" ;;
-    *  ) func_dirname_result="${3}" ;;
-  esac
-}
-
-# func_basename file
-func_basename ()
-{
-  func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-#   dirname:  Compute the dirname of FILE.  If nonempty,
-#             add APPEND to the result, otherwise set result
-#             to NONDIR_REPLACEMENT.
-#             value returned in "$func_dirname_result"
-#   basename: Compute filename of FILE.
-#             value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
-  case ${1} in
-    */*) func_dirname_result="${1%/*}${2}" ;;
-    *  ) func_dirname_result="${3}" ;;
-  esac
-  func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
-  # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
-  # positional parameters, so assign one to ordinary parameter first.
-  func_stripname_result=${3}
-  func_stripname_result=${func_stripname_result#"${1}"}
-  func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
-  func_opt_split_opt=${1%%=*}
-  func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
-  case ${1} in
-    *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
-    *)    func_lo2o_result=${1} ;;
-  esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
-  func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
-  func_arith_result=$(( $* ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
-  func_len_result=${#1}
-}
-
-_LT_EOF
-    ;;
-  *) # Bourne compatible functions.
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
-  # Extract subdirectory from the argument.
-  func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
-  if test "X$func_dirname_result" = "X${1}"; then
-    func_dirname_result="${3}"
-  else
-    func_dirname_result="$func_dirname_result${2}"
-  fi
-}
-
-# func_basename file
-func_basename ()
-{
-  func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
-}
-
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
-  case ${2} in
-    .*) func_stripname_result=`$ECHO "X${3}" \
-           | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
-    *)  func_stripname_result=`$ECHO "X${3}" \
-           | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
-  esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[^=]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
-  func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
-  func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
-  func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
-  func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[^.]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
-  func_arith_result=`expr "$@"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
-  func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
-  yes)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
-  eval "$1+=\$2"
-}
-_LT_EOF
-    ;;
-  *)
-    cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
-  eval "$1=\$$1\$2"
-}
-
-_LT_EOF
-    ;;
-  esac
-
-
-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
-    || (rm -f "$cfgfile"; exit 1)
-
-  mv -f "$cfgfile" "$ofile" ||
+  sed '$q' "$ltmain" >> "$cfgfile" \
+     || (rm -f "$cfgfile"; exit 1)
+
+  if test x"$xsi_shell" = xyes; then
+  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
+func_dirname ()\
+{\
+\    case ${1} in\
+\      */*) func_dirname_result="${1%/*}${2}" ;;\
+\      *  ) func_dirname_result="${3}" ;;\
+\    esac\
+} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_basename ()$/,/^} # func_basename /c\
+func_basename ()\
+{\
+\    func_basename_result="${1##*/}"\
+} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
+func_dirname_and_basename ()\
+{\
+\    case ${1} in\
+\      */*) func_dirname_result="${1%/*}${2}" ;;\
+\      *  ) func_dirname_result="${3}" ;;\
+\    esac\
+\    func_basename_result="${1##*/}"\
+} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
+func_stripname ()\
+{\
+\    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
+\    # positional parameters, so assign one to ordinary parameter first.\
+\    func_stripname_result=${3}\
+\    func_stripname_result=${func_stripname_result#"${1}"}\
+\    func_stripname_result=${func_stripname_result%"${2}"}\
+} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
+func_split_long_opt ()\
+{\
+\    func_split_long_opt_name=${1%%=*}\
+\    func_split_long_opt_arg=${1#*=}\
+} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
+func_split_short_opt ()\
+{\
+\    func_split_short_opt_arg=${1#??}\
+\    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
+} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
+func_lo2o ()\
+{\
+\    case ${1} in\
+\      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
+\      *)    func_lo2o_result=${1} ;;\
+\    esac\
+} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_xform ()$/,/^} # func_xform /c\
+func_xform ()\
+{\
+    func_xform_result=${1%.*}.lo\
+} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_arith ()$/,/^} # func_arith /c\
+func_arith ()\
+{\
+    func_arith_result=$(( $* ))\
+} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_len ()$/,/^} # func_len /c\
+func_len ()\
+{\
+    func_len_result=${#1}\
+} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+fi
+
+if test x"$lt_shell_append" = xyes; then
+  sed -e '/^func_append ()$/,/^} # func_append /c\
+func_append ()\
+{\
+    eval "${1}+=\\${2}"\
+} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
+func_append_quoted ()\
+{\
+\    func_quote_for_eval "${2}"\
+\    eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
+} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
+  && mv -f "$cfgfile.tmp" "$cfgfile" \
+    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+test 0 -eq $? || _lt_function_replace_fail=:
+
+
+  # Save a `func_append' function call where possible by direct use of '+='
+  sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
+    && mv -f "$cfgfile.tmp" "$cfgfile" \
+      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+  test 0 -eq $? || _lt_function_replace_fail=:
+else
+  # Save a `func_append' function call even when '+=' is not available
+  sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
+    && mv -f "$cfgfile.tmp" "$cfgfile" \
+      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
+  test 0 -eq $? || _lt_function_replace_fail=:
+fi
+
+if test x"$_lt_function_replace_fail" = x":"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
+$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
+fi
+
+
+   mv -f "$cfgfile" "$ofile" ||
     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
   chmod +x "$ofile"
 
@@ -25989,6 +27064,10 @@ _LT_EOF
 # The linker used to build libraries.
 LD=$lt_LD_FC
 
+# How to create reloadable object files.
+reload_flag=$lt_reload_flag_FC
+reload_cmds=$lt_reload_cmds_FC
+
 # Commands used to build an old-style archive.
 old_archive_cmds=$lt_old_archive_cmds_FC
 
@@ -26001,12 +27080,12 @@ with_gcc=$GCC_FC
 # Compiler flag to turn off builtin functions.
 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_FC
 
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl_FC
-
 # Additional compiler flags for building library objects.
 pic_flag=$lt_lt_prog_compiler_pic_FC
 
+# How to pass a linker flag through the compiler.
+wl=$lt_lt_prog_compiler_wl_FC
+
 # Compiler flag to prevent dynamic linking.
 link_static_flag=$lt_lt_prog_compiler_static_FC
 
@@ -26093,9 +27172,6 @@ inherit_rpath=$inherit_rpath_FC
 # Whether libtool must link a program against all its dependency libraries.
 link_all_deplibs=$link_all_deplibs_FC
 
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path_FC
-
 # Set to "yes" if exported symbols are required.
 always_export_symbols=$always_export_symbols_FC
 
@@ -26111,6 +27187,9 @@ include_expsyms=$lt_include_expsyms_FC
 # Commands necessary for linking programs (against libraries) with templates.
 prelink_cmds=$lt_prelink_cmds_FC
 
+# Commands necessary for finishing linking programs.
+postlink_cmds=$lt_postlink_cmds_FC
+
 # Specify filename containing input files.
 file_list_spec=$lt_file_list_spec_FC
 
@@ -26142,6 +27221,10 @@ _LT_EOF
 # The linker used to build libraries.
 LD=$lt_LD_F77
 
+# How to create reloadable object files.
+reload_flag=$lt_reload_flag_F77
+reload_cmds=$lt_reload_cmds_F77
+
 # Commands used to build an old-style archive.
 old_archive_cmds=$lt_old_archive_cmds_F77
 
@@ -26154,12 +27237,12 @@ with_gcc=$GCC_F77
 # Compiler flag to turn off builtin functions.
 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_F77
 
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl_F77
-
 # Additional compiler flags for building library objects.
 pic_flag=$lt_lt_prog_compiler_pic_F77
 
+# How to pass a linker flag through the compiler.
+wl=$lt_lt_prog_compiler_wl_F77
+
 # Compiler flag to prevent dynamic linking.
 link_static_flag=$lt_lt_prog_compiler_static_F77
 
@@ -26246,9 +27329,6 @@ inherit_rpath=$inherit_rpath_F77
 # Whether libtool must link a program against all its dependency libraries.
 link_all_deplibs=$link_all_deplibs_F77
 
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path_F77
-
 # Set to "yes" if exported symbols are required.
 always_export_symbols=$always_export_symbols_F77
 
@@ -26264,6 +27344,9 @@ include_expsyms=$lt_include_expsyms_F77
 # Commands necessary for linking programs (against libraries) with templates.
 prelink_cmds=$lt_prelink_cmds_F77
 
+# Commands necessary for finishing linking programs.
+postlink_cmds=$lt_postlink_cmds_F77
+
 # Specify filename containing input files.
 file_list_spec=$lt_file_list_spec_F77
 
@@ -26411,7 +27494,7 @@ _ACEOF
 ac_clean_files=$ac_clean_files_save
 
 test $ac_write_fail = 0 ||
-  as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
+  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
 
 
 # configure is writing to config.log, and then calls config.status.
@@ -26432,7 +27515,7 @@ if test "$no_create" != yes; then
   exec 5>>config.log
   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
   # would make configure fail if this is the last instruction.
-  $ac_cs_success || as_fn_exit $?
+  $ac_cs_success || as_fn_exit 1
 fi
 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
diff --git a/configure.ac b/configure.ac
index 52ee5fc..b6f80da 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4,7 +4,7 @@
 #   This file is part of the Code_Saturne Kernel, element of the
 #   Code_Saturne CFD tool.
 #
-#   Copyright (C) 2009 EDF S.A., France
+#   Copyright (C) 2009-2011 EDF S.A., France
 #
 #   The Code_Saturne Kernel is free software; you can redistribute it
 #   and/or modify it under the terms of the GNU General Public License
@@ -31,7 +31,7 @@ m4_define([cs_licence_c_comment],
    This file is part of the Code_Saturne Kernel, element of the
    Code_Saturne CFD tool.
 
-   Copyright (C) 2009 EDF S.A., France
+   Copyright (C) 2009-2011 EDF S.A., France
 
    The Code_Saturne Kernel is free software; you can redistribute it
    and/or modify it under the terms of the GNU General Public License
@@ -51,8 +51,8 @@ m4_define([cs_licence_c_comment],
 
 m4_define([cs_major_version], [2])
 m4_define([cs_minor_version], [0])
-m4_define([cs_release_version], [0])
-m4_define([cs_version_extra], [-rc1])
+m4_define([cs_release_version], [1])
+m4_define([cs_version_extra], [])
 m4_define([cs_version_string],
           [cs_major_version.cs_minor_version.cs_release_version@&t at cs_version_extra])
 
@@ -73,6 +73,9 @@ AM_INIT_AUTOMAKE([-Wall])
 
 AM_MAINTAINER_MODE
 
+# Enable silent rules with "./configure --enable-silent-rules" or "make V=0"
+m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES])
+
 #------------------------------------------------------------------------------
 # Checks for programs.
 #------------------------------------------------------------------------------
@@ -222,7 +225,11 @@ fi
 # Fortran flags for French translation
 
 if test "x$french" = "xtrue"; then
-  FCFLAGS="${FCFLAGS} -D_CS_LANG_FR"
+  if test "x$cs_ibm_bg_type" != "x" ; then
+    FCFLAGS="${FCFLAGS} -WF,-D_CS_LANG_FR"
+  else
+    FCFLAGS="${FCFLAGS} -D_CS_LANG_FR"
+  fi
 fi
 
 # We may only turn on processing for libtool now that the basic compiler
@@ -234,7 +241,7 @@ fi
 # take effect whether the result is true or not (maybe due to a bug),
 # so we directly use autoconf's enable_shared variable.
 
-if test "x$cs_disable_shared" = "xyes" ; then
+if test "x$cs_ibm_bg_type" != "x" ; then
    enable_shared=no
 fi
 
@@ -352,7 +359,7 @@ CS_AC_TEST_SYRTHES
 AC_ARG_WITH(prepro, [AS_HELP_STRING([--with-prepro=PATH],
                                     [specify prefix directory for the Preprocessor])])
 
-AC_PATH_PROG([ecs], [cs_preprocess],
+AC_PATH_PROG([ecs], [cs_preprocess$EXEEXT],
              [no],
              [$with_prepro/bin$PATH_SEPARATOR$PATH])
 
@@ -398,7 +405,12 @@ fi
 AC_SUBST(cs_python)
 
 PYTHON=${PYEXE}
-AM_PATH_PYTHON([2.3])
+if test "x$have_gui" = xyes; then
+  cs_python_version="2.4"
+else
+  cs_python_version="2.3"
+fi
+AM_PATH_PYTHON([$cs_python_version])
 
 #------------------------------------------------------------------------------
 # Checks for PyQt support.
@@ -453,8 +465,8 @@ sys.stdout.write(path)]"
     PYPATH=${PYQT4_EXE}
   fi
 
-  AC_PATH_PROG([PYUIC4], [pyuic4], ["no"], [${PYPATH}])
-  AC_PATH_PROG([PYRCC4], [pyrcc4], ["no"], [${PYPATH}])
+  AC_PATH_PROG([PYUIC4], [pyuic4], ["no"], [${PYPATH}:$PATH])
+  AC_PATH_PROG([PYRCC4], [pyrcc4], ["no"], [${PYPATH}:$PATH])
 
   if test "x$PYUIC4" == "xno" -o "x$PYRCC4" == "xno" ; then
     AC_MSG_FAILURE([cannot find PyQt4 dev tools, Graphical User Interface cannot be installed])
@@ -471,6 +483,7 @@ AM_CONDITIONAL(HAVE_GUI, [test "x$have_gui" = "xyes"])
 
 AC_HEADER_STDC
 AC_CHECK_HEADERS([sys/types.h sys/utsname.h sys/stat.h stddef.h])
+AC_CHECK_HEADERS([sys/resource.h])
 
 #------------------------------------------------------------------------------
 # Checks for library functions.
diff --git a/cs_config.h.in b/cs_config.h.in
index 14045d4..2f27d23 100644
--- a/cs_config.h.in
+++ b/cs_config.h.in
@@ -109,6 +109,9 @@
 /* Define to 1 if you have the <string.h> header file. */
 #undef HAVE_STRING_H
 
+/* Define to 1 if you have the <sys/resource.h> header file. */
+#undef HAVE_SYS_RESOURCE_H
+
 /* Define to 1 if you have the <sys/stat.h> header file. */
 #undef HAVE_SYS_STAT_H
 
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 0d2218d..9aca94b 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -21,7 +21,7 @@
 #-------------------------------------------------------------------------------
 
 #SUBDIRS = developper howto install refcard theory tutorial user
-SUBDIRS = refcard theory tutorial user
+SUBDIRS = refcard theory tutorial user developper
 
 EXTRA_DIST = \
 style/csdoc.sty \
diff --git a/doc/Makefile.in b/doc/Makefile.in
index 26c088f..0957e49 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -70,15 +70,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -124,6 +135,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -147,6 +159,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -198,6 +211,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -254,6 +268,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -291,7 +306,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -322,7 +336,7 @@ top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 
 #SUBDIRS = developper howto install refcard theory tutorial user
-SUBDIRS = refcard theory tutorial user
+SUBDIRS = refcard theory tutorial user developper
 EXTRA_DIST = \
 style/csdoc.sty \
 style/csindex.sty \
diff --git a/doc/developper/Makefile.am b/doc/developper/Makefile.am
index 3b7d7df..b6dacf9 100644
--- a/doc/developper/Makefile.am
+++ b/doc/developper/Makefile.am
@@ -26,7 +26,8 @@ TEXMAIN = developper.tex
 
 # Other LaTex document
 
-TEXOTHERS =
+TEXOTHERS = \
+coding_standards.tex
 
 TEXINPUTFILES =
 
diff --git a/doc/developper/Makefile.in b/doc/developper/Makefile.in
index b74bacb..19d286f 100644
--- a/doc/developper/Makefile.in
+++ b/doc/developper/Makefile.in
@@ -72,15 +72,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -126,6 +137,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -149,6 +161,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -200,6 +213,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -256,6 +270,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -293,7 +308,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -325,7 +339,9 @@ top_srcdir = @top_srcdir@
 TEXMAIN = developper.tex
 
 # Other LaTex document
-TEXOTHERS = 
+TEXOTHERS = \
+coding_standards.tex
+
 TEXINPUTFILES = 
 
 # Distributed files
diff --git a/doc/developper/coding_standards.tex b/doc/developper/coding_standards.tex
new file mode 100644
index 0000000..11e7072
--- /dev/null
+++ b/doc/developper/coding_standards.tex
@@ -0,0 +1,340 @@
+%
+%     This file is part of the Code_Saturne CFD tool.
+%
+%     Copyright (C) 1998-2010 EDF S.A., France
+%
+%     contact: saturne-support at edf.fr
+%
+%     The Code_Saturne Preprocessor is free software; you can redistribute it
+%     and/or modify it under the terms of the GNU General Public License
+%     as published by the Free Software Foundation; either version 2 of
+%     the License, or (at your option) any later version.
+%
+%     The Code_Saturne Preprocessor 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 General Public License for more details.
+%
+%     You should have received a copy of the GNU General Public License
+%     along with the Code_Saturne Preprocessor; if not, write to the
+%     Free Software Foundation, Inc.,
+%     51 Franklin St, Fifth Floor,
+%     Boston, MA  02110-1301  USA
+%
+
+
+\section{Coding style guidelines}
+
+\subsection{Master rule}
+
+Keep the style consistent !
+
+This rule should be observed above all others. The coding style in \CS
+has evolved over the years, but unless you are ready to update a whole
+file to a more current style (in which case the other guidelines should be
+followed), try to remain consistent with the style in the current file.
+
+\subsection{C coding style}
+
+\subsubsection{Punctuation}
+
+Except when adding additional white space to align similar definitions
+or arguments on several lines, standard English punctuation rules should be
+followed:
+
+\begin{itemize}
+\item no white space before a punctuation mark (, ; . ), one white space
+      after a punctuation mark.
+
+\item white space before an opening parenthesis, no white space after an opening
+      parenthesis.
+
+\item no white space before a closing parenthesis, white-space after a closing
+      parenthesis.
+\end{itemize}
+
+\subsubsection{General rules}
+
+The following presentation rules are strongly recommended:
+\begin{itemize}
+\item indentation step: 2 characters (4 characters in \texttt{cs\_gui\_*}
+      files). When saving files, use spaces, not tabs. Most importantly,
+      use a decent text editor that does not randomly mix spaces and
+      tabs. \CS has a \texttt{sbin/rmb} script which removes trailing
+      white-space and replaces tabs with spaces, but this may appear to damage
+      indentation when it was defined with an odd mix of spaces and tabs.
+\item 80 characters maximum line length; split lines longer than this
+      to ensure readability on small screens, or when viewing code side-by-side
+      on wider screens.
+\item always use lowercase characters for instructions and identifiers,
+      except for enumerations and macros which should be in uppercase.
+\end{itemize}
+
+The following coding rules are strongly recommended:
+
+\begin{itemize}
+
+\item header (\texttt{.h}) files should have a mechanism to prevent
+  multiple inclusions;
+
+\item all macro parameters must be enclosed inside parentheses;
+
+\item a function's return type must always be defined.
+
+\item variables should be initialized before use
+  (pointers are set to NULL). A good compiler should issue warnings when
+  this is not the case, and those warnings must be acted upon;
+
+\item when a structure definition is only needed in a single file,
+  it is preferred to define it directly in the C source file,
+  so as to make as little visible as possible in the matching header file.
+  structures only used through pointers may be made opaque in this
+  manner, which ensures that their possible future modification should
+  not have unexpected side-effects.
+
+\item When a public function is defined in a C source file, a matching
+  header file containing its prototype must be included.
+
+\item usage of global variables must be kept to a minimum, though such
+  variables may be useful to maintain state or references to mesh or
+  variable structures in C code callable by Fortran code.
+  If a global variable is only needed inside a single file, it should
+  be declared ``static''. It it is needed in other files, then it must
+  instead  be declared ``extern'' in the matching header file.
+
+\item a \texttt{const} type must not be cast into a non-\texttt{const}
+  type;
+
+\item every \texttt{switch} construct should have a \texttt{default}
+  clause (which may reduce to \texttt{assert(0) to check code paths in
+  debug mode, but at least this much must be ensured);}
+
+\item a \texttt{const} attribute should be used when an array or structure
+  is not  modified. Recall that for example \texttt{const cs\_mesh\_t *m}
+  means that the contents of mesh structure \texttt{m} are not modified
+  by the function, while \texttt{cs\_mesh\_t *const m} only means that
+  the pointer to \texttt{m} is not modified;
+  \texttt{const cs\_mesh\_t *const m} means both, but its usage in
+  a function prototype gives no additional useful information on
+  the function's side effects than the first form
+  (\texttt{const cs\_mesh\_t *m}), so that form is preferred, as it
+  does not clutter the code;
+
+\item when an array is passed to a function, describing it as
+  \texttt{array[]} is preferred to \texttt{*array}, as the array
+  nature of the argument is better conveyed.
+
+\item where both a macro or an enumerated constant could be used,
+  an enumeration is preferred, as values will appear with the
+  enumerated value's name under a debugger, while only a macro's
+  expanded value will appear. An additional advantage of enumerated
+  values is that a compiler may issue a warning when a \texttt{switch}
+  construct has no \texttt{case} for a given enumeration value.
+\end{itemize}
+
+\subsubsection{Language\label{sec:regle.lang}}
+
+ANSI C 1989 is assumed, so C99-specific constructs should be
+avoided (especially C++-style comments and variable declarations
+mixed with source code). An exception is the use of \texttt{long long},
+which is available in all C89 compilers tested, and which is needed
+in some places.
+
+Also, the build mechanism ensure that when some usual C99 types
+or keywords are not available, macros are available to simulate
+their use, so \texttt{restrict}, \texttt{\_Bool}, \texttt{int32\_t},
+and \texttt{int64\_t} can and should be used.
+
+\subsubsection{Assertions}
+
+Assertions are conditions which must always be verified. Several
+expanded macro libraries may be available, but a standard C language
+assertion has the following properties:
+
+\begin{itemize}
+
+\item it is only compiled in debug mode (and so incur no run-time
+  performance penalty in production code, where the \texttt{NDEBUG}
+  macro is defined);
+
+\item when its predicate are not verified, it causes a core dump;
+  when running under a debugger, the code is stopped inside the
+  assertion, but does not exit, which simplifies debugging.
+
+\end{itemize}
+
+Assertions are thus very useful to ensure that conditions
+which are always expected (and not dependent on program input)
+are met. They also make code more readable, in the sense that
+it is made clear that conditions checked by an assertion
+are always expected, and that not handling other cases is not an
+programming error or omission.
+
+If a condition may not be met for some program inputs,
+and not just in case of programmer error, a more complete
+test and call to an error handler (such as \texttt{bft\_error})
+is preferred.
+
+\subsection{Naming conventions}
+
+The following rules should be followed:
+
+\begin{itemize}
+
+\item identifier lengths should not exceed 31~characters (ANSI C89);
+
+\item identifier names are in lowercase, except for macro or enumeration
+  definitions, which are in uppercase; words in an identifier are
+  separated by an underscore character (for example,
+  \verb=n_elt_groups_=).
+
+\item global identifier names are prefixed by the matching library prefix,
+  such as \verb=cs_= or \verb=BFT_=;
+
+\item local identifiers should be prefixed by an underscore character.
+
+\item Index arrays used with $0$ to $n-1$ numbering should be named
+  using a \verb=idx_= or \verb=index_= prefix or suffix, while
+  similar arrays using a $0$ to $n-1$ numbering (usually those that may be
+  also used in Fortran code) should be named using a \verb=pos_= 
+  prefix or suffix.
+
+\end{itemize}
+
+\subsubsection{Naming of enumerations}
+
+The following form is preferred for enumerations:
+
+\begin{quote}
+\begin{alltt}
+typedef myclass \{ CS_MYCLASS_ENUM1,
+                   CS_MYCLASS_ENUM2,
+                \( /* etc. */ \)
+                \} cs_myclass_t;
+\end{alltt}
+\end{quote}
+
+\subsubsection{Naming of structures and associated functions}
+
+Macros and enumerations related to myclass structures
+are prefixed by \verb=CS_MYCLASS_=.
+
+Public functions implementing methods are named
+ \texttt{cs\_\textit{class\_method}}, while private functions are simply named:
+\texttt{\_\textit{class\_method}} and are declared static.
+
+Files containing these functions are named \texttt{\_\textit{class}.c}.
+
+\subsubsection{Integer types}
+
+Several integer types are found in \CS:
+
+\begin{itemize}
+\item \texttt{fvm\_lnum\_t} should be used for local entity (i.e. vertex, face,
+      cell) numbers or connectivity. It is a signed integer, normally identical
+      to \texttt{int}, but a larger size could be used in the future for very
+      large meshes on shared memory machines.
+
+\item \texttt{fvm\_gnum\_t} should be used for global entity numbers, usually
+      necessary only for I/O aspects. It is an unsigned 32 or 64-bit integer,
+      depending on whether the code was configured with the
+      \texttt{--enable-long-gnum} option. Global numbers should always use
+      this type, as for very large meshes, they may exceed the maximum size
+      of a 32-bit integer (2~147~483~648). The choice of unsigned integers
+      is two-fold: it doubles the range of available values, and good compilers
+      will issue warnings when this type is mixed without precaution with
+      the usual integer types. These warnings should be heeded, as they may
+      avoid many hours of debugging.
+
+\item \texttt{cs\_int\_t} should be used for integer variables or arrays passed
+      between C and Fortran, though using \texttt{integer(kind)} statements
+      in Fortran should be a better future solution. In practice,
+      \texttt{cs\_int\_t} and \texttt{fvm\_lnum\_t} are identical. The former
+      is more commonly found in older code, but the latter should be used where
+      applicable for better clarity.
+
+\item in all other cases, the standard C types \texttt{int} and \texttt{size\_t}
+      should be preferred (for example for loops over variables, probes, or
+      any entity independent of mesh size.
+\end{itemize}
+
+\subsection{Base functions and types}
+
+In the \CS kernel, it is preferable to use base functions provided by the
+BFT subsystem to the usual C functions, as those logging, exit and error-handling
+functions will work correctly when running in parallel, and the memory
+management macros ensure return value checking and allow additional logging.
+
+The array below summarizes the replacements for usual functions:
+
+\begin{center}
+\begin{tabular}{|l|l|l|l|}
+\hline
+\multicolumn{1}{|c}{C function}  & \multicolumn{1}{|c}{\CS macro or function} & \multicolumn{1}{|c|}{Header}\\
+\hline
+\verb=exit()=    & \verb=cs_exit()=         & \verb=cs_base.h=\\
+                  & \verb=bft_error()=       & \verb=bft_error.h=\\
+\verb=printf()=  & \verb=bft_printf()=      & \verb=bft_printf.h=\\
+\verb=malloc(=   & \verb=BFT_MALLOC()=      & \verb=bft_mem.h=\\
+\verb=realloc()=& \verb=BFT_REALLOC()=     & \verb=bft_mem.h=\\
+\verb=free()=   & \verb=BFT_FREE()=         & \verb=bft_mem.h=\\
+\hline
+\end{tabular}
+\end{center}
+
+\subsection{Internationalization}
+
+Internationalization of messages uses the \texttt{gettext()} mechanism.
+Messages should always be defined in US English in the source
+code (which avoids using extended characters and the accompanying
+text encoding issues in source code), and a French translation
+is defined and maintained using a translation file \texttt{po/fr.po}.
+Translations to other languages are of course possible, and only
+require a volunteer.
+
+Using the \texttt{gettext()} mechanism has several advantages:
+
+\begin{itemize}
+
+\item accented or otherwise extended characters appear normally whether
+  using a Latin-1 (or Latin-9 or Latin-15) environment or whether
+  using a ``Unicode'' (or generally UTF-8) environment (assuming
+  that a terminal's encoding matches that of the {\tt LANG} environment
+  variable, usually {\tt LANG=fr\_FR} or {\tt LANG=fr\_FR.UTF-8}
+  for French;
+
+\item if a message is not translated, it simply appears in its
+  untranslated version;
+
+\item maintenance of the translations only requires editing a single
+  file, gettext related tools also make it easy to check that
+  translations are consistent (i.e. matching format descriptors
+  or line returns) without requiring complete code coverage tests.
+  In fact, translations could be maintained by a non-programmer.
+
+\item internationalization may be disabled using the
+ {\tt --disable-nls} configure option, so possible comfort vs. speed
+ trade-offs may be decided by the user;
+
+\end{itemize}
+
+To make internationalization possible, translatable strings should be
+encased in a {\tt\_( )} macro (actually an abbreviation for a call
+to {\tt gettext()} if available, which reverts to an empty (identity)
+macro is internationalization is unavailable or disabled).
+Strings assigned to variables must be encased in a {\tt N\_( )}
+macro (which is an ``empty'' macro, used by the {\tt gettext} toolchain
+to determine that those strings should appear in the translation dictionary),
+and the variable to which such a string is assigned should be
+encased in the {\tt\_( )} macro where used.
+
+Note that with UTF-8 type character strings, accented or otherwise
+extended characters are represented on multiple bytes. The {\tt strlen()}
+C function will return the string's real size, which may be greater
+than the number of output columns it uses. In the preprocessor, the
+{\tt ecs\_print\_padded\_str()} may be used to print such a string
+and padding it with the correct number of white spaces so as to meet
+a given format width. No such function is used or currently needed in the
+main code, though it could be added if needed.
+
+
diff --git a/doc/developper/developper.tex b/doc/developper/developper.tex
index 8a90590..dca7f93 100644
--- a/doc/developper/developper.tex
+++ b/doc/developper/developper.tex
@@ -81,6 +81,7 @@ contents}{contents}}
 \tableofcontents
 \end{singlespace}\end{center}
 %
+\include{coding_standards}
 %
 \end{document}
 %
diff --git a/doc/developper/graphics/Makefile.in b/doc/developper/graphics/Makefile.in
index 1824a68..92926c2 100644
--- a/doc/developper/graphics/Makefile.in
+++ b/doc/developper/graphics/Makefile.in
@@ -72,20 +72,32 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -109,6 +121,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -160,6 +173,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -216,6 +230,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -253,7 +268,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/howto/Makefile.in b/doc/howto/Makefile.in
index 947f429..39a163f 100644
--- a/doc/howto/Makefile.in
+++ b/doc/howto/Makefile.in
@@ -72,15 +72,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -126,6 +137,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -149,6 +161,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -200,6 +213,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -256,6 +270,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -293,7 +308,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/howto/graphics/Makefile.in b/doc/howto/graphics/Makefile.in
index 8d2cb1a..b480552 100644
--- a/doc/howto/graphics/Makefile.in
+++ b/doc/howto/graphics/Makefile.in
@@ -72,20 +72,32 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -109,6 +121,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -160,6 +173,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -216,6 +230,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -253,7 +268,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/install/Makefile.in b/doc/install/Makefile.in
index 14c561e..027aaa5 100644
--- a/doc/install/Makefile.in
+++ b/doc/install/Makefile.in
@@ -72,20 +72,32 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -109,6 +121,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -160,6 +173,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -216,6 +230,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -253,7 +268,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/refcard/Makefile.in b/doc/refcard/Makefile.in
index c60fc78..bccf937 100644
--- a/doc/refcard/Makefile.in
+++ b/doc/refcard/Makefile.in
@@ -72,15 +72,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -126,6 +137,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -149,6 +161,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -200,6 +213,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -256,6 +270,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -293,7 +308,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/refcard/graphics/Makefile.in b/doc/refcard/graphics/Makefile.in
index 0da9298..fb15b09 100644
--- a/doc/refcard/graphics/Makefile.in
+++ b/doc/refcard/graphics/Makefile.in
@@ -72,20 +72,32 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -109,6 +121,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -160,6 +173,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -216,6 +230,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -253,7 +268,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/style/csdoc.sty b/doc/style/csdoc.sty
index 75faa58..7794363 100644
--- a/doc/style/csdoc.sty
+++ b/doc/style/csdoc.sty
@@ -57,6 +57,7 @@
 \RequirePackage{fancyhdr}
 \RequirePackage{lastpage}
 \RequirePackage{ifthen}
+\RequirePackage{alltt}
 
 \RequirePackage[latin1]{inputenc}
 \RequirePackage[OT1]{fontenc} % \RequirePackage[T1]{fontenc} Attention: Liste des symboles
diff --git a/doc/theory/Makefile.in b/doc/theory/Makefile.in
index f4525bf..ecdc2b3 100644
--- a/doc/theory/Makefile.in
+++ b/doc/theory/Makefile.in
@@ -72,15 +72,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -126,6 +137,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -149,6 +161,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -200,6 +213,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -256,6 +270,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -293,7 +308,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/theory/bilsc2.tex b/doc/theory/bilsc2.tex
index b12e2bd..3a08c49 100644
--- a/doc/theory/bilsc2.tex
+++ b/doc/theory/bilsc2.tex
@@ -343,7 +343,7 @@ The coefficients $( A_{\,b,ik}, B_{\,b,ik} )_{k\in {\gamma_b(i)}}$ $\left(\ \tex
 {\gamma_b(i)}}\ \right)$ represent the boundary conditions associated with
 $a$ (resp. the diffusive fluxes \footnote { see 
 \var{clptur} for more details. The difference is actually only effective when the $k-\epsilon$ model is used, and for the velocity only.} of $a$).\\
-The above sum corresponds to the numerical operation::
+The above sum corresponds to the numerical operation:
 \begin{equation}\label{Base_Bilsc2_eq_flux_bord}
 \begin{array}{ll}
 \var{FLUX}& = \var{ICONVP} \,.\,[\ \var{FLUI}\,.\, \var{PVAR(II)} + \var{FLUJ}\,.\, \var{PFAC}\ ]\\
diff --git a/doc/theory/combbase.tex b/doc/theory/combbase.tex
index 4dbbb19..25bb6c8 100644
--- a/doc/theory/combbase.tex
+++ b/doc/theory/combbase.tex
@@ -1,5 +1,5 @@
 \programme{ Introduction}
-{\huge sub-routines : co**, cp**, fu** ...}
+{\huge sub-routines: co**, cp**, fu** ...}
 
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -8,8 +8,8 @@
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 From a CFD point of view combustion is a ({\small sometimes very})
-complicated way to determine $\rho$.\\ Models needs few extra fields
-of scalar with regular transport equations, some of them with a
+complicated way to determine $\rho$.\\ Models needs few extra scalar
+fields with regular transport equations, some of them with a
 reactive or interfacial source term.\\ Modelling of combustion is able
 to deal with gas phase combustion ({\small diffusion, premix, partial
 premix}), and with solid or liquid fuels.\\ Combustion of condensed
@@ -21,8 +21,8 @@ That is the reason why many modules are similar for gas, coal and fuel
 combustion modelling. Obviously, the thermodynamical description of
 gas species is similar in every version as close as possible to the
 JANAF rules.\\ All models are developped in both adiabatic and
-unadiabatic ({\small permeatic : heat loss, eg. by radiation})
-version, beyond the standard, the rule to call models is :
+unadiabatic ({\small permeatic: heat loss, eg. by radiation})
+version, beyond the standard, the rule to call models is:
 
 IPPMOD(index model)  =  -1     unused
 
@@ -59,7 +59,7 @@ realised ({\small without blast ...}) and the mixture is introduced in
 the boiler ({\small or combustor can}). In common industrial
 conditions the combustion is mainly limited by the mixing of fresh
 gases ({\small inert}) and burnt ones resulting in the inflammation of
-the first and their conversion to burnt ones ; so an assumption of
+the first and their conversion to burnt ones; so an assumption of
 chemistry much faster than mixing induces an intermittent regime. The
 gas flow is constituted of totally fresh and totally burnt gases
 ({\small the flamme containing the gases during their transformation
@@ -102,24 +102,24 @@ of different sizes. After its introduction in the boiler, coal
 particles undergoes drying, devolatilisation ({\small heating of coal
 turn it in a mixture of char and gases}), heterogenous combustion
 ({\small of char in carbon monoxide}) leaving ash particles.\\ Each of
-these phenomena are taken into account for some class of particles : a
+these phenomena are taken into account for some class of particles: a
 class is caracterised by a coal ({\small it is useful to burn mixture
 of coals with differents ranks or mixture of coal with biomasse ...})
 and an initial diameter. For each class, \CS computes the number and
 the mass of particles by unit mass of mixture.\\ The main assumption
-is to solve only one velocity ({\small and pressure}) field : it means
+is to solve only one velocity ({\small and pressure}) field: it means
 the discrepancy of velocity between coal particles and gases is
 assumed negligible.\\ Due to the radiation and heterogeneous
 combustion, temperature can be different for gas and different size
-particles : so the specific enthalpy of each particle class is
+particles: so the specific enthalpy of each particle class is
 solved.\\ The description of coal pyrolysis proposed by Kobayashi \&
 Ubhayakar \cite{4} is used, leading to two source terms for light and
 heavy volatile matters ({\small the moderate temperature reaction
 produces gases with low molecular mass, the high temperature reaction
 produces heavier gases and less char}) represented by two passive
-scalars : mixture fractions.  The description of the heterogeneous
+scalars: mixture fractions.  The description of the heterogeneous
 reaction ({\small which produce carbon monoxide}) produces a source
-term for the carbon : a mixture fraction who can't be greater than the
+term for the carbon: a mixture fraction who can't be greater than the
 results of stoechiometric oxidation of char by air ({\small carbon
 can't be free in gas phase, it is always linked in an oxide}).\\ The
 retained model for the gas phase combustion is the assumption of
@@ -142,12 +142,12 @@ energy. Environmental regulation turning it more difficult and less
 acceptable, a focus is needed on pollutant emission mainly sulphur
 oxide and particles ({\small condensation of sulphuric acid can
 aggregate soot}).\\ The description of fuel evaporation is done with
-respect to its heaviness : after a minimum temperature is reached, the
+respect to its heaviness: after a minimum temperature is reached, the
 gain of enthalpy is splitted between heating and evaporation. This way
 the evaporation takes place on a range of temperature ({\small which
 can be large}). The "total" evaporation is common for light ({\small
-domestic}) oil but impossible for heavy ones : at high temperature,
-during the last evaporation, a crakink reaction appears : so a
+domestic}) oil but impossible for heavy ones: at high temperature,
+during the last evaporation, a crakink reaction appears: so a
 particle similar to char leaves. The heterogeneous oxydation of this
 char particle is very similar to coal char ones.\\ Fuel injection is
 described ({\small 2006 version}) with only one class of particles
@@ -179,8 +179,8 @@ to be converted to SO2 during gas combustion}).
 Combust. Sci. Technol., 161, pp. 351-390, (2000)
 
 \bibitem{3}
-{\sc Ribert, G. ; Champion, M. and Plion, P.},\\
-{\em Modeling turbulent reactive flows with variable equivalence ratio : application to the calculation of a reactive shear layer},\\
+{\sc Ribert, G.; Champion, M. and Plion, P.},\\
+{\em Modeling turbulent reactive flows with variable equivalence ratio: application to the calculation of a reactive shear layer},\\
 Combust. Sci. Technol., 176, pp. 907-923, (2004)
 
 \bibitem{4}
diff --git a/doc/theory/combfuel.tex b/doc/theory/combfuel.tex
index b1fe1d5..6bb90f4 100644
--- a/doc/theory/combfuel.tex
+++ b/doc/theory/combfuel.tex
@@ -12,37 +12,37 @@ the furnace, its temperature increases reaching an evaporating range
 point}):
 \begin{enumerate}
   \item As droplet's temperature reachs the begin of evaporating
-          range, vapour begins to be given off. Gazeous hydrocarbons
+          range, vapour begins to be given off. Gaseous hydrocarbons
           are then involved in a diffusion flame surrouding each
           droplet. The heavy fuel oil beeing constitued of long
           hydrocarbons molecules, cracking mays occur and char is
           leaved. So the complex chemistry inside the droplet is
-          summarized by : \\ Heavy fuel oil $\longrightarrow$ gazeous
+          summarized by: \\ Heavy fuel oil $\longrightarrow$ gaseous
           hydrocarbons + char
  
   \item After evaporation, when the whole vapour are burnt, oxygen is
   able to reach the surface of the char particle. So heterogenous
   combustion can take place. It is very similar to the oxydation of
-  coal char : diffusion of oxygen from bulk, heterogeneous reaction
+  coal char: diffusion of oxygen from bulk, heterogeneous reaction
   ({\small kinetically limited}) and back diffusion of carbone
   monoxide. The heterogenous combustion is achieved if all the carbon
   of the char particle is converted, leaving an ash particle ({\small
   heavy fuel oil can contain inerts, some of which beeing heavy
   metals}). Unburnt carbon can leave the boiler as flying
-  particle. The heterogeneous reaction is wrotten : \\
+  particle. The heterogeneous reaction is wrotten: \\
 \centerline{$Char + \frac{1}{2} 0_{2} =(k0het, T0het)=> CO$} 
 \end{enumerate}
 
 \vspace{0.5cm}
-\noindent{} Fuel jet combsution strongly depends on injection conditions and namely on mean diameter of drops (size distribution). In the first (2006) version \CS take in account only one diameter : monodisperse injection.
+\noindent{} Fuel jet combsution strongly depends on injection conditions and namely on mean diameter of drops (size distribution). In the first (2006) version \CS take in account only one diameter: monodisperse injection.
 
 
 \vspace{0.5cm}
 
-\noindent{} For heavy fuel oil, like for coal, the french reference [1] can be useful :
+\noindent{} For heavy fuel oil, like for coal, the french reference [1] can be useful:
  
 \noindent{\bf [1]} Escaich, Alain~: ``Mise en oeuvre dans Code\_Saturne des
-mod�lisations physiques particuli�res. Tome 2 : Combustion du charbon
+mod�lisations physiques particuli�res. Tome 2: Combustion du charbon
 pulv�ris�.'', HI-81/02/09/A, Rapport EDF, 2002.
 
 \newpage
@@ -82,7 +82,7 @@ $t$ 		& $s$ 		& time\\
 The bulk, done of gases and droplets, is assumed to be describable
 with only one pressure and velocity. The slipping velocitiy between
 droplets and gases is supposed negligible compared to this mean
-velocity.  Scalars for the bulk are :
+velocity.  Scalars for the bulk are:
 \vspace{0.5cm}
 \begin{itemize}
   \item Bulk density 
@@ -105,13 +105,13 @@ velocity.  Scalars for the bulk are :
      \end{equation} 
 \end{itemize}  
 
-Mass fractions of gaseous medium ($Y_{1}^{*}$) and of droplets are defined by :
+Mass fractions of gaseous medium ($Y_{1}^{*}$) and of droplets are defined by:
 \begin{eqnarray}
   Y_{1}^{*} = \frac{\alpha_{1}\rho_{1}}{\rho_{m}} &\\
   Y_{2}^{*} = \frac{\alpha_{2}\rho_{2}}{\rho_{m}} &
 \end{eqnarray}
 
-So budget equations for the bulk can be written :
+So budget equations for the bulk can be written:
 
 \begin{equation}
   \frac{\partial}{\partial t    } \rho_{m}
@@ -138,7 +138,7 @@ So budget equations for the bulk can be written :
                +S_{m,R}
 \end{equation}
  
-With the ({\small velocity}) homogeneity assumption, mainly budget equation for bulk caracteristic  are pertinent. So transport equation for the scalar $\Phi_{k}$, where k is the phase, can be written :
+With the ({\small velocity}) homogeneity assumption, mainly budget equation for bulk caracteristic  are pertinent. So transport equation for the scalar $\Phi_{k}$, where k is the phase, can be written:
 
 \begin{equation}
   \frac{\partial}{\partial t    } (\rho_{m} Y_{k}^{*}\Phi_{k})
@@ -152,21 +152,21 @@ With the ({\small velocity}) homogeneity assumption, mainly budget equation for
 \subsection{Fuel combustion scalars}
 %=================================
 
-\subsubsection{Bulk enthalpy : $H_{m}$ }
+\subsubsection{Bulk enthalpy: $H_{m}$ }
 Budget equation for the specific enthalpy of the mixture ({\small gas
 + droplets}) admits only one source term for radiative effects
-$S_{m,R}$ :
+$S_{m,R}$:
 \begin{equation}
     S_{m,R}= S_{1,R}+ S_{2,R}
 \end{equation}
 With contributions of each phases liable to be described by different
-models ({\small eg : wide band for gases, black body for particles}).
+models ({\small eg: wide band for gases, black body for particles}).
 
-\subsubsection{Droplets enthalpy : $Y_{2}^{*}H_{2}$ }
+\subsubsection{Droplets enthalpy: $Y_{2}^{*}H_{2}$ }
 Enthalpy of droplets ({\small J in droplets/kg bulk}) is the product
 of liquid phase mass fraction ({\small kg liq/kg bulk}) by the
 specific enthalpy of liquid ({\small kg liq/kg bulk}). So the budget
-equation for liquid enthalpy has four source terms : :
+equation for liquid enthalpy has four source terms:
 \begin{equation}
      \Pi_{2}^{'}+S_{2,R}-\Gamma_{evap}H_{vap}(T_{2})
                         +\Gamma_{het}\left( \frac{M_{O}}{M_{C}}H_{O_{2}}(T_{1})
@@ -174,14 +174,14 @@ equation for liquid enthalpy has four source terms : :
 \end{equation}
 with
 \begin{itemize}
-  \item $\Pi_{2}^{'}$ : heat flux between phases
-  \item $S_{2,R}$ : radiative source term for droplets
+  \item $\Pi_{2}^{'}$: heat flux between phases
+  \item $S_{2,R}$: radiative source term for droplets
   \item $\Gamma_{evap}H_{vap}(T_{2})$ the vapor flux leaves at droplet temperature ($H_{vap}$ includes latent heat)
-   \item $\Gamma_{het}(...)$ heterogenous combustion induces reciprocal mass flux : oxygen arriving at gas temperature and carbone monoxide leaving at char particle one.
+   \item $\Gamma_{het}(...)$ heterogenous combustion induces reciprocal mass flux: oxygen arriving at gas temperature and carbone monoxide leaving at char particle one.
 
 \end{itemize}
     
-\subsubsection{Dispersed phase mass fraction : $Y_{2}^{*}$}
+\subsubsection{Dispersed phase mass fraction: $Y_{2}^{*}$}
 In budget equation for the mass fraction of the dispersed phase
 ({\small first droplets, then char particles, at last ashes}) the
 source terms are interfacial mass fluxes ({\small first evaporation,
@@ -191,24 +191,24 @@ then net flux for heterogeneous combustion}):
      -\Gamma_{evap}-\Gamma_{het}
 \end{equation}
           
-\subsubsection{Number of droplets : $N_{p}^{*}$}
-No source term in the budget equation for number of droplets : a
+\subsubsection{Number of droplets: $N_{p}^{*}$}
+No source term in the budget equation for number of droplets: a
 droplet became a particle ({\small eventually a tiny flying ash}) but
 never vanish ({\small particles it have to get out}).
 
                                 
-\subsubsection{Mean of the passive scalar for fuel vapor : $F_{1}$}  
+\subsubsection{Mean of the passive scalar for fuel vapor: $F_{1}$}  
 This scalar represent the amount of matter which have leaved the
 particle as fuel vapour, whatever it happens after. It's a mass
 fraction of gaseous matter ({\small in hydrocarbon form or carbon
 oxide ones}). So the source term in its budget is only evaporation
-mass flux :
+mass flux:
 \begin{equation}
    \Gamma_{evap}
 \end{equation}     
 
-\subsubsection{ Variance of $F_{1}$ : $F_{1}^{'2}$}
-Budget equation for $F_{1}^{'2}$ have three source term :
+\subsubsection{ Variance of $F_{1}$: $F_{1}^{'2}$}
+Budget equation for $F_{1}^{'2}$ have three source term:
 \begin{equation}
    \Gamma_{F_{1}^{'2}}
    -2\rho_{m}Y_{1}^{*}\frac{F_{1}^{'2}}{\tau_{\chi_{F_{1}^{'2}}}} 
@@ -218,17 +218,17 @@ Budget equation for $F_{1}^{'2}$ have three source term :
 where $\Gamma_{F_{1}^{'2}}$ is due to interfacial mass fluxes ({\small
 every interfacial mass fluxes impact gaseous phase variances}).
                                                  
-\subsubsection{Mean of the passive scalar for carbon from char : $F_{3}$}  
+\subsubsection{Mean of the passive scalar for carbon from char: $F_{3}$}  
 Budget equation for $F_{3}$ have for lone source term the mass flux
 due to heterogeneous combsution ({\small mass flux of carbon monoxide
 minus oxygene mass flux}). As for $F_{1}$ oxidation in the gaseous
-phase does not modifiy this {\em passive} scalar :
+phase does not modifiy this {\em passive} scalar:
 \begin{equation}
    \Gamma_{het}
 \end{equation}   
          
                        
-\subsubsection{ Variance of the passive scalar for air : $F_{4}^{'2}$} 
+\subsubsection{ Variance of the passive scalar for air: $F_{4}^{'2}$} 
  
 This passive scalar incomes with air but is'nt destroyed by any
 ({\small in gaseous phase or heterogeneous}). No budget equation
@@ -236,7 +236,7 @@ needed for it, $F_{4}$ can be determined from the wholeness
 relation.\\
 
 Budget equation for $F_{4}^{'2}$ have, like other passive scalar
-variance budget equaiton, four source terms :
+variance budget equaiton, four source terms:
 \begin{equation} 
     \Gamma_{F_{4}^{'2}}
    -2\rho_{m}Y_{1}^{*}\frac{F_{4}^{'2}}{\tau_{\chi_{F_{4}^{'2}}}} 
@@ -258,6 +258,6 @@ every interfacial mass fluxes impact gaseous phase variances}).
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 The discretisation of equation are not problematic. Details are in
-sections : \fort{fuflux} (interfacial fluxes of mass and energy),
+sections: \fort{fuflux} (interfacial fluxes of mass and energy),
 \fort{futssc} (source term for fuel specific scalars)
 and \fort{fucym1} (gas phase combustion). 
diff --git a/doc/theory/combgaz.tex b/doc/theory/combgaz.tex
index 82cea5e..a631795 100644
--- a/doc/theory/combgaz.tex
+++ b/doc/theory/combgaz.tex
@@ -1,5 +1,5 @@
 \programme{ Gas combustion}
-{\huge subroutines : co** and d3p*, ebu*, lwc*, pdf*}
+{\huge subroutines: co** and d3p*, ebu*, lwc*, pdf*}
 
 Flames with gaseous fuels can be categorized in premix, diffusion or
 partial-premix.
@@ -7,7 +7,7 @@ partial-premix.
 
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\section{Premix : Eddy Break Up}
+\section{Premix: Eddy Break Up}
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
@@ -18,7 +18,7 @@ inlet}) ; the key-word of which is {\em"If it mixes, it burns"}.\\
 If the chemistry is fast, vs. mixing, fluid particles are made of
 fresh gases or of burned ones. This situation is described by a
 progress variable ({\small valued 0 in fresh gases and 1 in burnt
-ones}) with a source term : the reaction one. The mixture of totally
+ones}) with a source term: the reaction one. The mixture of totally
 fresh or totally burnt gases, called intermittency, leads to a maximal
 variance of the progress variable determined by the mean value of the
 progress variable.\\
@@ -33,7 +33,7 @@ ones. So the source term for the ({\small mean}) progress variable is
 the dissipation of its ({\small algebraic}) variance.\\
 
 In \CS the progress variable chosen is the mass fraction of fresh
-gases, so :\\
+gases, so:\\
 \begin{equation}
 S(Ygf) = - Cebu . \rho . \frac{\epsilon}{k} . Ygf . (1-Ygf)
 \end{equation}
@@ -46,10 +46,10 @@ Some improvements have been proposed, and largely used, for situations
 with mixture fraction gradient ({\small staggering of reactant(s)})
 but are not theorically funded. The simplest extension is available
 ({\small options 2 and 3 }) in \CS with one extra equation solved for
-f the mean of mixture fraction : the corresponding hypothesis is "no
+f the mean of mixture fraction: the corresponding hypothesis is "no
 variance for mixture fraction" ... a little bit surprising in an EBU
 context ({\small maximal variance for progress variable}). The choice
-of the fresh gas mass fraction appears now quite pertinent : the
+of the fresh gas mass fraction appears now quite pertinent: the
 computation of species mass fraction can be done, with respect to the
 mean mixture fraction, both in fresh ({\small the mass fraction of
 which is Ygf}) and burnt gases ({\small the mass fraction of which is
@@ -92,7 +92,7 @@ or a constant value ({\small in regular EBU model}).
 
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\section{Diffusion : PDF with 3 points chemistry}
+\section{Diffusion: PDF with 3 points chemistry}
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
@@ -100,11 +100,11 @@ In diffusion model, the combustion is supposed limited only by mixing
 ({\small between air and fuel}), so the reaction is assumed to reach
 instantaneously its equilibrium state and the temperature and
 concentrations can be computed for every value of the mixture
-fraction. In \CS the implemented version uses an extra hypothesis :
+fraction. In \CS the implemented version uses an extra hypothesis:
 the reaction is complete ; so if the mixture is stoechiometric, the
 burnt gases contains only final products ({\small none unburnt like
 CO...}). As a consequence, every concentration is a piecewise linear
-function of the mixture fraction (subroutines : \fort{D3PPHY, D3PINT,
+function of the mixture fraction (subroutines: \fort{D3PPHY, D3PINT,
 CPCYM,FUCYM}) .\\
 \begin{equation}
 0<f<fs => Yi(f) = Yair + \frac{f}{fs} . (Ys-Yair)
@@ -117,10 +117,10 @@ fs<f<1 => Yi(f) = Ys + \frac{f-fs}{1-fs} . (Yfuel-Ys)
 \caption{mass fraction of global species are piecewise linear with mixture fraction}
 \end{figure}
 Where fs is the stoechiometric mixture fraction, Yair and Yfuel are
-concentrations in ({\small supposed unable to react : inert}) initial
+concentrations in ({\small supposed unable to react: inert}) initial
 reactant, Ys concentrations in products of the complete reaction of a
 stoechiometric mixture ({\small in such products, the chemical
-reaction is no more possible : inert}).\\
+reaction is no more possible: inert}).\\
 
 The diffusion model uses two equations for the mixture fraction and
 its variance both of them having no reaction term. The mean and the
@@ -132,13 +132,13 @@ by Borghi \cite{4} with a rectangle and Dirac's peak is used
 \begin{figure}[h]
 %\centerline{\includegraphics[height=4cm]{../Comb/Cogz/Images/Pf.pdf}}
 %\centerline{\includegraphics[height=2.5cm]{../Comb/Cogz/Images/Pf2.pdf}}
-\caption{Examples of presumed PDF : cheapest form}
+\caption{Examples of presumed PDF: cheapest form}
 \end{figure}
 The determination of mean concentration is done by integration the
 local concentration weighted by the probability density function. As a
 matter of fact, integrate the product of a piecewise linear function
 by a constant ({\small height of the rectangle}) is a very simple
-exercise : analytic solution are available ({\small the original
+exercise: analytic solution are available ({\small the original
 Borghi formulation \cite{3} wich uses $\beta$ function was much more
 computationaly expensive}).
 
@@ -164,7 +164,7 @@ be computed.
 
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\section{Partial premix : Libby Williams models}
+\section{Partial premix: Libby Williams models}
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
@@ -174,7 +174,7 @@ be computed.
 The Libby \& Williams model have been developped to address the
 description of the combustor can of gas turbine in regime allowing a
 reduction of NOx production using ({\small sometimes very}) lean
-premix : by this way, the combustion occurs at moderate temperatures
+premix: by this way, the combustion occurs at moderate temperatures
 avoiding the hot spots which are favourable to thermal NOx
 production. As a consequence of the moderate temperatures, the
 chemistry is no more so fast and the stability is questionnable. To
@@ -199,23 +199,23 @@ chemistry description is used ({\small source term for every variables
 is a weighting of the reaction fluxes}).\\ With two peaks
 distribution, the two-variable PDF is restricted to one line, crossing
 the mean state and the slope of which is the ratio of variances
-({\small chose of the sign is user free, ... but relevant : expertise
+({\small chose of the sign is user free, ... but relevant: expertise
 is needed}). The correlation between variables is unity.\\ On this
 line the distribution is supposed to obey a modified Curl
 model \cite{7}.\\
 \begin{figure}[h]
 %\centerline{\includegraphics[height=5cm]{../Comb/Cogz/Images/LW2.pdf}}
-\caption{PDF recommended by Libby \& Williams : still undetermined}
+\caption{PDF recommended by Libby \& Williams: still undetermined}
 \end{figure}
 With three or four peaks distribution, the whole concentration space
 is available and the determination of the covariance allows evolution
 of the correlation ({\small with f and Yf, it have been shown that the
 correlation is positive in mixing layer and can become negative across
-flame : the particle nearer of stoechiometry being able to burn -then
+flame: the particle nearer of stoechiometry being able to burn -then
 destroy Yf- faster than poor ones}). \\
 \begin{figure}[h]
 %\centerline{\includegraphics[height=5cm]{../Comb/Cogz/Images/LW4.pdf}}
-\caption{PDF form in LWP approach : succesive modified Curl distributions}
+\caption{PDF form in LWP approach: succesive modified Curl distributions}
 \end{figure}
 In adiabatic conditions, the temperature can be computed for every
 pair (f,Yfuel), allowing the determination of the kinetic constant.\\
@@ -259,7 +259,7 @@ Comb. Sci. Technol., 161 , pp. 351-390, (2000).
 
 \bibitem{5}
 {\sc Ribert, G. {\em et al.}},\\
-{\em Modeling turbulent reactive flows with variable equivalence ratio : application to the calculation of a reactive shear layer},\\
+{\em Modeling turbulent reactive flows with variable equivalence ratio: application to the calculation of a reactive shear layer},\\
 Comb. Sci. Technol., 176 , pp. 907-923, (2004).
 
 \bibitem{6}
@@ -269,7 +269,7 @@ ICDERS, (2005) to be published.
 
 \bibitem{7}
 {\sc Curl, R.L.},\\
-{\em Dispersed phase mixing : theory and effects in simple reactors},\\
+{\em Dispersed phase mixing: theory and effects in simple reactors},\\
 AIChE J., 9 , pp. 175-181 (1963).
 
 
@@ -301,7 +301,7 @@ vaporisation, or pyrolysis, and heterogeneous combustion two or three
 gaseous fuels are taken in account, each of them having its own inert
 scalar, so the PDF is build for an inert scalar incoming with air and
 ranging from a minimum value and one ; the minimum value for air
-tracker is due to heterogeneous combustion : some air is needed to
+tracker is due to heterogeneous combustion: some air is needed to
 allow heterogeneous combsution and carbon releasing ({\small as carbon
 monoxide}) ; after some heteregenous reaction took place, air is
 lacking for gas combustion ({\small at the bottom stone mile of the
@@ -318,12 +318,12 @@ the three pertinent parameters ({\small three conditions given by
 momenta $m_{0}=1, m_{1}=mean, m_{2}=mean^{2}+variance$}).\\
 
 - for a lonesome rectangle Dirac's peak intensity is null, the three
-  parameters are : the begin and end values of the rectangle and its
+  parameters are: the begin and end values of the rectangle and its
   heigth\\
 
 - for a rectangle with a Dirac's peak at one boundary ({\small which
   is determined during the choose of shape}), one of the rectangle
-  hedge is fixed at this boundary, so the three parameters are : the
+  hedge is fixed at this boundary, so the three parameters are: the
   other rectangle hedge, height of rectangle, intensity of the Dirac's
   peak\\
 
@@ -350,7 +350,7 @@ With the above Probability Density Function and assumption of
 concentrations piecewise linear vs. the variable, it is quite easy to
 integrate and found the mean concentrations. For gas diffusion flame
 this is done by \fort{D3PPHY, D3PINT}, it seems more relevant to
-explain the algorithm in a more complicated case : for heavy fuel
+explain the algorithm in a more complicated case: for heavy fuel
 oil \fort{FYUCYM} or for coal \fort{CPCYM} three reactions are
 considered. \\
 
@@ -380,19 +380,19 @@ diffusion flammelet take place between this mixture and pure oxidiser
 ({\small but for solid particles introduced wet, when a first drying
 process releases water vapor which is mixed with air}) and the
 composition is described with respect to the inert scalar introduced
-with air : \fort{f4}.\\
+with air: \fort{f4}.\\
 
 For the description of compositions ({\small as piecewise linear
-functions}) the composition is computed in some remarkable points :
+functions}) the composition is computed in some remarkable points:
 the local mean fuel \fort{CL}, the oxidiser \fort{F4} and the three
 mixture ratio corresponding to the stoechiometry of the three
 successive reactions.\\ Before reaction between gases, only exist
-species coming from entries or interfacial source term :\\
+species coming from entries or interfacial source term:\\
 \begin{figure}[h]
 %\centerline{\includegraphics[height=6cm]{../Comb/Cogz/Images/YF0f.pdf}}
 \caption{Heavy Fuel Oil before any gas combustion} 
 \end{figure}
-{\centerline {\em Caution : axis for f4 is reverted, so fuel is on the
+{\centerline {\em Caution: axis for f4 is reverted, so fuel is on the
 right side like in a scheme with a mixture fraction direct axis}}}\\
 
 The oxygen and the hydrocarbon vapor have concentrations linear in f4
@@ -442,7 +442,7 @@ compute.\\
 \caption{Heavy Fuel Oil after final carbon oxidation}
 \end{figure}
 \\
-To have not any unburnt, the PDF may be zero valued for F4 $<$ F4s3 :
+To have not any unburnt, the PDF may be zero valued for F4 $<$ F4s3:
 every gas particle may have an F4 greater than F4s3.\\
 
 During pulverised coal combustion, two kinds of volatile matters are
@@ -451,7 +451,7 @@ successive reactions is quite similar.\\
 
 The first reaction is a partial dehydrogenation of the light volatile
 $CH_{x1}$ to form the species caracteristic of heavy volatile
-$CH_{x2}$ : in f4s1, all of $CH_{x1}$ ({\small issued from the low
+$CH_{x2}$: in f4s1, all of $CH_{x1}$ ({\small issued from the low
 temperature pyrolisis reaction}) is converted, and the $CH_{x2}$
 ({\small issued from the high temperature pyrolisis reaction}) is
 incremented.\\
@@ -468,22 +468,22 @@ is the same final oxidation of carbon monoxide to carbon dioxide.\\
 \\
 Comparisons of the PDF rectangle hedges [$f_{deb} , f_{fin}$] and
 remarkable composition points [CL, f4s1, f4s2, f4s3, F4] allows a
-simple integration : 1) Dirac's peak intensity are used to weight
+simple integration: 1) Dirac's peak intensity are used to weight
 composition at boundaries, 2) the piece linear part is integrated with
-analytical formulae on each band :\\
+analytical formulae on each band:\\
 \begin{enumerate}
-\item rich range, here exists species with the higher calorific value : $CH_{x}$ ({\small in fuel case}) or $CH_{x2}$ ({\small in coal case }) :\\  \centerline{[Max($f_{deb}$,CL) ; Min($f_{fin}$,f4s1)]}\\
-\item middle-class range $H_{2}S$ or $CH_{x1}$ conversion :\\
+\item rich range, here exists species with the higher calorific value: $CH_{x}$ ({\small in fuel case}) or $CH_{x2}$ ({\small in coal case }):\\  \centerline{[Max($f_{deb}$,CL) ; Min($f_{fin}$,f4s1)]}\\
+\item middle-class range $H_{2}S$ or $CH_{x1}$ conversion:\\
  \centerline{[Max($f_{deb}$ , f4s1 ); Min ($f_{fin}$ , f4s2 )]}\\
-\item working range, carbon monoxide consumption frees enthalpy :\\ \centerline{ [Max($f_{deb}$ ,f4s2 ); Min ($f_{fin}$ , f4s3 )]}\\
-\item poor range, only products and oxidisers :\\ \centerline{ [Max($f_{deb}$ , f4s3 ); Min ($f_{fin}$ , 1)]}\\
+\item working range, carbon monoxide consumption frees enthalpy:\\ \centerline{ [Max($f_{deb}$ ,f4s2 ); Min ($f_{fin}$ , f4s3 )]}\\
+\item poor range, only products and oxidisers:\\ \centerline{ [Max($f_{deb}$ , f4s3 ); Min ($f_{fin}$ , 1)]}\\
 \end{enumerate}
 
-For each band (eg. [f4si , f4sj]) concentrations can be written :\\
+For each band (eg. [f4si , f4sj]) concentrations can be written:\\
 \centerline{$Ye = Ye(f4si) + \frac{f4-f4si}{f4sj-f4si} . \left( Ye(f4sj)-Ye(f4si) \right) $}\\ 
 Integration on the band [b1 , b2] ({\small obviously b1$\geq$f4si \&
-b2$\leq$f4sj}) gives the increment :\\
-\centerline{$Ye := Ye + h_{rec}.(b2-b1) + \left[ \frac{Ye(f4si).f4sj-Ye(f4sj).f4si}{f4sj-f4si}+\frac{Ye(f4sj)-Ye(f4si)}{f4sj-f4si}.\frac{b1+b2}{2} \right] $}\\
+b2$\leq$f4sj}) gives the increment:\\
+\centerline{$Ye:= Ye + h_{rec}.(b2-b1) + \left[ \frac{Ye(f4si).f4sj-Ye(f4sj).f4si}{f4sj-f4si}+\frac{Ye(f4sj)-Ye(f4si)}{f4sj-f4si}.\frac{b1+b2}{2} \right] $}\\
 Where $h_{rec}$ is the height of the PDF's rectangle. 
 
  
diff --git a/doc/theory/graphics/Makefile.in b/doc/theory/graphics/Makefile.in
index 0007117..2bc7b85 100644
--- a/doc/theory/graphics/Makefile.in
+++ b/doc/theory/graphics/Makefile.in
@@ -72,20 +72,32 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -109,6 +121,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -160,6 +173,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -216,6 +230,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -253,7 +268,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/theory/thermo.tex b/doc/theory/thermo.tex
index bd75b86..7cfb32f 100644
--- a/doc/theory/thermo.tex
+++ b/doc/theory/thermo.tex
@@ -7,9 +7,21 @@
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-The description of the thermodynamical of gases mixture is as close as possible of the JANAF standard. The gases mixture is, often, considered as composed of some {\em global} species ({\small eg. oxidizer, products, fuel}) each of them beeing a mixture ({\small with known ratio}) of {\em elementary} species ({\small oxygen, nitrogen, carbon dioxide, ...}).\\
- A tabulation of the enthalpy of both elementary and global species for some temperatures is constructed ({\small using JANAF polynoms}) or read ({\small if the user found useful to define a global specie not simply related to elementary ones ; eg. unspecified hydrocarbon known by C, H, O, N, S analysis and heating value.}).\\ 
-The thermodynamic properties of condensed phase are more simple : formation enthalpy is computed using properties of gaseous products of combustion with air ({\small formation enthalpy of wich is zero valued as O2 and N2 are reference state}) and the lower heating value. The heat capacity of condensed phase is assumed constant and it is a data the user have to type ({\small in the corresponding data file dp\_FCP or dp\_FUE}).
+The description of the thermodynamical of gases mixture is as close as possible
+of the JANAF standard. The gases mixture is, often, considered as composed of
+some {\em global} species ({\small eg. oxidizer, products, fuel}) each of them
+beeing a mixture ({\small with known ratio}) of {\em elementary} species
+({\small oxygen, nitrogen, carbon dioxide, ...}).\\ A tabulation of the enthalpy
+of both elementary and global species for some temperatures is constructed
+({\small using JANAF polynoms}) or read ({\small if the user found useful to
+define a global specie not simply related to elementary ones ; eg. unspecified
+hydrocarbon known by C, H, O, N, S analysis and heating value.}).\\ The
+thermodynamic properties of condensed phase are more simple : formation enthalpy
+is computed using properties of gaseous products of combustion with air ({\small
+formation enthalpy of wich is zero valued as O2 and N2 are reference state}) and
+the lower heating value. The heat capacity of condensed phase is assumed
+constant and it is a data the user have to type ({\small in the corresponding
+data file dp\_FCP or dp\_FUE}).
 
 
 %d
@@ -19,11 +31,34 @@ The thermodynamic properties of condensed phase are more simple : formation enth
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-A table of gases ({\small both elementary species and global ones}) enthalpy for some temperatures ({\small user choses number of points, temperature in dp\_*** file}) is computed ({\small enthalpy of elementary species is computed using JANAF polynomia ; enthalpy for global species are computed by weighting of elementary ones})or read ({\small subroutine PPTBHT}). Then the entahlpy is supposed to be linear vs. temperature in each temperature gap ({\small i.e. continuous piece wise linea [...]
+A table of gases ({\small both elementary species and global ones}) enthalpy for
+some temperatures ({\small user choses number of points, temperature in dp\_***
+file}) is computed ({\small enthalpy of elementary species is computed using
+JANAF polynomia ; enthalpy for global species are computed by weighting of
+elementary ones})or read ({\small subroutine PPTBHT}). Then the entahlpy is
+supposed to be linear vs. temperature in each temperature gap ({\small
+i.e. continuous piece wise linear on the whole temperature range}). As a
+consequence, temperature is a linear function of entahlpy ; and a simple
+algorithm ({\small subroutine COTHHT}) allows to determine the enthalpy of a
+mixture of gases ({\small for inlet conditions it is more useful to indicate
+temperature and mass fractions}) or to determine temperature from enthalpy of
+the mixture and mass fractions of global species ({\small common use in every
+fluid particle, at every time step}).
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 \section{Particles enthalpy discretisation}
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-Enthalpy of condensed material are rarely known. Commonly, the thermal power and ultimate analysis are determined. So, using simple assumptions and the enthalpy of known released species ({\small after burning with air}) the formation enthalpy of coal or heavy oil can be computed. Assuming the thermal capacity is constant for every condensed material a table can be build with ... two temperatures, allowing the use of the same simple algorithm for temperature-enthalpy conversion. When int [...]
+Enthalpy of condensed material are rarely known. Commonly, the thermal power and
+ultimate analysis are determined. So, using simple assumptions and the enthalpy
+of known released species ({\small after burning with air}) the formation
+enthalpy of coal or heavy oil can be computed. Assuming the thermal capacity is
+constant for every condensed material a table can be build with ... two
+temperatures, allowing the use of the same simple algorithm for
+temperature-enthalpy conversion. When intermediate gaseous species ({\small
+volatile or vapour}) are thermodynamically known, simple assumptions({\small eg
+: char is thermodynamically equivalent to pure carbon in reference state ; ashes
+are inert}) allow to deduce enthalpy for heterogeneous reactions ({\small these
+energies have not to be explicitely taken in account for the energy budget of
+particles}).
diff --git a/doc/tutorial/Makefile.am b/doc/tutorial/Makefile.am
index afbeb11..83e1892 100644
--- a/doc/tutorial/Makefile.am
+++ b/doc/tutorial/Makefile.am
@@ -45,11 +45,6 @@ TEXINPUTFILES =
 
 EXTRA_DIST = $(TEXMAIN) $(TEXOTHERS) $(TEXINPUTFILES)
 
-# One adds the whole directory of test cases and get rid of the .svn
-# directories with a dist-hook. The reason for this trick is that
-# the number of test cases can grow and change a lot.
-EXTRA_DIST += test_cases
-
 # Subdirectories (order is important)
 
 SUBDIRS = graphics .
diff --git a/doc/tutorial/Makefile.in b/doc/tutorial/Makefile.in
index 69226a7..883700e 100644
--- a/doc/tutorial/Makefile.in
+++ b/doc/tutorial/Makefile.in
@@ -72,15 +72,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -126,6 +137,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -149,6 +161,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -200,6 +213,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -256,6 +270,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -293,7 +308,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -341,11 +355,7 @@ tuto_case5.tex
 TEXINPUTFILES = 
 
 # Distributed files
-
-# One adds the whole directory of test cases and get rid of the .svn
-# directories with a dist-hook. The reason for this trick is that
-# the number of test cases can grow and change a lot.
-EXTRA_DIST = $(TEXMAIN) $(TEXOTHERS) $(TEXINPUTFILES) test_cases
+EXTRA_DIST = $(TEXMAIN) $(TEXOTHERS) $(TEXINPUTFILES)
 
 # Subdirectories (order is important)
 SUBDIRS = graphics .
diff --git a/doc/tutorial/case2.tex b/doc/tutorial/case2.tex
index 90fb588..ef60e43 100644
--- a/doc/tutorial/case2.tex
+++ b/doc/tutorial/case2.tex
@@ -31,7 +31,7 @@
 %-----------------------------
 
 This aim of this case is to tackle the merging of initially separate meshes into
-a single fluid domain. The questions of mesh pasting and hanging nodes will be
+a single fluid domain. The questions of mesh joining and hanging nodes will be
 addressed. The test case will then be used to present more complex calculations,
 with time dependent variables and Fortran user routines.
 
@@ -105,14 +105,14 @@ variable in cases 3 and 4:
 %---------------------------------------
 
 Figure \ref{figante22} shows a global view of the mesh and some details of
-the pasting zones, to show that \CS can deal with hanging nodes.
+the joining zones, to show that \CS can deal with hanging nodes.
 This mesh is composed of 1\,650 cells, which is very small compared to those used in real
 studies. This is a deliberate choice so that tutorial calculations run fast.
 
 \begin{figure}[h!]
 \begin{center}
 \includegraphics[width=8.65cm,height=7.4cm]{fig05}
-\caption{View of the full domain mesh with zoom on the pasting regions}
+\caption{View of the full domain mesh with zoom on the joining regions}
 \label{figante22}
 \end{center}
 \end{figure}
@@ -122,7 +122,7 @@ studies. This is a deliberate choice so that tutorial calculations run fast.
 {\bfseries Coordinates system}: cartesian, origin on the edge of the main
 pipe at the outlet level, on the nozzle side (figure \ref{figante22})
 
-{\bfseries Mesh generator used}: SIMAIL and mesh pasting with the Preprocessor
+{\bfseries Mesh generator used}: SIMAIL and mesh joining with the Preprocessor
 of \CS (in order to deal with hanging nodes)
 
 {\bfseries Color definition}: see figure \ref{figante23}
@@ -290,8 +290,8 @@ Output period for post-processing files& $2$ \\
 \end{tabular}\\
 \end{center}
 
-In order to paste the separate meshes into a single domain, colors 5, 24 and 32
-will have to be pasted through the Graphical Interface.
+In order to join the separate meshes into a single domain, colors 5, 24 and 32
+will have to be joined through the Graphical Interface.
 
 
 
@@ -312,7 +312,7 @@ removed from the
 post-processing results\footnote{this can be very useful to save some disk space
 if some variables are of no interest, as post-processing files can be large}.
 
-Eventually, probes will be defined for chronological records, folowing the data
+Eventually, probes will be defined for chronological records, following the data
 given in figure \ref{figante25}. Then the {\itshape total pressure} will be
 deactivated for all probes and the {\itshape Velocity U} will only be activated
 on probes  1, 2, 6, 7 and 8.
diff --git a/doc/tutorial/case3.tex b/doc/tutorial/case3.tex
index d8b868b..0edde46 100644
--- a/doc/tutorial/case3.tex
+++ b/doc/tutorial/case3.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -28,7 +28,7 @@
 %-----------------------------------------------------------------------------------------------------------------
 \section{CASE 3:  Time dependent boundary conditions and variable fluid density}
 %-----------------------------------------------------------------------------------------------------------------
-In this case some boundary conditions will be time dependent and some physycal
+In this case some boundary conditions will be time dependent and some physical
 characteristics of the fluid will be dependent on the temperature.
 
         \subsection{Calculation options}
@@ -134,13 +134,28 @@ Colors & Conditions \\
 \end{center}
 \end{table}
 
+        \subsection{Variable Density}
+%---------------------------------
+In this case the density is a function of temperature, the variation law is defined
+ in the Graphical User Interface although it can also be defined in a Fortran user 
+routine. The expression is:
+\begin{equation}
+\rho = T.(A.T + B) + C
+\end{equation}
+where $\rho$ is the density, $T$ is the temperature, $A = -4.0668\times10^{-3}$,
+$B =-5.0754\times 10^{-2}$ and $C = 1\,000.9$
+
+In order for the variable density to have an effect on the flow, gravity must be
+set to a non-zero value. $\vect{g} = -9.81 \vect{e}_y$ will be specified in the
+Graphical Interface.
+
 
         \subsection{Parameters}
 %------------------------------
 
-All the parameter necessary to this study can be defined through the Graphical
-Interface, except the time dependent boundary conditions and the variable
-density that have to be specified in user routines.
+All the parameters necessary to this study can be defined through the Graphical
+Interface, except the time dependent boundary conditions that have to be specified 
+in user routines.
 
 \begin{center}
 \begin{tabular}{|l|c|}
@@ -156,22 +171,22 @@ Output period for post-processing files& $2$ \\
 \end{tabular}\\
 \end{center}
 
-In order to paste the separate meshes into a single domain, colors 5, 24 and 32
-will have to be pasted through the Graphical Interface.
+In order to join the separate meshes into a single domain, colors 5, 24 and 32
+will have to be joined through the Graphical Interface.
 
 
-        \subsection{User routines}
+        \subsection{User routine}
 %---------------------------------
 
-The following routines have to be copied from the folder FORT/USER/base into the
-folder FORT\footnote{only when they appear in the FORT directory will they be
-taken into account by the code}: usclim.F and usphyv.F.
+The following routine has to be copied from the folder SRC/REFERENCE/base into the
+folder SRC\footnote{only when it appears in the SRC directory will it be
+taken into account by the code}: usclim.f90.
 
-$\bullet$ {\bfseries usclim.F}\\
+{\bfseries usclim.f90}\\
 This routine allows to define advanced boundary conditions on the boundary
-faces. Even if usclim.F is used, all boundary conditions have to be defined in
+faces. Even if usclim.f90 is used, all boundary conditions have to be defined in
 the Graphical User Interface. Only the conditions that differ from this first
-definition need appear in usclim.F. The boundary conditions defined in usclim.F
+definition need to appear in usclim.f90. The boundary conditions defined in usclim.f90
 will replace those specified in the Graphical Interface.
 
 In this case, the temperature at entry is supposed variable in time, following
@@ -187,30 +202,13 @@ where $T$ is the temperature in \degresC\ and $t$ is the time in $s$.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=9cm,height=6.4cm]{probe9.png}
+\includegraphics[width=9cm,height=6.4cm]{probe9}
 \caption{Time evolution of the temperature at inlet}
 \label{figp9_e3}
 \end{center}
 \end{figure}
 
 
-$\bullet$ {\bfseries usphyv.F}\\
-This routine allows to specify variable physical properties, density in
-particular. In this case, the variation law given as an example in the routine
-will be appropriate:
-\begin{equation}
-\rho = T.(A.T + B) + C
-\end{equation}
-where $\rho$ is the density, $T$ is the temperature, $A = -4.0668\times10^{-3}$,
-$B =-5.0754\times 10^{-2}$ and $C = 1\,000.9$
-
-\textbf{Note:} in the example routine, the example is protected by a test to prevent any
-undesired use. Do not forget to deactivate it.
-
-In order for the variable density to have an effect on the flow, gravity must be
-set to a non-zero value. $\vect{g} = -9.81 \vect{e}_y$ will be specified in the
-Graphical Interface.
-
         \subsection{Output management}
 %-------------------------------------
 
@@ -259,7 +257,7 @@ removed from the
 post-processing results\footnote{this can be very useful to save some disk space
 if some variables are of no interest, as post-processing files can be large}.
 
-Eventually, probes will be defined for chronological records, folowing the data
+Eventually, probes will be defined for chronological records, following the data
 given in figure \ref{figante25}. Then the {\itshape total pressure} will be
 deactivated from all probes and the {\itshape Velocity U} will be only activated
 on probes  1, 2, 6, 7 and 8.
@@ -283,7 +281,7 @@ monitoring probe.
 \begin{figure}[hb]
 \begin{center}
 \begin{tabular}{cc}
-\includegraphics[width=11cm]{evotemp_case3.png} \\
+\includegraphics[width=11cm]{evotemp_case3} \\
 \end{tabular}
 \caption{Time evolution of temperature at monitoring probes for case 3}
 \label{fige3_e3}
diff --git a/doc/tutorial/case4.tex b/doc/tutorial/case4.tex
index 277ace5..82cc709 100644
--- a/doc/tutorial/case4.tex
+++ b/doc/tutorial/case4.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -134,6 +134,20 @@ Colors & Conditions \\
 \end{center}
 \end{table}
 
+        \subsection{Variable Density}
+%---------------------------------
+In this case the density is a function of temperature, the variation law is defined
+ in the Graphical User Interface although it can also be defined in a Fortran user 
+routine. The expression is:
+\begin{equation}
+\rho = T.(A.T + B) + C
+\end{equation}
+where $\rho$ is the density, $T$ is the temperature, $A = -4.0668\times10^{-3}$,
+$B =-5.0754\times 10^{-2}$ and $C = 1\,000.9$
+
+In order for the variable density to have an effect on the flow, gravity must be
+set to a non-zero value. $\vect{g} = -9.81 \vect{e}_y$ will be specified in the
+Graphical Interface.
 
 
         \subsection{Head loss}
@@ -141,7 +155,7 @@ Colors & Conditions \\
 
 To simulate the presence of an obstacle $0.20\ m$ large and $0.5\ m$ high in the
 vessel, a zone of head loss will be created in the domain (fig \ref{figante41}).
-The head loss zone is situated between the coordinates $X=0.2\ m$ and $X=0.4\ m$,
+The head loss zone is located between the coordinates $X=0.2\ m$ and $X=0.4\ m$,
 and $Y=-0.75\ m$ and $Y=-0.25\ m$. The head loss coefficient to apply is $10^4$
 and is isotropic.
 
@@ -154,14 +168,11 @@ and is isotropic.
 \end{figure}
 
 
-
         \subsection{Parameters}
 %------------------------------
 
-All the parameter necessary to this study can be defined through the Graphical
-Interface, except the time dependent boundary conditions, the variable
-density and the head loss that have to be specified in user routines. The
-calculation of the spatial average is also defined by a user routine.
+All the parameters necessary to this study can be defined through the Graphical
+Interface. However, the calculation of the spatial average is defined by a user routine.
 
 
 \begin{center}
@@ -179,22 +190,22 @@ The calculation will be run in parallel on 2 processors \\
 \end{tabular}\\
 \end{center}
 
-In order to paste the separate meshes into a single domain, colors 5, 24 and 32
-will have to be pasted through the Graphical Interface.
+In order to join the separate meshes into a single domain, colors 5, 24 and 32
+will have to be joined through the Graphical Interface.
 
 
         \subsection{User routines}
 %---------------------------------
 
-The following routines have to be copied from the folder FORT/USER/base into the
-folder FORT\footnote{only when they appear in the FORT directory will they be
-taken into account by the code}: usclim.F, usphyv.F, usproj.F and uskpdc.F.
+The following routines have to be copied from the folder SRC/REFERENCE/base into the
+folder SRC\footnote{only when they appear in the SRC directory will they be
+taken into account by the code}: usclim.f90 and usproj.f90.
 
-$\bullet$ {\bfseries usclim.F}\\
+$\bullet$ {\bfseries usclim.f90}\\
 This routine allows to define advanced boundary conditions on the boundary
-faces. Even if usclim.F is used, all boundary conditions have to be defined in
+faces. Even if usclim.f90 is used, all boundary conditions have to be defined in
 the Graphical User Interface. Only the conditions that differ from this first
-definition need appear in usclim.F. The boundary conditions defined in usclim.F
+definition need to appear in usclim.f90. The boundary conditions defined in usclim.f90
 will replace those specified in the Graphical Interface.
 
 In this case, the temperature at entry is supposed variable in time, following
@@ -210,32 +221,14 @@ where $T$ is the temperature in \degresC\ and $t$ is the time in $s$.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=9cm,height=6.4cm]{probe9.png}
+\includegraphics[width=9cm,height=6.4cm]{probe9}
 \caption{Time evolution of the temperature at inlet}
 \label{figp9_e4}
 \end{center}
 \end{figure}
 
 
-$\bullet$ {\bfseries usphyv.F}\\
-This routine allows to specify variable physical properties, density in
-particular. In this case, the variation law given as an example in the routine
-will be appropriate:
-\begin{equation}
-\rho = T.(A.T + B) + C
-\end{equation}
-where $\rho$ is the density, $T$ is the temperature, $A = -4.0668\times10^{-3}$,
-$B =-5.0754\times 10^{-2}$ and $C = 1\,000.9$
-
-\textbf{Note:} in the example routine, the example is protected by a test to prevent any
-undesired use. Do not forget to deactivate it.
-
-In order for the variable density to have an effect on the flow, gravity must be
-set to a non-zero value. $\vect{g} = -9.81 \vect{e}_y$ will be specified in the
-Graphical Interface.
-
-
-$\bullet$ {\bfseries usproj.F}\\
+$\bullet$ {\bfseries usproj.f90}\\
 This routine is called at the end of each time step and has access to the whole
 set of variables of the code. It is therefore useful for many user-specific
 post-processing, including the calculation of a spatial average in the present
@@ -250,29 +243,10 @@ yield for each processor the sum on the cells managed by this processor. In
 order to obtain the full sum, the parallelism routine PARSOM must be used (see
 example).
 
-\textbf{Note:} usproj.F contains many examples. They should be removed before
+\textbf{Note:} usproj.f90 contains many examples. They should be removed before
 running the case.
 
 
-$\bullet$ {\bfseries uskpdc.F}
-
-This routine allows to apply head loss on the fluid domain.
-
-The localization of the obstacle is made geometrically, using the
-coordinates of the centers of the cells.
-
-
-If $XYZCEN(1,IEL) \leq 0.40$ and $XYZCEN(1,IEL) \geq 0.20$ \\
-and $XYZCEN(2,IEL) \geq -0.75$ and $XYZCEN(2,IEL) \leq -0.25$\\
-then an isotropic head loss coefficient $K = 10^{4}$ is applied:\\
-
-$CKUPDC(IELPDC,1) = K*ABS(RTPA(IEL,IU(IPHAS)))$ \\
-$CKUPDC(IELPDC,2) = K*ABS(RTPA(IEL,IV(IPHAS)))$ \\
-$CKUPDC(IELPDC,3) = K*ABS(RTPA(IEL,IW(IPHAS)))$ \\
-$CKUPDC(IELPDC,4) = 0.$ \\
-$CKUPDC(IELPDC,5) = 0.$ \\
-$CKUPDC(IELPDC,6) = 0.$
-
         \subsection{Output management}
 %-------------------------------------
 
@@ -320,7 +294,7 @@ removed from the
 post-processing results\footnote{this can be very useful to save some disk space
 if some variables are of no interest, as post-processing files can be large}.
 
-Eventually, probes will be defined for chronological records, folowing the data
+Eventually, probes will be defined for chronological records, following the data
 given in figure \ref{figante25}. Then the {\itshape total pressure} will be
 deactivated from all probes and the {\itshape Velocity U} will be only activated
 on probes  1, 2, 6, 7 and 8.
@@ -337,7 +311,7 @@ Figure \ref{fige2_e4} shows the evolution of the spatial average of the temperat
 
 \begin{figure}[h]
 \begin{center}
-\includegraphics[width=9cm]{moytemp.png}
+\includegraphics[width=9cm]{moytemp}
 \caption{Evolution of spatial average of the temperature as a function of time}
 \label{fige2_e4}
 \end{center}
diff --git a/doc/tutorial/case5.tex b/doc/tutorial/case5.tex
index 1fb7bb9..a5e4738 100644
--- a/doc/tutorial/case5.tex
+++ b/doc/tutorial/case5.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -146,7 +146,7 @@ The following options are considered for the case:
         \item Scalar(s): temperature
         \item Physical properties: uniform and constant for specific heat and
 thermal conductivity and variable for density and dynamic viscosity
-        \item Pressure interpolation in stratified fows : improved
+        \item Pressure interpolation in stratified flows : improved
 \end{itemize}
 
 
@@ -196,9 +196,35 @@ Colors & Conditions \\
 \end{table}
 
 
+
+        \subsection{Variable density and dynamic viscosity}
+%------------------------------
+
+In this case the density and the dynamic are functions of the temperature, the following variation laws are specified in the Graphical User Interface:
+\begin{equation}
+\rho = T.(A.T + B) + C
+\end{equation}
+where $\rho$ is the density, $T$ is the temperature, $A = -4.0668\times10^{-3}$,
+$B =-5.0754\times 10^{-2}$ and $C = 1\,000.9$
+
+
+For the dynamic viscosity, the variation law is:
+
+\begin{equation}
+\mu = T.(T.(AM.T + BM) + CM) + DM
+\end{equation}
+where $\mu$ is the dynamic viscosity, $T$ is the temperature,
+$AM=-3.4016\times 10^{-9}$, $BM = 6.2332\times 10^{-7}$,
+$CM = -4.5577\times 10^{-5}$ and $DM = 1.6935\times 10^{-3}$
+
+In order for the variable density to have an effect on the flow, gravity must be
+set to a non-zero value. $\vect{g} = -9.81 \vect{e}_z$ will be specified in the
+Graphical Interface.
+
+
         \subsection{Parameters}
 %------------------------------
-All the parameter necessary to this study can be defined through the Graphical
+All the parameters necessary to this study can be defined through the Graphical
 Interface, except the variable fluid characteristics and the advanced
 post-processing features that have to be specified in user routines.
 
@@ -263,36 +289,7 @@ profil32: & $x=3.2\qquad$ & $y=0\qquad$ & $-0.2 \leqslant z \leqslant 0.2$ ($m$)
 
 The following routines have to be copied from the folder SRC/REFERENCE/base into the
 folder SRC\footnote{only when they appear in the SRC directory will they be
-taken into account by the code}: usphyv.F, usdpst.F, usvpst.F and usmpst.F
-
-
-$\bullet$ {\bfseries usphyv.F}\\
-This routine allows to specify variable physical properties, density and
-viscosity in particular. In this case, the following variation laws are specified:
-\begin{equation}
-\rho = T.(A.T + B) + C
-\end{equation}
-where $\rho$ is the density, $T$ is the temperature, $A = -4.0668\times10^{-3}$,
-$B =-5.0754\times 10^{-2}$ and $C = 1\,000.9$
-
-
-For the dynamic viscosity, the variation law is:
-
-\begin{equation}
-\mu = T.(T.(AM.T + BM) + CM) + DM
-\end{equation}
-where $\mu$ is the dynamic viscosity, $T$ is the temperature,
-$AM=-3.4016\times 10^{-9}$, $BM = 6.2332\times 10^{-7}$,
-$CM = -4.5577\times 10^{-5}$ and $DM = 1.6935\times 10^{-3}$
-
-
-\textbf{Note:} in the example routine, the examples are protected by a test to prevent any
-undesired use. Do not forget to deactivate them.
-
-In order for the variable density to have an effect on the flow, gravity must be
-set to a non-zero value. $\vect{g} = -9.81 \vect{e}_y$ will be specified in the
-Graphical Interface.
-
+taken into account by the code}: usdpst.f90, usvpst.f90 and usmpst.f90
 
 In this test case, advanced post-processing features will be used. A clip
 plane will be created, along the symmetry plane of the domain, on which the
@@ -307,15 +304,15 @@ as for the cells it contains.
 
 Three Fortran routines will be used:
 
-$\bullet$ {\bfseries usdpst.F}\\
+$\bullet$ {\bfseries usdpst.f90}\\
 This routine is called only once, at the beginning of the calculation. It allows
 to define the different writers and parts.
 
-$\bullet$ {\bfseries usmpst.F}\\
+$\bullet$ {\bfseries usmpst.f90}\\
 This routine is called at each time step. It allows to redefine the content of
 certain parts using any variable, especially the temperature for this case.
 
-$\bullet$ {\bfseries usvpst.F}\\
+$\bullet$ {\bfseries usvpst.f90}\\
 This routine is called at each time step. It allows to specify which variable
 will be written on which part.
 
diff --git a/doc/tutorial/graphics/Makefile.am b/doc/tutorial/graphics/Makefile.am
index 863d808..c1c7089 100644
--- a/doc/tutorial/graphics/Makefile.am
+++ b/doc/tutorial/graphics/Makefile.am
@@ -27,42 +27,30 @@ FIGFILES =
 # Other files
 
 OTHERFILES = \
-c1_capture01.jpg c1_capture02.jpg c1_capture03.jpg c1_capture04.jpg \
-c1_capture05.jpg c1_capture06.jpg c1_capture07.jpg c1_capture08.jpg \
-c1_capture09.jpg c1_capture10.jpg c1_capture11.jpg c1_capture12.jpg \
-c1_capture13.jpg c1_capture14.jpg c1_capture15.jpg c1_capture16.jpg \
-c1_capture17.jpg c1_capture18.jpg c1_capture19.jpg c1_capture20.jpg \
-c1_capture21.jpg c1_capture22.jpg c1_capture23.jpg c1_capture24.jpg \
-c1_capture25.jpg c1_capture26.jpg c1_capture27.jpg c1_capture28.jpg \
-c1_capture29.jpg c1_capture30.jpg c1_capture31.jpg c1_capture32.jpg \
-c1_capture33.jpg c1_capture34.jpg c1_capture35.jpg c1_capture36.jpg \
-c1_capture37.jpg c1_capture38.jpg c1_capture39.jpg c1_capture40.jpg \
-c1_capture41.jpg c1_capture42.jpg c1_capture43.jpg \
-c2_capture01.jpg c2_capture02.jpg c2_capture03.jpg c2_capture04.jpg \
-c2_capture05.jpg c2_capture06.jpg c2_capture07.jpg c2_capture08.jpg \
-c2_capture09.jpg c2_capture10.jpg c2_capture11.jpg c2_capture12.jpg \
-c2_capture13.jpg c2_capture14.jpg c2_capture152.jpg c2_capture15.jpg \
-c2_capture16.jpg c2_capture17.jpg c2_capture18.jpg c2_capture19.jpg \
-c2_capture20.jpg c2_capture212.jpg c2_capture21.jpg c2_capture22.jpg \
-c2_capture23.jpg c2_capture24.jpg c2_capture25.jpg c2_capture26.jpg \
-c2_capture27.jpg c2_capture28.jpg c2_capture29.jpg c2_capture30.jpg \
 c2_p1.jpg c2_p2.jpg c2_p3.jpg c2_p4.jpg c2_p5.jpg c2_p6.jpg c2_p7.jpg \
-c3_capture01.jpg c3_capture02.jpg c3_capture03.jpg c3_capture04.jpg \
-c3_capture05.jpg c3_capture06.jpg c4_capture01.jpg c4_capture02.jpg \
-c5_capture01.jpg c5_capture02.jpg c5_capture03.jpg c5_capture04.jpg \
-c5_capture05.jpg c5_capture06.jpg c5_capture07.jpg c5_capture08.jpg \
-c5_capture09.jpg c5_capture10.jpg c5_capture11.jpg c5_capture12.jpg \
-c5_capture13.jpg c5_config.jpg \
-capture10.jpg capture11.jpg capture12.jpg capture13.jpg \
-cas1_t_10.jpg cas1_t_1.jpg cas1_t_20.jpg cas1_t_29.jpg \
+c5_config.jpg cas1_t_10.jpg cas1_t_1.jpg cas1_t_20.jpg cas1_t_29.jpg \
 case3_p10.jpg case3_p1.jpg case3_p2.jpg case3_p3.jpg case3_p4.jpg \
 case3_p5.jpg case3_p6.jpg case3_p7.jpg case3_p8.jpg case3_p9.jpg \
 case4_p1.jpg case4_p2.jpg case4_p3.jpg case4_p4.jpg case4_p5.jpg \
 case4_p6.jpg case5_01.jpg case5_02.jpg case5_03.jpg case5_04.jpg \
 case5_05.jpg case5_06.jpg case5_07.jpg case5_08.jpg case5_09.jpg \
-color_Snimbus.jpg evotemp_case3.png \
-fig01.jpg fig02.jpg fig03.jpg fig04.jpg fig05.jpg fig06.jpg \
-fig07.jpg fig08.jpg fig09.jpg moytemp.png probe9.png
+color_Snimbus.jpg density_law.png evotemp_case3.png \
+fig01.jpg fig02.jpg fig03.jpg fig04.jpg fig05.jpg fig06.jpg fig07.jpg \
+fig08.jpg fig09.jpg \
+head_loss0.png head_loss1.png head_loss2.png head_loss3.png head_loss4.png \
+head_loss5.png \
+moytemp.png probe9.png \
+V-10.png V-11.png V-12.png V-13.png V-14.png V-15.png V-16.png V-17.png \
+V-18.png V-1.png V-20.png V-21.png V-22.png V-23.png V-24.png V-25.png \
+V-27.png V-28.png V-29.png V-2.png V-30.png V-31.png V-32.png V-33.png \
+V-34bis.png V-34.png V-35.png V-36.png V-37.png V-38.png V-39.png V-3.png \
+V-40.png V-41.png V-43.png V-44.png V-45.png V-46.png V-47.png V-48.png \
+V-49.png V-4.png V-50.png V-51.png V-52.png V-53.png V-54.png V-56.png \
+V-57.png V-58.png V-59.png V-5.png V-60bis.png V-60.png V-61.png V-62.png \
+V-63.png V-64.png V-65.png V-66.png V-67.png V-68.png V-69bis.png V-69.png \
+V-6.png V-70.png V-71.png V-72.png V-73bis.png V-73.png V-74bis.png V-74.png \
+V-75.png V-76bis.png V-76.png V-7.png V-8.png V-9.png \
+viscosity_law.png
 
 # Distributed files
 
diff --git a/doc/tutorial/graphics/Makefile.in b/doc/tutorial/graphics/Makefile.in
index 923f15f..6db7abb 100644
--- a/doc/tutorial/graphics/Makefile.in
+++ b/doc/tutorial/graphics/Makefile.in
@@ -72,20 +72,32 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -109,6 +121,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -160,6 +173,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -216,6 +230,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -253,7 +268,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -286,42 +300,30 @@ FIGFILES =
 
 # Other files
 OTHERFILES = \
-c1_capture01.jpg c1_capture02.jpg c1_capture03.jpg c1_capture04.jpg \
-c1_capture05.jpg c1_capture06.jpg c1_capture07.jpg c1_capture08.jpg \
-c1_capture09.jpg c1_capture10.jpg c1_capture11.jpg c1_capture12.jpg \
-c1_capture13.jpg c1_capture14.jpg c1_capture15.jpg c1_capture16.jpg \
-c1_capture17.jpg c1_capture18.jpg c1_capture19.jpg c1_capture20.jpg \
-c1_capture21.jpg c1_capture22.jpg c1_capture23.jpg c1_capture24.jpg \
-c1_capture25.jpg c1_capture26.jpg c1_capture27.jpg c1_capture28.jpg \
-c1_capture29.jpg c1_capture30.jpg c1_capture31.jpg c1_capture32.jpg \
-c1_capture33.jpg c1_capture34.jpg c1_capture35.jpg c1_capture36.jpg \
-c1_capture37.jpg c1_capture38.jpg c1_capture39.jpg c1_capture40.jpg \
-c1_capture41.jpg c1_capture42.jpg c1_capture43.jpg \
-c2_capture01.jpg c2_capture02.jpg c2_capture03.jpg c2_capture04.jpg \
-c2_capture05.jpg c2_capture06.jpg c2_capture07.jpg c2_capture08.jpg \
-c2_capture09.jpg c2_capture10.jpg c2_capture11.jpg c2_capture12.jpg \
-c2_capture13.jpg c2_capture14.jpg c2_capture152.jpg c2_capture15.jpg \
-c2_capture16.jpg c2_capture17.jpg c2_capture18.jpg c2_capture19.jpg \
-c2_capture20.jpg c2_capture212.jpg c2_capture21.jpg c2_capture22.jpg \
-c2_capture23.jpg c2_capture24.jpg c2_capture25.jpg c2_capture26.jpg \
-c2_capture27.jpg c2_capture28.jpg c2_capture29.jpg c2_capture30.jpg \
 c2_p1.jpg c2_p2.jpg c2_p3.jpg c2_p4.jpg c2_p5.jpg c2_p6.jpg c2_p7.jpg \
-c3_capture01.jpg c3_capture02.jpg c3_capture03.jpg c3_capture04.jpg \
-c3_capture05.jpg c3_capture06.jpg c4_capture01.jpg c4_capture02.jpg \
-c5_capture01.jpg c5_capture02.jpg c5_capture03.jpg c5_capture04.jpg \
-c5_capture05.jpg c5_capture06.jpg c5_capture07.jpg c5_capture08.jpg \
-c5_capture09.jpg c5_capture10.jpg c5_capture11.jpg c5_capture12.jpg \
-c5_capture13.jpg c5_config.jpg \
-capture10.jpg capture11.jpg capture12.jpg capture13.jpg \
-cas1_t_10.jpg cas1_t_1.jpg cas1_t_20.jpg cas1_t_29.jpg \
+c5_config.jpg cas1_t_10.jpg cas1_t_1.jpg cas1_t_20.jpg cas1_t_29.jpg \
 case3_p10.jpg case3_p1.jpg case3_p2.jpg case3_p3.jpg case3_p4.jpg \
 case3_p5.jpg case3_p6.jpg case3_p7.jpg case3_p8.jpg case3_p9.jpg \
 case4_p1.jpg case4_p2.jpg case4_p3.jpg case4_p4.jpg case4_p5.jpg \
 case4_p6.jpg case5_01.jpg case5_02.jpg case5_03.jpg case5_04.jpg \
 case5_05.jpg case5_06.jpg case5_07.jpg case5_08.jpg case5_09.jpg \
-color_Snimbus.jpg evotemp_case3.png \
-fig01.jpg fig02.jpg fig03.jpg fig04.jpg fig05.jpg fig06.jpg \
-fig07.jpg fig08.jpg fig09.jpg moytemp.png probe9.png
+color_Snimbus.jpg density_law.png evotemp_case3.png \
+fig01.jpg fig02.jpg fig03.jpg fig04.jpg fig05.jpg fig06.jpg fig07.jpg \
+fig08.jpg fig09.jpg \
+head_loss0.png head_loss1.png head_loss2.png head_loss3.png head_loss4.png \
+head_loss5.png \
+moytemp.png probe9.png \
+V-10.png V-11.png V-12.png V-13.png V-14.png V-15.png V-16.png V-17.png \
+V-18.png V-1.png V-20.png V-21.png V-22.png V-23.png V-24.png V-25.png \
+V-27.png V-28.png V-29.png V-2.png V-30.png V-31.png V-32.png V-33.png \
+V-34bis.png V-34.png V-35.png V-36.png V-37.png V-38.png V-39.png V-3.png \
+V-40.png V-41.png V-43.png V-44.png V-45.png V-46.png V-47.png V-48.png \
+V-49.png V-4.png V-50.png V-51.png V-52.png V-53.png V-54.png V-56.png \
+V-57.png V-58.png V-59.png V-5.png V-60bis.png V-60.png V-61.png V-62.png \
+V-63.png V-64.png V-65.png V-66.png V-67.png V-68.png V-69bis.png V-69.png \
+V-6.png V-70.png V-71.png V-72.png V-73bis.png V-73.png V-74bis.png V-74.png \
+V-75.png V-76bis.png V-76.png V-7.png V-8.png V-9.png \
+viscosity_law.png
 
 
 # Distributed files
diff --git a/doc/tutorial/graphics/V-1.png b/doc/tutorial/graphics/V-1.png
new file mode 100644
index 0000000..9a5f0c5
Binary files /dev/null and b/doc/tutorial/graphics/V-1.png differ
diff --git a/doc/tutorial/graphics/V-10.png b/doc/tutorial/graphics/V-10.png
new file mode 100644
index 0000000..4862044
Binary files /dev/null and b/doc/tutorial/graphics/V-10.png differ
diff --git a/doc/tutorial/graphics/V-11.png b/doc/tutorial/graphics/V-11.png
new file mode 100644
index 0000000..c68bf1c
Binary files /dev/null and b/doc/tutorial/graphics/V-11.png differ
diff --git a/doc/tutorial/graphics/V-12.png b/doc/tutorial/graphics/V-12.png
new file mode 100644
index 0000000..3d40621
Binary files /dev/null and b/doc/tutorial/graphics/V-12.png differ
diff --git a/doc/tutorial/graphics/V-13.png b/doc/tutorial/graphics/V-13.png
new file mode 100644
index 0000000..b88003a
Binary files /dev/null and b/doc/tutorial/graphics/V-13.png differ
diff --git a/doc/tutorial/graphics/V-14.png b/doc/tutorial/graphics/V-14.png
new file mode 100644
index 0000000..0d61d82
Binary files /dev/null and b/doc/tutorial/graphics/V-14.png differ
diff --git a/doc/tutorial/graphics/V-15.png b/doc/tutorial/graphics/V-15.png
new file mode 100644
index 0000000..d975c12
Binary files /dev/null and b/doc/tutorial/graphics/V-15.png differ
diff --git a/doc/tutorial/graphics/V-16.png b/doc/tutorial/graphics/V-16.png
new file mode 100644
index 0000000..9165382
Binary files /dev/null and b/doc/tutorial/graphics/V-16.png differ
diff --git a/doc/tutorial/graphics/V-17.png b/doc/tutorial/graphics/V-17.png
new file mode 100644
index 0000000..797a006
Binary files /dev/null and b/doc/tutorial/graphics/V-17.png differ
diff --git a/doc/tutorial/graphics/V-18.png b/doc/tutorial/graphics/V-18.png
new file mode 100644
index 0000000..7d40238
Binary files /dev/null and b/doc/tutorial/graphics/V-18.png differ
diff --git a/doc/tutorial/graphics/V-2.png b/doc/tutorial/graphics/V-2.png
new file mode 100644
index 0000000..f6b4c67
Binary files /dev/null and b/doc/tutorial/graphics/V-2.png differ
diff --git a/doc/tutorial/graphics/V-20.png b/doc/tutorial/graphics/V-20.png
new file mode 100644
index 0000000..69d73b6
Binary files /dev/null and b/doc/tutorial/graphics/V-20.png differ
diff --git a/doc/tutorial/graphics/V-21.png b/doc/tutorial/graphics/V-21.png
new file mode 100644
index 0000000..8f45a18
Binary files /dev/null and b/doc/tutorial/graphics/V-21.png differ
diff --git a/doc/tutorial/graphics/V-22.png b/doc/tutorial/graphics/V-22.png
new file mode 100644
index 0000000..ed94e09
Binary files /dev/null and b/doc/tutorial/graphics/V-22.png differ
diff --git a/doc/tutorial/graphics/V-23.png b/doc/tutorial/graphics/V-23.png
new file mode 100644
index 0000000..807e98c
Binary files /dev/null and b/doc/tutorial/graphics/V-23.png differ
diff --git a/doc/tutorial/graphics/V-24.png b/doc/tutorial/graphics/V-24.png
new file mode 100644
index 0000000..895fea7
Binary files /dev/null and b/doc/tutorial/graphics/V-24.png differ
diff --git a/doc/tutorial/graphics/V-25.png b/doc/tutorial/graphics/V-25.png
new file mode 100644
index 0000000..d0c7830
Binary files /dev/null and b/doc/tutorial/graphics/V-25.png differ
diff --git a/doc/tutorial/graphics/V-27.png b/doc/tutorial/graphics/V-27.png
new file mode 100644
index 0000000..e12135f
Binary files /dev/null and b/doc/tutorial/graphics/V-27.png differ
diff --git a/doc/tutorial/graphics/V-28.png b/doc/tutorial/graphics/V-28.png
new file mode 100644
index 0000000..b24b09f
Binary files /dev/null and b/doc/tutorial/graphics/V-28.png differ
diff --git a/doc/tutorial/graphics/V-29.png b/doc/tutorial/graphics/V-29.png
new file mode 100644
index 0000000..d706654
Binary files /dev/null and b/doc/tutorial/graphics/V-29.png differ
diff --git a/doc/tutorial/graphics/V-3.png b/doc/tutorial/graphics/V-3.png
new file mode 100644
index 0000000..a46efaf
Binary files /dev/null and b/doc/tutorial/graphics/V-3.png differ
diff --git a/doc/tutorial/graphics/V-30.png b/doc/tutorial/graphics/V-30.png
new file mode 100644
index 0000000..f09caf9
Binary files /dev/null and b/doc/tutorial/graphics/V-30.png differ
diff --git a/doc/tutorial/graphics/V-31.png b/doc/tutorial/graphics/V-31.png
new file mode 100644
index 0000000..9de1d16
Binary files /dev/null and b/doc/tutorial/graphics/V-31.png differ
diff --git a/doc/tutorial/graphics/V-32.png b/doc/tutorial/graphics/V-32.png
new file mode 100644
index 0000000..4d372f8
Binary files /dev/null and b/doc/tutorial/graphics/V-32.png differ
diff --git a/doc/tutorial/graphics/V-33.png b/doc/tutorial/graphics/V-33.png
new file mode 100644
index 0000000..476ac30
Binary files /dev/null and b/doc/tutorial/graphics/V-33.png differ
diff --git a/doc/tutorial/graphics/V-34.png b/doc/tutorial/graphics/V-34.png
new file mode 100644
index 0000000..f62ab30
Binary files /dev/null and b/doc/tutorial/graphics/V-34.png differ
diff --git a/doc/tutorial/graphics/V-34bis.png b/doc/tutorial/graphics/V-34bis.png
new file mode 100644
index 0000000..1ba97a7
Binary files /dev/null and b/doc/tutorial/graphics/V-34bis.png differ
diff --git a/doc/tutorial/graphics/V-35.png b/doc/tutorial/graphics/V-35.png
new file mode 100644
index 0000000..96a23d9
Binary files /dev/null and b/doc/tutorial/graphics/V-35.png differ
diff --git a/doc/tutorial/graphics/V-36.png b/doc/tutorial/graphics/V-36.png
new file mode 100644
index 0000000..654a4d1
Binary files /dev/null and b/doc/tutorial/graphics/V-36.png differ
diff --git a/doc/tutorial/graphics/V-37.png b/doc/tutorial/graphics/V-37.png
new file mode 100644
index 0000000..a11c693
Binary files /dev/null and b/doc/tutorial/graphics/V-37.png differ
diff --git a/doc/tutorial/graphics/V-38.png b/doc/tutorial/graphics/V-38.png
new file mode 100644
index 0000000..fdbe23a
Binary files /dev/null and b/doc/tutorial/graphics/V-38.png differ
diff --git a/doc/tutorial/graphics/V-39.png b/doc/tutorial/graphics/V-39.png
new file mode 100644
index 0000000..7149616
Binary files /dev/null and b/doc/tutorial/graphics/V-39.png differ
diff --git a/doc/tutorial/graphics/V-4.png b/doc/tutorial/graphics/V-4.png
new file mode 100644
index 0000000..64ec262
Binary files /dev/null and b/doc/tutorial/graphics/V-4.png differ
diff --git a/doc/tutorial/graphics/V-40.png b/doc/tutorial/graphics/V-40.png
new file mode 100644
index 0000000..92cf331
Binary files /dev/null and b/doc/tutorial/graphics/V-40.png differ
diff --git a/doc/tutorial/graphics/V-41.png b/doc/tutorial/graphics/V-41.png
new file mode 100644
index 0000000..190df1d
Binary files /dev/null and b/doc/tutorial/graphics/V-41.png differ
diff --git a/doc/tutorial/graphics/V-43.png b/doc/tutorial/graphics/V-43.png
new file mode 100644
index 0000000..066aaad
Binary files /dev/null and b/doc/tutorial/graphics/V-43.png differ
diff --git a/doc/tutorial/graphics/V-44.png b/doc/tutorial/graphics/V-44.png
new file mode 100644
index 0000000..72418cf
Binary files /dev/null and b/doc/tutorial/graphics/V-44.png differ
diff --git a/doc/tutorial/graphics/V-45.png b/doc/tutorial/graphics/V-45.png
new file mode 100644
index 0000000..3a8b6bb
Binary files /dev/null and b/doc/tutorial/graphics/V-45.png differ
diff --git a/doc/tutorial/graphics/V-46.png b/doc/tutorial/graphics/V-46.png
new file mode 100644
index 0000000..f0e42ed
Binary files /dev/null and b/doc/tutorial/graphics/V-46.png differ
diff --git a/doc/tutorial/graphics/V-47.png b/doc/tutorial/graphics/V-47.png
new file mode 100644
index 0000000..e8a2e1d
Binary files /dev/null and b/doc/tutorial/graphics/V-47.png differ
diff --git a/doc/tutorial/graphics/V-48.png b/doc/tutorial/graphics/V-48.png
new file mode 100644
index 0000000..a58ac8a
Binary files /dev/null and b/doc/tutorial/graphics/V-48.png differ
diff --git a/doc/tutorial/graphics/V-49.png b/doc/tutorial/graphics/V-49.png
new file mode 100644
index 0000000..bbf3949
Binary files /dev/null and b/doc/tutorial/graphics/V-49.png differ
diff --git a/doc/tutorial/graphics/V-5.png b/doc/tutorial/graphics/V-5.png
new file mode 100644
index 0000000..a7a5137
Binary files /dev/null and b/doc/tutorial/graphics/V-5.png differ
diff --git a/doc/tutorial/graphics/V-50.png b/doc/tutorial/graphics/V-50.png
new file mode 100644
index 0000000..9d706a1
Binary files /dev/null and b/doc/tutorial/graphics/V-50.png differ
diff --git a/doc/tutorial/graphics/V-51.png b/doc/tutorial/graphics/V-51.png
new file mode 100644
index 0000000..1c0afe4
Binary files /dev/null and b/doc/tutorial/graphics/V-51.png differ
diff --git a/doc/tutorial/graphics/V-52.png b/doc/tutorial/graphics/V-52.png
new file mode 100644
index 0000000..262b050
Binary files /dev/null and b/doc/tutorial/graphics/V-52.png differ
diff --git a/doc/tutorial/graphics/V-53.png b/doc/tutorial/graphics/V-53.png
new file mode 100644
index 0000000..60b6d5f
Binary files /dev/null and b/doc/tutorial/graphics/V-53.png differ
diff --git a/doc/tutorial/graphics/V-54.png b/doc/tutorial/graphics/V-54.png
new file mode 100644
index 0000000..09d0c99
Binary files /dev/null and b/doc/tutorial/graphics/V-54.png differ
diff --git a/doc/tutorial/graphics/V-56.png b/doc/tutorial/graphics/V-56.png
new file mode 100644
index 0000000..63bf0f7
Binary files /dev/null and b/doc/tutorial/graphics/V-56.png differ
diff --git a/doc/tutorial/graphics/V-57.png b/doc/tutorial/graphics/V-57.png
new file mode 100644
index 0000000..e61fc5d
Binary files /dev/null and b/doc/tutorial/graphics/V-57.png differ
diff --git a/doc/tutorial/graphics/V-58.png b/doc/tutorial/graphics/V-58.png
new file mode 100644
index 0000000..1626dee
Binary files /dev/null and b/doc/tutorial/graphics/V-58.png differ
diff --git a/doc/tutorial/graphics/V-59.png b/doc/tutorial/graphics/V-59.png
new file mode 100644
index 0000000..6259368
Binary files /dev/null and b/doc/tutorial/graphics/V-59.png differ
diff --git a/doc/tutorial/graphics/V-6.png b/doc/tutorial/graphics/V-6.png
new file mode 100644
index 0000000..c859ea4
Binary files /dev/null and b/doc/tutorial/graphics/V-6.png differ
diff --git a/doc/tutorial/graphics/V-60.png b/doc/tutorial/graphics/V-60.png
new file mode 100644
index 0000000..00bdf4d
Binary files /dev/null and b/doc/tutorial/graphics/V-60.png differ
diff --git a/doc/tutorial/graphics/V-60bis.png b/doc/tutorial/graphics/V-60bis.png
new file mode 100644
index 0000000..787f384
Binary files /dev/null and b/doc/tutorial/graphics/V-60bis.png differ
diff --git a/doc/tutorial/graphics/V-61.png b/doc/tutorial/graphics/V-61.png
new file mode 100644
index 0000000..38c5493
Binary files /dev/null and b/doc/tutorial/graphics/V-61.png differ
diff --git a/doc/tutorial/graphics/V-62.png b/doc/tutorial/graphics/V-62.png
new file mode 100644
index 0000000..8da8484
Binary files /dev/null and b/doc/tutorial/graphics/V-62.png differ
diff --git a/doc/tutorial/graphics/V-63.png b/doc/tutorial/graphics/V-63.png
new file mode 100644
index 0000000..62dee30
Binary files /dev/null and b/doc/tutorial/graphics/V-63.png differ
diff --git a/doc/tutorial/graphics/V-64.png b/doc/tutorial/graphics/V-64.png
new file mode 100644
index 0000000..dc81ebd
Binary files /dev/null and b/doc/tutorial/graphics/V-64.png differ
diff --git a/doc/tutorial/graphics/V-65.png b/doc/tutorial/graphics/V-65.png
new file mode 100644
index 0000000..53ca0ed
Binary files /dev/null and b/doc/tutorial/graphics/V-65.png differ
diff --git a/doc/tutorial/graphics/V-66.png b/doc/tutorial/graphics/V-66.png
new file mode 100644
index 0000000..1f5bdb8
Binary files /dev/null and b/doc/tutorial/graphics/V-66.png differ
diff --git a/doc/tutorial/graphics/V-67.png b/doc/tutorial/graphics/V-67.png
new file mode 100644
index 0000000..8ba6e25
Binary files /dev/null and b/doc/tutorial/graphics/V-67.png differ
diff --git a/doc/tutorial/graphics/V-68.png b/doc/tutorial/graphics/V-68.png
new file mode 100644
index 0000000..de770d1
Binary files /dev/null and b/doc/tutorial/graphics/V-68.png differ
diff --git a/doc/tutorial/graphics/V-69.png b/doc/tutorial/graphics/V-69.png
new file mode 100644
index 0000000..af55db6
Binary files /dev/null and b/doc/tutorial/graphics/V-69.png differ
diff --git a/doc/tutorial/graphics/V-69bis.png b/doc/tutorial/graphics/V-69bis.png
new file mode 100644
index 0000000..4c9a1cb
Binary files /dev/null and b/doc/tutorial/graphics/V-69bis.png differ
diff --git a/doc/tutorial/graphics/V-7.png b/doc/tutorial/graphics/V-7.png
new file mode 100644
index 0000000..799f3cc
Binary files /dev/null and b/doc/tutorial/graphics/V-7.png differ
diff --git a/doc/tutorial/graphics/V-70.png b/doc/tutorial/graphics/V-70.png
new file mode 100644
index 0000000..4c8345a
Binary files /dev/null and b/doc/tutorial/graphics/V-70.png differ
diff --git a/doc/tutorial/graphics/V-71.png b/doc/tutorial/graphics/V-71.png
new file mode 100644
index 0000000..c84cdde
Binary files /dev/null and b/doc/tutorial/graphics/V-71.png differ
diff --git a/doc/tutorial/graphics/V-72.png b/doc/tutorial/graphics/V-72.png
new file mode 100644
index 0000000..50b7794
Binary files /dev/null and b/doc/tutorial/graphics/V-72.png differ
diff --git a/doc/tutorial/graphics/V-73.png b/doc/tutorial/graphics/V-73.png
new file mode 100644
index 0000000..3e859a9
Binary files /dev/null and b/doc/tutorial/graphics/V-73.png differ
diff --git a/doc/tutorial/graphics/V-73bis.png b/doc/tutorial/graphics/V-73bis.png
new file mode 100644
index 0000000..f35ee98
Binary files /dev/null and b/doc/tutorial/graphics/V-73bis.png differ
diff --git a/doc/tutorial/graphics/V-74.png b/doc/tutorial/graphics/V-74.png
new file mode 100644
index 0000000..f100a21
Binary files /dev/null and b/doc/tutorial/graphics/V-74.png differ
diff --git a/doc/tutorial/graphics/V-74bis.png b/doc/tutorial/graphics/V-74bis.png
new file mode 100644
index 0000000..2c5336b
Binary files /dev/null and b/doc/tutorial/graphics/V-74bis.png differ
diff --git a/doc/tutorial/graphics/V-75.png b/doc/tutorial/graphics/V-75.png
new file mode 100644
index 0000000..7574434
Binary files /dev/null and b/doc/tutorial/graphics/V-75.png differ
diff --git a/doc/tutorial/graphics/V-76.png b/doc/tutorial/graphics/V-76.png
new file mode 100644
index 0000000..126de68
Binary files /dev/null and b/doc/tutorial/graphics/V-76.png differ
diff --git a/doc/tutorial/graphics/V-76bis.png b/doc/tutorial/graphics/V-76bis.png
new file mode 100644
index 0000000..c5d57f2
Binary files /dev/null and b/doc/tutorial/graphics/V-76bis.png differ
diff --git a/doc/tutorial/graphics/V-8.png b/doc/tutorial/graphics/V-8.png
new file mode 100644
index 0000000..8aadd90
Binary files /dev/null and b/doc/tutorial/graphics/V-8.png differ
diff --git a/doc/tutorial/graphics/V-9.png b/doc/tutorial/graphics/V-9.png
new file mode 100644
index 0000000..bf0e796
Binary files /dev/null and b/doc/tutorial/graphics/V-9.png differ
diff --git a/doc/tutorial/graphics/c1_capture01.jpg b/doc/tutorial/graphics/c1_capture01.jpg
deleted file mode 100644
index df71eed..0000000
Binary files a/doc/tutorial/graphics/c1_capture01.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture02.jpg b/doc/tutorial/graphics/c1_capture02.jpg
deleted file mode 100644
index 2a66e3b..0000000
Binary files a/doc/tutorial/graphics/c1_capture02.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture03.jpg b/doc/tutorial/graphics/c1_capture03.jpg
deleted file mode 100644
index 8ff7285..0000000
Binary files a/doc/tutorial/graphics/c1_capture03.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture04.jpg b/doc/tutorial/graphics/c1_capture04.jpg
deleted file mode 100644
index 56f2d03..0000000
Binary files a/doc/tutorial/graphics/c1_capture04.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture05.jpg b/doc/tutorial/graphics/c1_capture05.jpg
deleted file mode 100644
index e2b23e2..0000000
Binary files a/doc/tutorial/graphics/c1_capture05.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture06.jpg b/doc/tutorial/graphics/c1_capture06.jpg
deleted file mode 100644
index c8b462a..0000000
Binary files a/doc/tutorial/graphics/c1_capture06.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture07.jpg b/doc/tutorial/graphics/c1_capture07.jpg
deleted file mode 100644
index e97ad60..0000000
Binary files a/doc/tutorial/graphics/c1_capture07.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture08.jpg b/doc/tutorial/graphics/c1_capture08.jpg
deleted file mode 100644
index e28b38a..0000000
Binary files a/doc/tutorial/graphics/c1_capture08.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture09.jpg b/doc/tutorial/graphics/c1_capture09.jpg
deleted file mode 100644
index 649cef1..0000000
Binary files a/doc/tutorial/graphics/c1_capture09.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture10.jpg b/doc/tutorial/graphics/c1_capture10.jpg
deleted file mode 100644
index 42edc01..0000000
Binary files a/doc/tutorial/graphics/c1_capture10.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture11.jpg b/doc/tutorial/graphics/c1_capture11.jpg
deleted file mode 100644
index 8b48dbf..0000000
Binary files a/doc/tutorial/graphics/c1_capture11.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture12.jpg b/doc/tutorial/graphics/c1_capture12.jpg
deleted file mode 100644
index f73f04e..0000000
Binary files a/doc/tutorial/graphics/c1_capture12.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture13.jpg b/doc/tutorial/graphics/c1_capture13.jpg
deleted file mode 100644
index 46b371f..0000000
Binary files a/doc/tutorial/graphics/c1_capture13.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture14.jpg b/doc/tutorial/graphics/c1_capture14.jpg
deleted file mode 100644
index 12649ec..0000000
Binary files a/doc/tutorial/graphics/c1_capture14.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture15.jpg b/doc/tutorial/graphics/c1_capture15.jpg
deleted file mode 100644
index bf7d896..0000000
Binary files a/doc/tutorial/graphics/c1_capture15.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture16.jpg b/doc/tutorial/graphics/c1_capture16.jpg
deleted file mode 100644
index d561132..0000000
Binary files a/doc/tutorial/graphics/c1_capture16.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture17.jpg b/doc/tutorial/graphics/c1_capture17.jpg
deleted file mode 100644
index ddf586c..0000000
Binary files a/doc/tutorial/graphics/c1_capture17.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture18.jpg b/doc/tutorial/graphics/c1_capture18.jpg
deleted file mode 100644
index 3733f5c..0000000
Binary files a/doc/tutorial/graphics/c1_capture18.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture19.jpg b/doc/tutorial/graphics/c1_capture19.jpg
deleted file mode 100644
index e6c0fbb..0000000
Binary files a/doc/tutorial/graphics/c1_capture19.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture20.jpg b/doc/tutorial/graphics/c1_capture20.jpg
deleted file mode 100644
index cd76668..0000000
Binary files a/doc/tutorial/graphics/c1_capture20.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture21.jpg b/doc/tutorial/graphics/c1_capture21.jpg
deleted file mode 100644
index f60e1d1..0000000
Binary files a/doc/tutorial/graphics/c1_capture21.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture22.jpg b/doc/tutorial/graphics/c1_capture22.jpg
deleted file mode 100644
index 5e07997..0000000
Binary files a/doc/tutorial/graphics/c1_capture22.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture23.jpg b/doc/tutorial/graphics/c1_capture23.jpg
deleted file mode 100644
index 63df8fe..0000000
Binary files a/doc/tutorial/graphics/c1_capture23.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture24.jpg b/doc/tutorial/graphics/c1_capture24.jpg
deleted file mode 100644
index 4180774..0000000
Binary files a/doc/tutorial/graphics/c1_capture24.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture25.jpg b/doc/tutorial/graphics/c1_capture25.jpg
deleted file mode 100644
index 846a8ab..0000000
Binary files a/doc/tutorial/graphics/c1_capture25.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture26.jpg b/doc/tutorial/graphics/c1_capture26.jpg
deleted file mode 100644
index e159fe4..0000000
Binary files a/doc/tutorial/graphics/c1_capture26.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture27.jpg b/doc/tutorial/graphics/c1_capture27.jpg
deleted file mode 100644
index bcf458b..0000000
Binary files a/doc/tutorial/graphics/c1_capture27.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture28.jpg b/doc/tutorial/graphics/c1_capture28.jpg
deleted file mode 100644
index f788aaa..0000000
Binary files a/doc/tutorial/graphics/c1_capture28.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture29.jpg b/doc/tutorial/graphics/c1_capture29.jpg
deleted file mode 100644
index 921d575..0000000
Binary files a/doc/tutorial/graphics/c1_capture29.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture30.jpg b/doc/tutorial/graphics/c1_capture30.jpg
deleted file mode 100644
index f298d2b..0000000
Binary files a/doc/tutorial/graphics/c1_capture30.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture31.jpg b/doc/tutorial/graphics/c1_capture31.jpg
deleted file mode 100644
index 5da39de..0000000
Binary files a/doc/tutorial/graphics/c1_capture31.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture32.jpg b/doc/tutorial/graphics/c1_capture32.jpg
deleted file mode 100644
index 40c6bac..0000000
Binary files a/doc/tutorial/graphics/c1_capture32.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture33.jpg b/doc/tutorial/graphics/c1_capture33.jpg
deleted file mode 100644
index f8b3e33..0000000
Binary files a/doc/tutorial/graphics/c1_capture33.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture34.jpg b/doc/tutorial/graphics/c1_capture34.jpg
deleted file mode 100644
index e74ec92..0000000
Binary files a/doc/tutorial/graphics/c1_capture34.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture35.jpg b/doc/tutorial/graphics/c1_capture35.jpg
deleted file mode 100644
index e97b7c6..0000000
Binary files a/doc/tutorial/graphics/c1_capture35.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture36.jpg b/doc/tutorial/graphics/c1_capture36.jpg
deleted file mode 100644
index 08080f3..0000000
Binary files a/doc/tutorial/graphics/c1_capture36.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture37.jpg b/doc/tutorial/graphics/c1_capture37.jpg
deleted file mode 100644
index 586497e..0000000
Binary files a/doc/tutorial/graphics/c1_capture37.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture38.jpg b/doc/tutorial/graphics/c1_capture38.jpg
deleted file mode 100644
index b6f0a41..0000000
Binary files a/doc/tutorial/graphics/c1_capture38.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture39.jpg b/doc/tutorial/graphics/c1_capture39.jpg
deleted file mode 100644
index 25c2672..0000000
Binary files a/doc/tutorial/graphics/c1_capture39.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture40.jpg b/doc/tutorial/graphics/c1_capture40.jpg
deleted file mode 100644
index 7f0f7de..0000000
Binary files a/doc/tutorial/graphics/c1_capture40.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture41.jpg b/doc/tutorial/graphics/c1_capture41.jpg
deleted file mode 100644
index 7c0d09b..0000000
Binary files a/doc/tutorial/graphics/c1_capture41.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture42.jpg b/doc/tutorial/graphics/c1_capture42.jpg
deleted file mode 100644
index 0075168..0000000
Binary files a/doc/tutorial/graphics/c1_capture42.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c1_capture43.jpg b/doc/tutorial/graphics/c1_capture43.jpg
deleted file mode 100644
index 4aa5bc8..0000000
Binary files a/doc/tutorial/graphics/c1_capture43.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture01.jpg b/doc/tutorial/graphics/c2_capture01.jpg
deleted file mode 100644
index 461d8c4..0000000
Binary files a/doc/tutorial/graphics/c2_capture01.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture02.jpg b/doc/tutorial/graphics/c2_capture02.jpg
deleted file mode 100644
index 431d4c8..0000000
Binary files a/doc/tutorial/graphics/c2_capture02.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture03.jpg b/doc/tutorial/graphics/c2_capture03.jpg
deleted file mode 100644
index 85231e6..0000000
Binary files a/doc/tutorial/graphics/c2_capture03.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture04.jpg b/doc/tutorial/graphics/c2_capture04.jpg
deleted file mode 100644
index ae8bb66..0000000
Binary files a/doc/tutorial/graphics/c2_capture04.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture05.jpg b/doc/tutorial/graphics/c2_capture05.jpg
deleted file mode 100644
index 374774c..0000000
Binary files a/doc/tutorial/graphics/c2_capture05.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture06.jpg b/doc/tutorial/graphics/c2_capture06.jpg
deleted file mode 100644
index 3b0de67..0000000
Binary files a/doc/tutorial/graphics/c2_capture06.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture07.jpg b/doc/tutorial/graphics/c2_capture07.jpg
deleted file mode 100644
index c9fd440..0000000
Binary files a/doc/tutorial/graphics/c2_capture07.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture08.jpg b/doc/tutorial/graphics/c2_capture08.jpg
deleted file mode 100644
index 57f9f6c..0000000
Binary files a/doc/tutorial/graphics/c2_capture08.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture09.jpg b/doc/tutorial/graphics/c2_capture09.jpg
deleted file mode 100644
index 9a27326..0000000
Binary files a/doc/tutorial/graphics/c2_capture09.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture10.jpg b/doc/tutorial/graphics/c2_capture10.jpg
deleted file mode 100644
index a74f23b..0000000
Binary files a/doc/tutorial/graphics/c2_capture10.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture11.jpg b/doc/tutorial/graphics/c2_capture11.jpg
deleted file mode 100644
index 74ece69..0000000
Binary files a/doc/tutorial/graphics/c2_capture11.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture12.jpg b/doc/tutorial/graphics/c2_capture12.jpg
deleted file mode 100644
index 1c6f239..0000000
Binary files a/doc/tutorial/graphics/c2_capture12.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture13.jpg b/doc/tutorial/graphics/c2_capture13.jpg
deleted file mode 100644
index d27dec2..0000000
Binary files a/doc/tutorial/graphics/c2_capture13.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture14.jpg b/doc/tutorial/graphics/c2_capture14.jpg
deleted file mode 100644
index 31b3e7a..0000000
Binary files a/doc/tutorial/graphics/c2_capture14.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture15.jpg b/doc/tutorial/graphics/c2_capture15.jpg
deleted file mode 100644
index 237f349..0000000
Binary files a/doc/tutorial/graphics/c2_capture15.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture152.jpg b/doc/tutorial/graphics/c2_capture152.jpg
deleted file mode 100644
index 193ddb3..0000000
Binary files a/doc/tutorial/graphics/c2_capture152.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture16.jpg b/doc/tutorial/graphics/c2_capture16.jpg
deleted file mode 100644
index 8f8595d..0000000
Binary files a/doc/tutorial/graphics/c2_capture16.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture17.jpg b/doc/tutorial/graphics/c2_capture17.jpg
deleted file mode 100644
index 586c124..0000000
Binary files a/doc/tutorial/graphics/c2_capture17.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture18.jpg b/doc/tutorial/graphics/c2_capture18.jpg
deleted file mode 100644
index ecee4d0..0000000
Binary files a/doc/tutorial/graphics/c2_capture18.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture19.jpg b/doc/tutorial/graphics/c2_capture19.jpg
deleted file mode 100644
index 74c438e..0000000
Binary files a/doc/tutorial/graphics/c2_capture19.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture20.jpg b/doc/tutorial/graphics/c2_capture20.jpg
deleted file mode 100644
index ba8a0ae..0000000
Binary files a/doc/tutorial/graphics/c2_capture20.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture21.jpg b/doc/tutorial/graphics/c2_capture21.jpg
deleted file mode 100644
index 79e0348..0000000
Binary files a/doc/tutorial/graphics/c2_capture21.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture212.jpg b/doc/tutorial/graphics/c2_capture212.jpg
deleted file mode 100644
index c83c88d..0000000
Binary files a/doc/tutorial/graphics/c2_capture212.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture22.jpg b/doc/tutorial/graphics/c2_capture22.jpg
deleted file mode 100644
index 1d8c15d..0000000
Binary files a/doc/tutorial/graphics/c2_capture22.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture23.jpg b/doc/tutorial/graphics/c2_capture23.jpg
deleted file mode 100644
index bf816db..0000000
Binary files a/doc/tutorial/graphics/c2_capture23.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture24.jpg b/doc/tutorial/graphics/c2_capture24.jpg
deleted file mode 100644
index 39abc29..0000000
Binary files a/doc/tutorial/graphics/c2_capture24.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture25.jpg b/doc/tutorial/graphics/c2_capture25.jpg
deleted file mode 100644
index 5e526f9..0000000
Binary files a/doc/tutorial/graphics/c2_capture25.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture26.jpg b/doc/tutorial/graphics/c2_capture26.jpg
deleted file mode 100644
index 691ee20..0000000
Binary files a/doc/tutorial/graphics/c2_capture26.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture27.jpg b/doc/tutorial/graphics/c2_capture27.jpg
deleted file mode 100644
index 5c477d0..0000000
Binary files a/doc/tutorial/graphics/c2_capture27.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture28.jpg b/doc/tutorial/graphics/c2_capture28.jpg
deleted file mode 100644
index e2c1ad5..0000000
Binary files a/doc/tutorial/graphics/c2_capture28.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture29.jpg b/doc/tutorial/graphics/c2_capture29.jpg
deleted file mode 100644
index 26589db..0000000
Binary files a/doc/tutorial/graphics/c2_capture29.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c2_capture30.jpg b/doc/tutorial/graphics/c2_capture30.jpg
deleted file mode 100644
index 43f6144..0000000
Binary files a/doc/tutorial/graphics/c2_capture30.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c3_capture01.jpg b/doc/tutorial/graphics/c3_capture01.jpg
deleted file mode 100644
index 07bced7..0000000
Binary files a/doc/tutorial/graphics/c3_capture01.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c3_capture02.jpg b/doc/tutorial/graphics/c3_capture02.jpg
deleted file mode 100644
index 5cb3edd..0000000
Binary files a/doc/tutorial/graphics/c3_capture02.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c3_capture03.jpg b/doc/tutorial/graphics/c3_capture03.jpg
deleted file mode 100644
index f0b4bc1..0000000
Binary files a/doc/tutorial/graphics/c3_capture03.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c3_capture04.jpg b/doc/tutorial/graphics/c3_capture04.jpg
deleted file mode 100644
index 578f5f7..0000000
Binary files a/doc/tutorial/graphics/c3_capture04.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c3_capture05.jpg b/doc/tutorial/graphics/c3_capture05.jpg
deleted file mode 100644
index bb5019c..0000000
Binary files a/doc/tutorial/graphics/c3_capture05.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c3_capture06.jpg b/doc/tutorial/graphics/c3_capture06.jpg
deleted file mode 100644
index f2d197d..0000000
Binary files a/doc/tutorial/graphics/c3_capture06.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c4_capture01.jpg b/doc/tutorial/graphics/c4_capture01.jpg
deleted file mode 100644
index 0cebd61..0000000
Binary files a/doc/tutorial/graphics/c4_capture01.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c4_capture02.jpg b/doc/tutorial/graphics/c4_capture02.jpg
deleted file mode 100644
index fd9e4c8..0000000
Binary files a/doc/tutorial/graphics/c4_capture02.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture01.jpg b/doc/tutorial/graphics/c5_capture01.jpg
deleted file mode 100644
index 418706d..0000000
Binary files a/doc/tutorial/graphics/c5_capture01.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture02.jpg b/doc/tutorial/graphics/c5_capture02.jpg
deleted file mode 100644
index bad2cef..0000000
Binary files a/doc/tutorial/graphics/c5_capture02.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture03.jpg b/doc/tutorial/graphics/c5_capture03.jpg
deleted file mode 100644
index b086666..0000000
Binary files a/doc/tutorial/graphics/c5_capture03.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture04.jpg b/doc/tutorial/graphics/c5_capture04.jpg
deleted file mode 100644
index e157c8a..0000000
Binary files a/doc/tutorial/graphics/c5_capture04.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture05.jpg b/doc/tutorial/graphics/c5_capture05.jpg
deleted file mode 100644
index 17b405b..0000000
Binary files a/doc/tutorial/graphics/c5_capture05.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture06.jpg b/doc/tutorial/graphics/c5_capture06.jpg
deleted file mode 100644
index 7e72e32..0000000
Binary files a/doc/tutorial/graphics/c5_capture06.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture07.jpg b/doc/tutorial/graphics/c5_capture07.jpg
deleted file mode 100644
index 64cd581..0000000
Binary files a/doc/tutorial/graphics/c5_capture07.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture08.jpg b/doc/tutorial/graphics/c5_capture08.jpg
deleted file mode 100644
index 0e21cc6..0000000
Binary files a/doc/tutorial/graphics/c5_capture08.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture09.jpg b/doc/tutorial/graphics/c5_capture09.jpg
deleted file mode 100644
index bbeaf2d..0000000
Binary files a/doc/tutorial/graphics/c5_capture09.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture10.jpg b/doc/tutorial/graphics/c5_capture10.jpg
deleted file mode 100644
index 21eeefc..0000000
Binary files a/doc/tutorial/graphics/c5_capture10.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture11.jpg b/doc/tutorial/graphics/c5_capture11.jpg
deleted file mode 100644
index e47d64f..0000000
Binary files a/doc/tutorial/graphics/c5_capture11.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture12.jpg b/doc/tutorial/graphics/c5_capture12.jpg
deleted file mode 100644
index 3689d63..0000000
Binary files a/doc/tutorial/graphics/c5_capture12.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/c5_capture13.jpg b/doc/tutorial/graphics/c5_capture13.jpg
deleted file mode 100644
index bb6914f..0000000
Binary files a/doc/tutorial/graphics/c5_capture13.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/capture10.jpg b/doc/tutorial/graphics/capture10.jpg
deleted file mode 100644
index 21eeefc..0000000
Binary files a/doc/tutorial/graphics/capture10.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/capture11.jpg b/doc/tutorial/graphics/capture11.jpg
deleted file mode 100644
index e47d64f..0000000
Binary files a/doc/tutorial/graphics/capture11.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/capture12.jpg b/doc/tutorial/graphics/capture12.jpg
deleted file mode 100644
index 3689d63..0000000
Binary files a/doc/tutorial/graphics/capture12.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/capture13.jpg b/doc/tutorial/graphics/capture13.jpg
deleted file mode 100644
index bb6914f..0000000
Binary files a/doc/tutorial/graphics/capture13.jpg and /dev/null differ
diff --git a/doc/tutorial/graphics/density_law.png b/doc/tutorial/graphics/density_law.png
new file mode 100644
index 0000000..787f384
Binary files /dev/null and b/doc/tutorial/graphics/density_law.png differ
diff --git a/doc/tutorial/graphics/head_loss0.png b/doc/tutorial/graphics/head_loss0.png
new file mode 100644
index 0000000..264690c
Binary files /dev/null and b/doc/tutorial/graphics/head_loss0.png differ
diff --git a/doc/tutorial/graphics/head_loss1.png b/doc/tutorial/graphics/head_loss1.png
new file mode 100644
index 0000000..20ee71b
Binary files /dev/null and b/doc/tutorial/graphics/head_loss1.png differ
diff --git a/doc/tutorial/graphics/head_loss2.png b/doc/tutorial/graphics/head_loss2.png
new file mode 100644
index 0000000..a800951
Binary files /dev/null and b/doc/tutorial/graphics/head_loss2.png differ
diff --git a/doc/tutorial/graphics/head_loss3.png b/doc/tutorial/graphics/head_loss3.png
new file mode 100644
index 0000000..01d7d0f
Binary files /dev/null and b/doc/tutorial/graphics/head_loss3.png differ
diff --git a/doc/tutorial/graphics/head_loss4.png b/doc/tutorial/graphics/head_loss4.png
new file mode 100644
index 0000000..ca0de92
Binary files /dev/null and b/doc/tutorial/graphics/head_loss4.png differ
diff --git a/doc/tutorial/graphics/head_loss5.png b/doc/tutorial/graphics/head_loss5.png
new file mode 100644
index 0000000..f943451
Binary files /dev/null and b/doc/tutorial/graphics/head_loss5.png differ
diff --git a/doc/tutorial/graphics/viscosity_law.png b/doc/tutorial/graphics/viscosity_law.png
new file mode 100644
index 0000000..b32fed2
Binary files /dev/null and b/doc/tutorial/graphics/viscosity_law.png differ
diff --git a/doc/tutorial/intro.tex b/doc/tutorial/intro.tex
index 0e1b452..e9fcf07 100644
--- a/doc/tutorial/intro.tex
+++ b/doc/tutorial/intro.tex
@@ -49,8 +49,7 @@ It presents five simple test cases and guides the future \CS user step by step
 into the preparation and the computation of the cases.
 
 The test case directories, containing the necessary meshes and data
-are available in the \CS Kernel directory:\\
-\texttt{\$CS\_HOME/doc/TUTORIAL/TEST\_CASES}
+are available in the \texttt{examples} directory.
 
 This tutorial focuses on the procedure and the preparation of the \CS
 computations. For more elements on the structure of the code and the definition
diff --git a/doc/tutorial/tuto_case1.tex b/doc/tutorial/tuto_case1.tex
index b64d3d0..2cc350c 100644
--- a/doc/tutorial/tuto_case1.tex
+++ b/doc/tutorial/tuto_case1.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -28,9 +28,11 @@
 The first thing to do before running \CS is to prepare the computation
 directories. In this first example, the study directory ``T\_JUNCTION'' will be
 created, containing a single calculation directory CAS1. This is done by typing
-the command {\itshape cree\_sat -etude T\_JUNCTION CAS1}.
-
-The mesh files should be copied in the directory MAILLAGE.
+the command:
+\begin{center}
+\texttt{code\_saturne create -s T\_JUNCTION -c CASE1}\
+\end{center}
+The mesh files should be copied in the directory MESH.
 
 The \CS Graphical Interface is launched by typing the command
 {\itshape ./SaturneGUI} in the DATA subdirectory of the CAS1 directory.
@@ -38,7 +40,7 @@ The following graphic window opens (fig \ref{fig1_e1}).
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture01}
+\includegraphics[width=13cm]{V-1}
 \caption{User interface}
 \label{fig1_e1}
 \end{center}
@@ -52,7 +54,7 @@ calculation data file, as shown in the figure
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture02}
+\includegraphics[width=13cm]{V-2}
 \caption{Opening a new file}
 \label{fig2_e1}
 \end{center}
@@ -70,7 +72,7 @@ The interface automatically updates the following information:
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture03}
+\includegraphics[width=12cm]{V-3}
 \caption{Identity and paths}
 \label{fig3_e1}
 \end{center}
@@ -87,7 +89,7 @@ Remember to save the case regularly throughout the preparation of the calculatio
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture04}
+\includegraphics[width=10cm]{V-4}
 \caption{Saving the {\itshape XML} file}
 \label{fig4_e1}
 \end{center}
@@ -98,15 +100,15 @@ Remember to save the case regularly throughout the preparation of the calculatio
 The next step is to specify the mesh(es) to be used for the calculation.
 Click on the item {\itshape Solution Domain}
 under the heading {\itshape Analysis environment}. The list of all
-meshes available in the folder {\itshape MAILLAGE} appears in the
+meshes available in the folder {\itshape MESH} appears in the
 window {\itshape List of meshes}. Delete the mesh(es) you will not
 use\footnote{this operation only deletes the selected entries from the list, it
-does not delete the mesh file in the MAILLAGE directory}. In this case only the
+does not delete the mesh file in the MESH directory}. In this case only the
 mesh {\itshape downcomer.des} is needed.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture05}
+\includegraphics[width=12cm]{V-5}
 \caption{Meshes: list of meshes}
 \label{fig5_e1}
 \end{center}
@@ -127,7 +129,7 @@ steady flow will be chosen.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture07}
+\includegraphics[width=12cm]{V-6}
 \caption{Flow type}
 \label{fig7_e1}
 \end{center}
@@ -149,7 +151,7 @@ The turbulence model is selected in the following list:\\
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture09}
+\includegraphics[width=12cm]{V-7}
 \caption{Turbulence model: list of models}
 \label{fig9_e1}
 \end{center}
@@ -161,7 +163,7 @@ In this case, the k-$\varepsilon$ model is used.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture10}
+\includegraphics[width=9cm]{V-8}
 \caption{Turbulence model: choice of a model}
 \label{fig10_e1}
 \end{center}
@@ -179,7 +181,7 @@ choose between:\\
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture11}
+\includegraphics[width=12cm]{V-9}
 \caption{Thermal scalar conservation: list of models}
 \label{fig11_e1}
 \end{center}
@@ -190,33 +192,17 @@ choose between:\\
 In the present case, select {\itshape Temperature (Celsius degrees)}.
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture12}
+\includegraphics[width=9cm]{V-10}
 \caption{Thermal scalar conservation: choice of a model}
 \label{fig12_e1}
 \end{center}
 \end{figure}
 
-There are no radiative transfers in our case, so the item is ignored.
-
-\clearpage
-To initialize variables at the instant $t=0\ s$, go to the item {\itshape Initialization}.
-Here the velocity, the thermal scalar and the turbulence can be initialized. In
-this case, the default values can be kept: zero velocity, an initial temperature
-of 20\degresC\ and a turbulence level based on a reference velocity of $1\
-m.s^{-1}$. Specific zones can be defined with different initializations. In this
-case, only the default ``all cells'' is used.
-
-\begin{figure}[ht]
-\begin{center}
-\includegraphics[width=12cm]{c1_capture14}
-\caption{Initialization of dynamic variables}
-\label{fig14_e1}
-\end{center}
-\end{figure}
-
+Once the thermal scalar selected, additional items appear.
+There are no radiative transfers in our case, so this item can be ignored.
 
 \clearpage
-The initial value for the thermal scalar also appears in the item
+To initialize the thermal scalar, go to the item
 {\itshape Definition and Initialization} under the heading
 {\itshape Additional scalars}, where more options concerning the scalars can be
 specified. The value of the initial value can be modified in any of the two
@@ -226,7 +212,7 @@ Additional scalars} page.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture15}
+\includegraphics[width=12cm]{V-12}
 \caption{Initialization of the scalar}
 \label{fig15_e1}
 \end{center}
@@ -242,12 +228,10 @@ Click on the thermal scalar in the list, to change:
         \item its maximal value
 \end{itemize}
 In this case the temperature can vary between 0\degresC\ and 400\degresC.
-After entering the new values, click on {\itshape Modify} in order to validate
-these changes.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture16}
+\includegraphics[width=8cm]{V-13}
 \caption{Initialization of the scalar}
 \label{fig16_e1}
 \end{center}
@@ -267,7 +251,7 @@ Use the default value of $101\,300\ Pa$.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture17}
+\includegraphics[width=12cm]{V-14}
 \caption{Physical properties: reference pressure}
 \label{fig17_e1}
 \end{center}
@@ -294,7 +278,7 @@ In this case they are all constant.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture18}
+\includegraphics[width=12cm]{V-15}
 \caption{Physical properties: fluid properties}
 \label{fig18_e1}
 \end{center}
@@ -311,12 +295,29 @@ default value.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture19}
+\includegraphics[width=12cm]{V-16}
 \caption{Physical properties: gravity, hydrostatic pressure}
 \label{fig19_e1}
 \end{center}
 \end{figure}
 
+\clearpage
+To initialize variables at the instant $t=0\ s$, go to the item {\itshape Initialization} under the heading {\itshape Volume conditions}.
+Here the velocity, the thermal scalar and the turbulence can be initialized. In
+this case, the default values can be kept: zero velocity, an initial temperature
+of 20\degresC\ (consistant with previous initialization) and a turbulence level based on a reference velocity of $1\
+m.s^{-1}$. Specific zones can be defined with different initializations. In this
+case, only the default ``all cells'' is used.
+
+\begin{figure}[ht]
+\begin{center}
+\includegraphics[width=12cm]{V-11}
+\caption{Initialization of dynamic variables}
+\label{fig14_e1}
+\end{center}
+\end{figure}
+
+
 
 \clearpage
 Boundary conditions now need to be defined. Go to the item {\itshape Define
@@ -325,7 +326,7 @@ The following window opens (fig \ref{fig20_e1}).
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture20}
+\includegraphics[width=12cm]{V-17}
 \caption{Creation of a boundary region}
 \label{fig20_e1}
 \end{center}
@@ -333,9 +334,10 @@ The following window opens (fig \ref{fig20_e1}).
 
 
 \clearpage
-Each boundary must be defined. The boundary faces will be grouped in
+Each boundary must be defined. Click on {\itshape Add} to edit a new boundary. 
+The boundary faces will be grouped in
 user-defined zones, based on their color or on geometrical conditions. For each
-zone, a reference number, a label, a nature and a localization condition must be
+zone, a reference number, a label, a nature and a selection criteria must be
 assigned.
 The different natures that can be assigned are:\\
 \hspace*{1cm}$\bullet\ $wall\\
@@ -349,13 +351,13 @@ zone more easily. It usually corresponds to the nature of the zone.
 The {\itshape Zone} number can be any integer. It will be used by the code to
 identify the zone. No specific order or continuity in the numbering is needed.
 
-The {\itshape Localization} is used to define the faces that belong to the
+The {\itshape Selection criteria} is used to define the faces that belong to the
 zone. It can be a color number, a group reference, geometrical conditions, on a
 combination of them, related by ``or'' or ``and'' keywords.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture21}
+\includegraphics[width=8cm]{V-18}
 \caption{Creation of a boundary region}
 \label{fig21_e1}
 \end{center}
@@ -368,28 +370,15 @@ pages. The settings will be as follows:\\
 \hspace*{1cm}$\bullet\ ${\itshape Label}: inlet\\
 \hspace*{1cm}$\bullet\ ${\itshape Zone}: 1\\
 \hspace*{1cm}$\bullet\ ${\itshape Nature}: inlet\\
-\hspace*{1cm}$\bullet\ ${\itshape Localization}: 1
+\hspace*{1cm}$\bullet\ ${\itshape Selection criteria}: 1
 
-\begin{figure}[ht]
-\begin{center}
-\includegraphics[width=12cm]{c1_capture22}
-\caption{Creation of a boundary region: inlet region}
-\label{fig22_e1}
-\end{center}
-\end{figure}
-
-
-
-\clearpage
-After typing all the information, click on {\itshape Create} to
-create the boundary zone. It appears in the
-{\itshape Define Boundary regions} list above.
+Type all the information in the fields, the result diplays as figure \ref{fig20_e1}
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture23}
-\caption{Creation of a boundary region: inlet region}
-\label{fig23_e1}
+\includegraphics[width=8cm]{V-20}
+\caption{Creation of a boundary region}
+\label{fig20_e1}
 \end{center}
 \end{figure}
 
@@ -416,7 +405,7 @@ the string ``8 or 9''.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture24}
+\includegraphics[width=8cm]{V-21}
 \caption{Creation of boundary regions: symmetry region}
 \label{fig24_e1}
 \end{center}
@@ -432,7 +421,7 @@ figure \ref{fig25_e1}.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture25}
+\includegraphics[width=8cm]{V-22}
 \caption{Creation of boundary regions}
 \label{fig25_e1}
 \end{center}
@@ -442,14 +431,12 @@ figure \ref{fig25_e1}.
 \clearpage
 Now that the boundary zones are defined, the boundary conditions assigned to
 them will be specified. Click on the item
-{\itshape Dynamic variables boundary} to set the boundary conditions for
-velocity and turbulence. As shown on figure \ref{fig26_e1}, only the inlet and
-wall boundary zones appear in the window. Indeed, symmetry and outlet conditions
-do not need any user-defined data.
+{\itshape Boundary conditions} to set the inlet boundary conditions for
+velocity and turbulence. As shown on figure \ref{fig26_e1}, outlet and wall boundary zones also appear in the window.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture26}
+\includegraphics[width=12cm]{V-23}
 \caption{Dynamic variables boundary conditions}
 \label{fig26_e1}
 \end{center}
@@ -457,17 +444,17 @@ do not need any user-defined data.
 
 
 \clearpage
-Click on the label {\itshape inlet}. Enter the three components of the inlet
+Click on the label {\itshape inlet}. In the section {\itshape Velocity}, select {\itshape norm}, then in the sub-section {\itshape Direction} choose {\itshape specified ccordinates} and enter the normal vector components of the inlet
 velocity. For the turbulence, chose the inlet condition based on a hydraulic
 diameter and specify it.\\
-\hspace*{1cm}$\bullet\ U = 1\ m.s^{-1}$\\
-\hspace*{1cm}$\bullet\ V = 0\ m.s^{-1}$\\
-\hspace*{1cm}$\bullet\ W = 0\ m.s^{-1}$\\
+\hspace*{1cm}$\bullet\ X = 1\ m$\\
+\hspace*{1cm}$\bullet\ Y = 0\ m$\\
+\hspace*{1cm}$\bullet\ Z = 0\ m$\\
 \hspace*{1cm}$\bullet\ D = 0.5\ m$
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture27}
+\includegraphics[width=9cm]{V-24}
 \caption{Dynamic variables boundary: inlet}
 \label{fig27_e1}
 \end{center}
@@ -475,16 +462,16 @@ diameter and specify it.\\
 
 
 \clearpage
-As for the wall boundary zone, the only specification the user might have to
-give is when the wall is sliding. In this case, the walls are fixed so the
-option is left ``off''.
+As for the wall boundary zone, the specifications the user might have to
+give is when the wall is sliding, and if the wall is "smooth" or "rough". In this case, the walls are fixed so the
+option is not selected, and the wall is considered as "smooth".
 
 Note that if one of the walls had been sliding, it would have been necessary to
 isolate the corresponding boundary faces in a specific boundary region.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture28}
+\includegraphics[width=9cm]{V-25}
 \caption{Dynamic variables boundary: walls}
 \label{fig28_e1}
 \end{center}
@@ -492,35 +479,25 @@ isolate the corresponding boundary faces in a specific boundary region.
 
 
 \clearpage
-click on the item {\itshape Scalars boundaries} to set the boundary conditions
-on the scalar. Only inlets, outlets and walls are concerned.
+The boundary conditions
+on the temperature are only applied on inlets, outlets and walls.
 
 For the walls, three conditions are available:\\
-\hspace*{1cm}$\bullet\ ${\itshape Dirichlet}\\
-\hspace*{1cm}$\bullet\ ${\itshape Neumann}\\
+\hspace*{1cm}$\bullet\ ${\itshape Prescribed value}\\
+\hspace*{1cm}$\bullet\ ${\itshape Prescribed flux}\\
 \hspace*{1cm}$\bullet\ ${\itshape Exchange Coefficient}
 
-For the outlet, only Dirichlet and Neumann conditions are available, but they are
-taken into account only when the flow re-enters from the oultet. Otherwise,
-homogeneous Neumann is considered by \CS.
-
-For the inlets, only a Dirichlet condition is available.
-
-\begin{figure}[ht]
-\begin{center}
-\includegraphics[width=12cm]{c1_capture29}
-\caption{Scalars boundaries}
-\label{fig29_e1}
-\end{center}
-\end{figure}
+For the outlet, only {\itshape Prescribed value} and {\itshape Prescribed flux} are available, but they are
+taken into account only when the flow re-enters from the outlet. Otherwise,
+homogeneous {\itshape Prescribed flux} is considered by \CS.
 
+For the inlets, only {\itshape Prescribed value} is available.
 
-\clearpage
 In this case all walls are adiabatic. So the boundary condition for the
-temperature will be a {\itshape Neumann} condition with 0 for the value.
+temperature will be a {\itshape Prescribed flux} set to 0.
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture30}
+\includegraphics[width=10cm]{V-27}
 \caption{Scalars boundaries: walls}
 \label{fig30_e1}
 \end{center}
@@ -534,7 +511,7 @@ The default value is left for the outlet.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture31}
+\includegraphics[width=10cm]{V-28}
 \caption{Scalars boundaries: inlet}
 \label{fig31_e1}
 \end{center}
@@ -543,16 +520,16 @@ The default value is left for the outlet.
 
 \clearpage
 The calculation parameters need then to be specified, under the header {\itshape
-Analysis control}.
+Numerical parameters}.
 
-Go to the item {\itshape Steady management} to specify the number of iterations,
+Go to the item {\itshape Steady flow management} to specify the number of iterations,
 30 in this case. The default value of the relaxation
-coefficient will be kept and  the
-{\itshape Option zero iteration} will not be activated.
+coefficient will be kept and  the {\itshape Zero iteration option} 
+will not be activated.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture32}
+\includegraphics[width=12cm]{V-29}
 \caption{Steady flow management}
 \label{fig32_e1}
 \end{center}
@@ -560,7 +537,28 @@ coefficient will be kept and  the
 
 
 \clearpage
-Click on the item {\itshape Output control} to change the frequency for the
+After selecting the item {\itshape Equation parameters}, the tab {\itshape Scheme} allows to change different more
+advanced numerical parameters. In this case none of them should be changed from
+their default value.
+
+\begin{figure}[!h]
+\begin{center}
+\includegraphics[width=11cm]{V-34}
+\caption{Numerical parameters}
+\label{fig3738_e1}
+\end{center}
+\end{figure}
+
+\begin{figure}[!h]
+\begin{center}
+\includegraphics[width=11cm]{V-34bis}
+\caption{Numerical parameters}
+\label{fig3738bis_e1}
+\end{center}
+\end{figure}
+
+\clearpage
+Under the heading {\itshape Calculation control}, click on the item {\itshape Output control} to change the frequency for the
 printing of information in the output listing.
 The options are:\\
 \hspace*{1cm}$\bullet\ ${\itshape No output}\\
@@ -571,7 +569,7 @@ Here and in most cases, the second option should be chosen.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture33}
+\includegraphics[width=12cm]{V-30}
 \caption{Output control: output listing}
 \label{fig33_e1}
 \end{center}
@@ -579,16 +577,17 @@ Here and in most cases, the second option should be chosen.
 
 
 \clearpage
-For the post-processing (by default EnSight format files), there are two options:\\
+For the post-processing (by default EnSight format files), there are three options:\\
 \hspace*{1cm}$\bullet\ ${\itshape Only at the end of calculation}\\
-\hspace*{1cm}$\bullet\ ${\itshape Chronologics at each 'n' time steps}
+\hspace*{1cm}$\bullet\ ${\itshape At each time step}\\
+\hspace*{1cm}$\bullet\ ${\itshape Post-processing every 'n' time steps}
 
 In this case, we are interested in the evolution of the variables during the
-calculation, so the second option is chosen with a value of 1 for 'n'.
+calculation, so the second option is chosen.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture34}
+\includegraphics[width=8cm]{V-31}
 \caption{Output control: post-processing}
 \label{fig34_e1}
 \end{center}
@@ -600,20 +599,20 @@ The other options are kept to their default value.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture35}
+\includegraphics[width=8cm]{V-32}
 \caption{Output control}
 \label{fig35_e1}
 \end{center}
 \end{figure}
 
-The {\itshape Monitoring points management} tab allows to define specific points
+The {\itshape Monitoring Points Coordinates} tab allows to define specific points
 in the domain (monitoring probes) where the time evolution of the different
 variables will be stored in historic files. In this case no monitoring points
 are defined.
 
 
 \clearpage
-The item {\itshape Solution control} allows to specify which variable will
+The item {\itshape Volume solution control} allows to specify which variable will
 appear in the output listing, in the post-processing files or on the
 monitoring probes. In this case, the default value is kept, where every variable
 is activated.
@@ -621,7 +620,7 @@ is activated.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture36}
+\includegraphics[width=12cm]{V-33}
 \caption{Solution control}
 \label{fig36_e1}
 \end{center}
@@ -629,31 +628,20 @@ is activated.
 
 
 \clearpage
-The heading {\itshape Numerical parameters} allows to change different more
-advanced numerical parameters. In this case none of them should be changed from
-their default value.
-
-\begin{figure}[!h]
-\begin{center}
-\begin{tabular}{c}
-\includegraphics[width=9cm]{c1_capture37}\\
-\includegraphics[width=9cm]{c1_capture38}
-\end{tabular}
-\caption{Numerical parameters}
-\label{fig3738_e1}
-\end{center}
-\end{figure}
-
-
-\clearpage
 When using Fortran routines, it is sometimes useful to allocate pre-defined user
 arrays, that are present in every sub-routine. This allocation can be specified
 in the {\itshape User arrays} item, under the {\itshape Calculation management}
-heading. It is not the case in the present calculation.
+heading. It is not the case in the present calculation.\\
+
+The item {\itshape Memory management} allows to set the
+memory size for the calculation. It is the size of the integer and real arrays that will be used to store most of the variables in the Fortran parts of \CS.
+It is dependent on the number of cells in the mesh. In parallel mode, it depends
+on the number of cells treated by each processor, and not the total number of
+cells. For this simple case, the default values are appropriate.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture39}
+\includegraphics[width=12cm]{V-35}
 \caption{User arrays}
 \label{fig39_e1}
 \end{center}
@@ -667,7 +655,7 @@ nothing has to be modified.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture40}
+\includegraphics[width=12cm]{V-36}
 \caption{Start/Restart}
 \label{fig40_e1}
 \end{center}
@@ -675,7 +663,7 @@ nothing has to be modified.
 
 
 \clearpage
-The final item, {\itshape Prepare batch analysis}, is used to prepare the launch
+The final item, {\itshape Prepare batch calculation}, is used to prepare the launch
 script and, on certain architectures, launch the calculation.
 
 Calculations can be launched from the Graphical Interface in interactive mode
@@ -684,7 +672,7 @@ PBS}). In this simple case, choose the Workstation.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture41}
+\includegraphics[width=10cm]{V-37}
 \caption{Prepare batch analysis: Computer selection}
 \label{fig41_e1}
 \end{center}
@@ -693,14 +681,14 @@ PBS}). In this simple case, choose the Workstation.
 
 \clearpage
 Click on the icon to {\itshape Select the batch script file} to select the
-launch script. The default launch script is named {\itshape lance} and is
-situated in the SCRIPTS directory. Select it and click on {\itshape Open}.
+launch script. The default launch script is named {\itshape runcase} and is
+located in the SCRIPTS directory. Select it and click on {\itshape Open}.
 
 Remember to save the Xml file before opening the launch script.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture42}
+\includegraphics[width=12cm]{V-38}
 \caption{Prepare batch analysis: Batch script file selection}
 \label{fig42_e1}
 \end{center}
@@ -708,13 +696,7 @@ Remember to save the Xml file before opening the launch script.
 
 
 \clearpage
-When the script is selected, new options will appear. They allow to give the
-memory size for the calculation. It is the size of the integer and real arrays
-that will be used to store most of the variables in the Fortran parts of \CS.
-It is dependent on the number of cells in the mesh. In parallel mode, it depends
-on the number of cells treated by each processor, and not the total number of
-cells. For this simple case, the default values are appropriate.
-
+When the script is selected, new options will appear.
 On this calculation, the number of processors used will be left to 1.
 
 When launching a calculation, a temporary directory is created on the machine,
@@ -730,12 +712,12 @@ Finally, the {\itshape Advanced options} icon allows to change some more
 advanced parameters that will not be needed in this simple case.
 
 Eventually, save the Xml file and execute it by clicking on
-{\itshape \CS batch running}. The results will be copied in the RESU
+\CS {\itshape batch running}. The results will be copied in the RESU
 directory.
 
 \begin{figure}[ht]
 \begin{center}
-\includegraphics[width=12cm]{c1_capture43}
+\includegraphics[width=10cm]{V-39}
 \caption{Prepare batch analysis: Execution}
 \label{fig43_e1}
 \end{center}
diff --git a/doc/tutorial/tuto_case2.tex b/doc/tutorial/tuto_case2.tex
index 105dd49..050ac8c 100644
--- a/doc/tutorial/tuto_case2.tex
+++ b/doc/tutorial/tuto_case2.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -27,30 +27,29 @@
 \section{SOLUTION FOR CASE 2}
 This case corresponds to a new study, in which there will be three calculation
 cases (cases 2, 3 and 4). All of them can be created in a single {\itshape
-cree\_sat} command, or additional cases can be added later. To test both
+code\_saturne create} command, or additional cases can be added later. To test both
 possibilities, first create the study directory, with cases directories CAS2
 and CAS4:\\
-{\itshape cree\_sat -etude FULL\_DOMAIN CAS2 CAS4}\\
+{\itshape code\_saturne create -s FULL\_DOMAIN CAS2 CAS4}\\
 then go in the study directory and add the CAS3 directory:\\
 {\itshape cd FULL\_DOMAIN}\\
-{\itshape cree\_sat -cas CAS3}
+{\itshape code\_saturne create -c CAS3}
 
-Go to the SCRIPT directory in CAS2,
+Go to the DATA directory in CAS2,
 open a new case and select the meshes to use. Click on the
-item {\itshape Solution Domain}. In this case the three meshes have to be
-pasted. So don't delete any mesh and activate the {\itshape Paste mesh} option by
-clicking it {\itshape on}. Additional information appears on the page. If it is
+heading {\itshape Calculation environment} then on the item {\itshape Meshes selection}. In this case the three meshes have to be
+joined. So don't delete any mesh and activate the {\itshape Join meshes} option by clicking in the box. Additional information appears on the page. If it is
 left untouched, the \CS Preprocessor will test all the boundary faces for
-potential pasting (based on geometrical criteria). To make mesh pasting more
+potential joining (based on geometrical criteria). To make mesh joining more
 efficient, this analysis can be restricted to a sub-set of boundary faces. This
-is the case in the present calculation, since only faces of colors 5, 24 and 34
-are liable to be pasted.
+is the case in the present calculation, since only faces of colors 5, 24 and 32
+are liable to be joined.
 
-Click on the {\itshape Add} icon to enter the list of colors to be pasted.
+Click on the {\itshape New} icon to enter the list of colors to be joined.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture02}
+\includegraphics[width=12cm]{V-40}
 \caption{Meshes: list of meshes}
 \label{fig2_e2}
 \end{center}
@@ -58,30 +57,14 @@ Click on the {\itshape Add} icon to enter the list of colors to be pasted.
 
 
 \newpage
-Clicking on {\itshape Add} opens a new window. Fill in the
-{\itshape Input references} for the color reference to be pasted: 5, 24 and 32.
-(different colors can be entered on a single line, separated by blanks). They
-will appear in the area above. Then click on {\itshape Validate}.
-
-
-\begin{figure}[h!]
-\begin{center}
-\includegraphics[width=12cm]{c2_capture04}
-\caption{Meshes: Join a mesh}
-\label{fig4_e2}
-\end{center}
-\end{figure}
-
-
-\newpage
-The Preprocessor command for mesh pasting is now visible in the window (Fig
-\ref{fig5_e2}). It will automatically be transfered into the launch script when
-it is edited by the Interface.
+Fill the array
+{\itshape References} for the color reference to be joined: 5, 24 and 32.
+(different colors can be entered on a single line, separated by blanks).
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture05}
-\caption{Meshes}
+\includegraphics[width=12cm]{V-41}
+\caption{Join a Mesh}
 \label{fig5_e2}
 \end{center}
 \end{figure}
@@ -93,7 +76,7 @@ In this case ``Unsteady flow'' must be selected in the
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture06}
+\includegraphics[width=12cm]{V-43}
 \caption{Thermophysical models - Analysis features - Unsteady flow}
 \label{fig6_e2}
 \end{center}
@@ -111,18 +94,16 @@ The characteristics of the thermal scalar are still the
 same. Its initial value is 20\degresC\ and it can vary between
 0\degresC\ and 400\degresC.
 
-To create an additional scalar, enter:\\
+To create an additional scalar, click on {\itshape Add}, then enter:\\
 \hspace*{1cm}$\bullet\ $its {\itshape Name}: scalar\_2\\
 \hspace*{1cm}$\bullet\ $its {\itshape Initial value}: 10\\
 \hspace*{1cm}$\bullet\ $its {\itshape Minimal value}: 0\\
 \hspace*{1cm}$\bullet\ $its {\itshape Maximal value}: 400
 
-Then click on {\itshape Create}; the scalar will appear on the list,
-below the thermal scalar.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture08}
+\includegraphics[width=12cm]{V-44}
 \caption{Additional scalar - User scalar definition}
 \label{fig8_e2}
 \end{center}
@@ -138,7 +119,7 @@ $0.895\times 10^{-4}\ m^{2}.s^{-1}$
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture09}
+\includegraphics[width=12cm]{V-45}
 \caption{Additional scalar - User scalar physical properties}
 \label{fig9_e2}
 \end{center}
@@ -148,7 +129,7 @@ $0.895\times 10^{-4}\ m^{2}.s^{-1}$
 \newpage
 Create the boundary zones. The procedure is the same as in case 1, but the
 colors are different. Note that colors 5 and 32 have completely disappeared in
-the pasting process (they are now internal faces and are not considered as
+the joining process (they are now internal faces and are not considered as
 boundaries), while some boundary faces of color 24 remain.\\
 Create the inlet, outlet
 and symmetry boundary zones with the following colors:\\
@@ -158,7 +139,7 @@ and symmetry boundary zones with the following colors:\\
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture10}
+\includegraphics[width=12cm]{V-46}
 \caption{Creation of the boundary zones}
 \label{fig10_e2}
 \end{center}
@@ -182,8 +163,8 @@ wall\_6 & 9 & wall & 31 or 33 \\
 \end{center}
 
 The ``wall\_1'' region combines color and geometrical criteria. The associated
-character string to enter in the ``Localization'' box is as follows:\\
-``24 and 0.1$<$=X and 0.5$>$=X''\footnote{Note that, due to the pasting process,
+character string to enter in the ``Selection criteria'' box is as follows:\\
+``24 and 0.1$<$=X and 0.5$>$=X''\footnote{Note that, due to the joining process,
 there are in fact no boundary faces of color 24 with X coordinate outside the
 [0.1;0.5] intervalle. The geometrical criterium is therefore not
 necessary. It is presented here to show the capacity of the face selection
@@ -191,7 +172,7 @@ module}.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture11}
+\includegraphics[width=10cm]{V-47}
 \caption{Creation of a wall boundary region}
 \label{fig11_e2}
 \end{center}
@@ -204,7 +185,7 @@ two separate zones, based on a geometrical criterium on $Y$.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture152}
+\includegraphics[width=9cm]{V-48}
 \caption{Creation of wall boundary regions}
 \label{fig152_e2}
 \end{center}
@@ -218,7 +199,7 @@ there are still no sliding walls.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture16}
+\includegraphics[width=12cm]{V-49}
 \caption{Dynamic variables boundary: inlet}
 \label{fig16_e2}
 \end{center}
@@ -226,34 +207,33 @@ there are still no sliding walls.
 
 
 \newpage
-To configure the scalar boundary conditions, click on the item
-{\itshape Scalars boundaries}.
-On all the walls, a default homogeneous Neumann condition is set for
-temperature, and Dirichlet conditions are specified for the passive scalar,
+To configure the scalar boundary conditions on the walls, select individually each wall in the item {\itshape Boundary conditions}.
+On all the walls, a default homogeneous prescribed flux is set for
+temperature, and prescribed values are specified for the passive scalar,
 according to the following table:
 \begin{center}
 \begin{tabular}{|c|c|c|}
 \hline
 Wall & Nature & Value \\
 \hline
-wall\_1 & Dirichlet  & 0 \\
+wall\_1 & Prescribed value  & 0 \\
 \hline
-wall\_2 & Dirichlet  & 5 \\
+wall\_2 & Prescribed value  & 5 \\
 \hline
-wall\_3 & Dirichlet  & 0 \\
+wall\_3 & Prescribed value  & 0 \\
 \hline
-wall\_4 & Dirichlet  & 25 \\
+wall\_4 & Prescribed value  & 25 \\
 \hline
-wall\_5 & Dirichlet  & 320 \\
+wall\_5 & Prescribed value  & 320 \\
 \hline
-wall\_6 & Dirichlet  & 40 \\
+wall\_6 & Prescribed value  & 40 \\
 \hline
 \end{tabular}
 \end{center}
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture21}
+\includegraphics[width=9cm]{V-50}
 \caption{Scalars boundaries: wall\_5}
 \label{fig21_e2}
 \end{center}
@@ -266,7 +246,7 @@ for temperature and 200 for the passive scalar.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture22}
+\includegraphics[width=8cm]{V-51}
 \caption{Scalars boundaries: inlet}
 \label{fig22_e2}
 \end{center}
@@ -276,25 +256,26 @@ for temperature and 200 for the passive scalar.
 \newpage
 Some calculation parameters now need to be defined.
 Go to the item {\itshape Time step} under the heading
-{\itshape Analysis control}. In our case the time step is
+{\itshape Numerical parameters}. In our case the time step is
 {\itshape Uniform and constant}. Set the number of iterations to 300 and the
 reference time step to $0.05\ s$.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture23}
+\includegraphics[width=12cm]{V-52}
 \caption{Time step setting}
 \label{fig23_e2}
 \end{center}
 \end{figure}
 
+No change is needed in the {\itshape Equation parameters} and {\itshape Global parameters} items.
 
 \newpage
-Go to the item {\itshape Output control} to set the output parameters.
+Go to the item {\itshape Output control} under the heading {\itshape Calculation control} to set the output parameters.
 
 Keep the default value for the output listing frequency.
 
-For the Post-processing, select the second option (output every 'n' time steps)
+For the Post-processing, select the third option (output every 'n' time steps)
 and set the value of 'n' to 2.
 
 Activate the post-processing on the boundary faces by ticking the
@@ -305,7 +286,7 @@ the boundary conditions for the passive scalar have been properly set.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture24}
+\includegraphics[width=12cm]{V-53}
 \caption{Output control: post-processing}
 \label{fig24_e2}
 \end{center}
@@ -315,11 +296,11 @@ the boundary conditions for the passive scalar have been properly set.
 \newpage
 In this case, chronological records on specified monitoring probes are needed.
 To define the probes, click on the
-{\itshape Monitoring points management} tab.
+{\itshape Monitoring points Coordinates} tab.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture25}
+\includegraphics[width=12cm]{V-54}
 \caption{Output control: monitoring points}
 \label{fig25_e2}
 \end{center}
@@ -328,27 +309,15 @@ To define the probes, click on the
 
 
 \newpage
-Enter the coordinates of the monitoring points you want to define. For the first point:\\
+Click on ``Add'' and enter the coordinates of the monitoring points you want to define. For the first point:\\
 \hspace*{1cm}$\bullet\ X = -0.25\ m$\\
 \hspace*{1cm}$\bullet\ Y = 2.25\ m$\\
 \hspace*{1cm}$\bullet\ Z = 0\ m$
 
-\begin{figure}[h!]
-\begin{center}
-\includegraphics[width=12cm]{c2_capture26}
-\caption{Output controls: monitoring points - $1^{st}$ point}
-\label{fig26_e2}
-\end{center}
-\end{figure}
-
-
-\newpage
-Then click on the {\itshape Add} button. The newly created point will appear in
-the window above.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture27}
+\includegraphics[width=8cm]{V-56}
 \caption{Output controls: monitoring points - $1^{st}$ point}
 \label{fig27_e2}
 \end{center}
@@ -382,7 +351,7 @@ Points & X(m) & Y(m) \\
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture28}
+\includegraphics[width=9cm]{V-57}
 \caption{Output control: monitoring points}
 \label{fig28_e2}
 \end{center}
@@ -392,7 +361,7 @@ Remember to save the Xml file regularly.
 
 
 \newpage
-Go to the item {\itshape Solution control} to define which variables will
+Go to the item {\itshape Volume solution control} to define which variables will
 appear in the listing, the post-processing and the chronological records.
 
 Uncheck the boxes in front of the {\itshape Pressure}, {\itshape Tubulent energy}
@@ -406,7 +375,7 @@ variables will be removed from the post-processing results.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture29}
+\includegraphics[width=12cm]{V-58}
 \caption{Solution control - Output configuration}
 \label{fig29_e2}
 \end{center}
@@ -416,19 +385,18 @@ variables will be removed from the post-processing results.
 \newpage
 Delete all the probe numbers for the {\itshape total\_pressure} variable. No
 chronological record will be created for this variable. As for the
-{\itshape VelocitU} variable, only select probes  1, 2, 6, 7 and 8. Time
+{\itshape VelocitX} variable, only select probes  1, 2, 6, 7 and 8. Time
 evolution on the other probes will not be recorded.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c2_capture30}
+\includegraphics[width=10cm]{V-59}
 \caption{Solution control - Probes}
 \label{fig30_e2}
 \end{center}
 \end{figure}
 
 
-No change is needed under the {\itshape Numerical parameters} heading.
 Switch to the {\itshape Calculation management} heading to prepare the launch
 script and run the calculation.
 
diff --git a/doc/tutorial/tuto_case3.tex b/doc/tutorial/tuto_case3.tex
index 46ede71..8167161 100644
--- a/doc/tutorial/tuto_case3.tex
+++ b/doc/tutorial/tuto_case3.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -31,29 +31,29 @@ Only a few elements are different from case 2.
 In this case the density becomes variable. Go to the item
 {\itshape Fluid properties} under the heading
 {\itshape Physical properties} and change the nature of the density from
-{\itshape constant} to {\itshape variable}.
+{\itshape constant} to {\itshape user law}. Click on the highlighted icon and define the user law in the window that pops up. Follow the format used in the tab ``Examples''.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c3_capture01}
+\begin{tabular}{c}
+\includegraphics[width=9cm]{V-60} \\
+\\
+\includegraphics[width=9cm]{V-60bis}
+\end{tabular}
 \caption{Fluid properties - Variable density}
 \label{fig1_e3}
 \end{center}
 \end{figure}
 
-
 \newpage
 As the density is variable, the influence of gravity has to be considered. In the
 heading {\itshape Physical properties} go to
 {\itshape Gravity, hydrostatic pressure} and set the value of each component of
-the gravity vector. If the norm of gravity is the standard $9.81\ m.s^{-2}$, a
-alternative way to define gravity is to specify its direction in the component
-boxes, (0;-1;0) in our case, and click on the icon below to renormalize the
-vector to 9.81.
+the gravity vector.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c3_capture02}
+\includegraphics[width=12cm]{V-61}
 \caption{Fluid properties - Gravity}
 \label{fig2_e3}
 \end{center}
@@ -76,7 +76,7 @@ Points & X(m) & Y(m) & Z(m)\\
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c3_capture03}
+\includegraphics[width=12cm]{V-62}
 \caption{New monitoring probe}
 \label{fig3_e3}
 \end{center}
@@ -87,81 +87,54 @@ Points & X(m) & Y(m) & Z(m)\\
 After completing the interface, before running the calculation,
 some Fortran user routines need to be modified.
 
-Go to the folder FORT/USERS/base and copy {\itshape usclim.F} and
-{\itshape usphyv.F} in the FORT directory.
+Go to the folder SRC/REFERENCE/base and copy {\itshape usclim.f90} in the SRC directory.
 
-$\bullet\ $\textbf{usclim.F}\\
-In this case, {\itshape usclim.F} is used to specify the time dependent boundary
+\textbf{usclim.f90}\\
+In this case, {\itshape usclim.f90} is used to specify the time dependent boundary
 condition for
 the temperature. Refer to the comments in the routine or to the \CS user manual
 for more information on this routine.\\
 In our case, you need to identify the boundary faces of color 1. The command\\
-CALL GETFBR('1',NLELT,LSTELT)
-will return an integer NLELT, corresponding to the number of boundary faces of
-color 1, and an integer array LSTELT containing the list of the NLELT boundary
+\texttt{call getfbr('1',nlelt,lstelt)}
+will return an integer \texttt{nlelt}, corresponding to the number of boundary faces of
+color 1, and an integer array \texttt{lstelt} containing the list of the \texttt{nlelt} boundary
 faces of color 1. Note that the string '1' can be more complex and combine
 different colors, group references or geometrical criteria, with the same syntax
 as in the Graphical Interface.
 
-For each boundary face IFAC in the list, the Dirichlet value is given in the
-multi-dimension array RCODCL as follows:
+For each boundary face \texttt{ifac} in the list, the Dirichlet value is given in the
+multi-dimension array \texttt{rcodcl} as follows:
 \begin{verbatim}
-IF (TTCABS.LT.3.8D0) THEN
-  DO IELT = 1, NLELT
-    IFAC = LSTELT(IELT)
-    RCODCL(IFAC,ISCA(1),1) = 20.D0+100.D0*TTCABS
-  ENDDO
-ELSE
-  DO IELT = 1, NLELT
-    IFAC = LSTELT(IELT)
-    RCODCL(IFAC,ISCA(1),1) = 400.D0
-  ENDDO
-ENDIF
+if (ttcabs.lt.3.8d0) then
+  do ielt = 1, nlelt
+    ifac = lstelt(ielt)
+    rcodcl(ifac,isca(1),1) = 20.d0 + 100.d0*ttcabs
+  enddo
+else
+  do ielt = 1, nlelt
+    ifac = lstelt(ielt)
+    rcodcl(ifac,isca(1),1) = 400.d0
+  enddo
+endif
 \end{verbatim}
-ISCA(1) refers to the first scalar and TTCABS is the current physical time.
+\texttt{isca(1)} refers to the first scalar and \texttt{ttcabs} is the current physical time.
 
-See the example file in the directory TEST\_CASES for the complete
-{\itshape usclim.F} file.
+See the example file in the directory \texttt{examples} for the complete
+{\itshape usclim.f90} file.
 
 Note that, although the inlet boundary conditions for temperature are specified
-in the {\itshape usclim.F} file, it is necessary to specify them also in the
+in the {\itshape usclim.f90} file, it is necessary to specify them also in the
 Graphical Interface. The value given in the Interface can be anything, it will
 be overwritten by the Fortran routine.
 
-
-$\bullet\ $\textbf{usphyv.F}\\
-In this case, {\itshape usphyv.F} is used to specify the law that governs the
-variation of density as a function of the temperature. The physical
-characteristics at the center of the cells are stored in the array PROPCE
-(respectively PROPFA for the internal faces and PROPFB for the boundary faces).
-The index of the physical characteristic ``density'' among the other
-characteristics is IROM(IPHAS) for the phase IPHAS.
-Not all the physical characteristics are stored at the center of the cells and
-some characteristics are stored both at the centers of the cells and on the
-boundary faces, for instance.
-Therefore, another array is used, to specify, for a given physical
-characteristics stored at the centers of the cells, its index among the other
-physical characteristics stored at the centers of the cells. It is the array
-IPPROC (IPPROF for the internal faces and IPPROB for the boundary faces).\\
-Hence, the fluid density at the center of cell IEL, for phase IPHAS(=1) is:\\
-PROPCE(IEL,IPPROC(IROM(IPHAS)))
-
-It is this array that has to be modified. The variable density in the cell IEL
-is calculated from the fluid temperature in this cell, stored in\\
-RTP(IEL,ISCA(1))
-
-See the example file in the directory TEST\_CASES for the complete
-{\itshape usphyv.F} file.
-
-
-After updating these two Fortran files, run the calculation as explained in case
+After updating the Fortran file, run the calculation as explained in case
 2.
 
 
 \newpage
 When a calculation is finished, \CS stores all the necessary elements to
 continue the computation in another execution, with total continuity. These
-elements are stored in several files, grouped in a SUITE.xxxxxxxx directory, in
+elements are stored in several files, grouped in a RESTART.xxxxxxxx directory, in
 the RESU directory.
 
 In this case, after the first calculation is finished, a second calculation will
@@ -169,13 +142,13 @@ be run, starting from the results of the first one.
 
 
 Go directly on the item {\itshape Start/Restart} under the heading
-{\itshape Calcul management}.  Activate the {\itshape Analysis restart}
+{\itshape Calculation management}.  Activate the {\itshape Calculation restart}
 by ticking the ``on'' box. Then click on the folder icon next to it to specify
 the restart files to use.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c3_capture04}
+\includegraphics[width=12cm]{V-63}
 \caption{Start / Restart}
 \label{fig4_e3}
 \end{center}
@@ -184,12 +157,12 @@ the restart files to use.
 
 \newpage
 A window opens, with the architecture of the study sub-directories. Open the
-RESU folder and click on the folder SUITE.xxxxxxxx (where xxxxxxxx corresponds
+RESU folder and click on the folder RESTART.xxxxxxxx (where xxxxxxxx corresponds
 to the reference of the first calculation). Then click on {\itshape Validate}.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c3_capture05}
+\includegraphics[width=10cm]{V-64}
 \caption{Start / Restart - Selection of the restart directory}
 \label{fig5_e3}
 \end{center}
@@ -197,8 +170,7 @@ to the reference of the first calculation). Then click on {\itshape Validate}.
 
 
 \newpage
-Go to the {\itshape Time step} item under the heading {\itshape Analysis
-control} and change the number of iterations. It must be the total number of
+Go to the {\itshape Time step} item under the heading {\itshape Numerical parameters} and change the number of iterations. It must be the total number of
 iterations, from the beginning of the first calculation.\\
 
 The first calculation was done with 300 iterations and another 400 iterations
@@ -206,7 +178,7 @@ are needed for the present case. Therefore the value 700 must be entered.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c3_capture06}
+\includegraphics[width=12cm]{V-65}
 \caption{Time step}
 \label{fig6_e3}
 \end{center}
diff --git a/doc/tutorial/tuto_case4.tex b/doc/tutorial/tuto_case4.tex
index 84b7bf7..ee42036 100644
--- a/doc/tutorial/tuto_case4.tex
+++ b/doc/tutorial/tuto_case4.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -31,13 +31,36 @@ This case is similar to case 3, with the following differences:\\
 \hspace*{1cm}$\bullet\ $calculation of a spatial average\\
 \hspace*{1cm}$\bullet\ $dealing with a user results file
 
-The head loss is controlled by the {\itshape uskpdc.F} routine. Some elements
-are given in paragraph \ref{prg_case4}. Refer to the example file in the
-directory TEST\_CASES for the complete {\itshape uskpdc.F} file.
+The head loss is defined in the Graphical User Interface. Go to {\itshape Volume regions definition} under the heading {\itshape Volume conditions}. Click on ``Add'', unselect ``Initialization'' and select ``Head losses'' in the box named {\itshape Nature}. In the box named {\itshape Label}, name the head loss region. Define the limits of the head losses region in {\itshape Selection criteria}. The associated character string to enter is as follows:
+``$0.2 <= X$ and $0.4 >= X$ and $-0.75 <= Y$ and $-0.25 >= Y$''
 
-The calculation of the spatial average is done in the {\itshape usproj.F}
+\begin{figure}[h!]
+\begin{center}
+\begin{tabular}{c}
+\includegraphics[width=9cm]{head_loss0} \\
+\\
+\includegraphics[width=9cm]{head_loss3}
+\end{tabular}
+\caption{Creation of head losses region}
+\label{fig_hl1}
+\end{center}
+\end{figure}
+
+\newpage
+To specify the head losses coefficients go to the item {\itshape Head losses} and select the name of the head losses volume region. In this example, the coefficient is isotropic so that we use the same value for each $\alpha_{ii}$. Please note that $\alpha_{ii}=2 \times K_{ii}$, therefore if $K_{ii}=10^4$, $\alpha_{ii}=2 \ 10^4$.
+
+\begin{figure}[h!]
+\begin{center}
+\includegraphics[width=12cm]{head_loss5}
+\caption{Head losses coefficients}
+\label{fig_hl2}
+\end{center}
+\end{figure}
+
+\newpage
+The calculation of the spatial average is done in the {\itshape usproj.f90}
 routine. Refer to the example file in the
-directory TEST\_CASES for the complete {\itshape usproj.F} file.
+directory \texttt{examples} for the complete {\itshape usproj.f90} file.
 
 The other two changes are controlled in the item
 {\itshape Prepare batch analysis}.
@@ -47,7 +70,7 @@ indicator to 2. The launch script will automatically deal with the rest.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c4_capture01}
+\includegraphics[width=12cm]{V-66}
 \caption{Number of processors}
 \label{fig1_e4}
 \end{center}
@@ -56,20 +79,18 @@ indicator to 2. The launch script will automatically deal with the rest.
 
 \newpage
 As seen in paragraph \ref{prg_case4}, the file ``moy.dat'' created by
-{\itshape usproj.F} will be written in the temporary execution directory. It
+{\itshape usproj.f90} will be written in the temporary execution directory. It
 must be identified in the launch script in order to be automatically copied in
 the RESU directory (More precisely, a RES\_USERS.xxxxxxxx directory will be
 created in the RESU folder, in which the file will be copied).
 
-Click on the icon {\itshape User files} to open the associated dialog window.
-Enter the file name ``moy.dat'' in the field {\itshape New results files}
-and press the return''Enter'' key on the keyboard. The file name moves to the
-list in the above window, so further file names can be added. When finished,
-click on {\itshape Validate}.
+Click on the icon {\itshape New user result file} to enter the associated dialog window.
+Enter the file name ``moy.dat'' in the field. Further file names can be added. When finished,
+click on {\itshape OK}.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c4_capture02}
+\includegraphics[width=5cm]{V-67}
 \caption{User results files}
 \label{fig2_e4}
 \end{center}
diff --git a/doc/tutorial/tuto_case5.tex b/doc/tutorial/tuto_case5.tex
index a43c2ed..9cbe940 100644
--- a/doc/tutorial/tuto_case5.tex
+++ b/doc/tutorial/tuto_case5.tex
@@ -3,7 +3,7 @@
 %     This file is part of the Code_Saturne Kernel, element of the
 %     Code_Saturne CFD tool.
 %
-%     Copyright (C) 1998-2008 EDF S.A., France
+%     Copyright (C) 1998-2010 EDF S.A., France
 %
 %     contact: saturne-support at edf.fr
 %
@@ -34,13 +34,13 @@ The preparation of the calculation for case 5 is very similar to the other cases
         \item Use a thermal scalar in Celsius degrees
 \end{itemize}
 
-In the item {\itshape Initialization}, set the initial value of the temperature
+In the item {\itshape Initialization} under the heading {\itshape Volume conditions}, set the initial value of the temperature
 in the domain to 38.5\degresC. Initialize the turbulence with the reference
 velocity $0.03183\ m.s^{-1}$.
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c5_capture01}
+\includegraphics[width=12cm]{V-68}
 \caption{Thermophysical models - Initialization}
 \label{fig1_e5}
 \end{center}
@@ -55,9 +55,9 @@ properties}, enter the following information:
 \begin{tabular}{c|c|c}
 Variable & Type & Value \\
 \hline
-Density & Variable & $998.671\ kg.m^{-3} $ \\
+Density & user law & $998.671\ kg.m^{-3} $ \\
 \hline
-Viscosity & Variable & $0.445\times 10^{-4}\ kg.m^{-1}.s^{-1} $ \\
+Viscosity & user law & $0.445\times 10^{-4}\ kg.m^{-1}.s^{-1} $ \\
 \hline
 Specific Heat & Constant & $4\,182.88\ J.kg^{-1}.\mbox{\degresC}^{-1} $ \\
 \hline
@@ -70,12 +70,31 @@ value (see user manual for details).
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c5_capture02}
+\includegraphics[width=12cm]{V-69}
 \caption{Physical properties: fluid properties}
 \label{fig2_e5}
 \end{center}
 \end{figure}
 
+\newpage
+For the density and viscosity, enter the expressions of the user laws as showed in
+figures \ref{fig5_var1} and \ref{fig5_var2}, in the windows poping while clicking on the highlighted boxes.
+
+\begin{figure}[h!]
+\begin{center}
+\includegraphics[width=12cm]{density_law}
+\caption{Variable density}
+\label{fig5_var1}
+\end{center}
+\end{figure}
+
+\begin{figure}[h!]
+\begin{center}
+\includegraphics[width=12cm]{viscosity_law}
+\caption{Variable viscosity}
+\label{fig5_var2}
+\end{center}
+\end{figure}
 
 \newpage
 The aim of the calculation is to simulate a stratified flow. It is therefore
@@ -86,7 +105,7 @@ stratification, the pressure interpolation method will be set to
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c5_capture03}
+\includegraphics[width=12cm]{V-70}
 \caption{Fluid properties - Gravity}
 \label{fig3_e5}
 \end{center}
@@ -102,7 +121,7 @@ temperature: 18.26\degresC\ and 38.5\degresC. Note that the initial value of
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c5_capture04}
+\includegraphics[width=12cm]{V-71}
 \caption{Scalar initialization}
 \label{fig4_e5}
 \end{center}
@@ -130,7 +149,7 @@ Colors & Conditions \\
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c5_capture05}
+\includegraphics[width=12cm]{V-72}
 \caption{Boundary regions}
 \label{fig5_e5}
 \end{center}
@@ -144,16 +163,19 @@ $z$ direction and the hydraulic diameter $0.4\ m$ for both inlets.
 
 \begin{figure}[h!]
 \begin{center}
-\begin{tabular}{c}
-\includegraphics[width=8.5cm]{c5_capture07} \\
-\\
-\includegraphics[width=8.5cm]{c5_capture08}
-\end{tabular}
+\includegraphics[width=12cm]{V-73}
 \caption{Dynamic boundary conditions}
 \label{fig6_e5}
 \end{center}
 \end{figure}
 
+\begin{figure}[h!]
+\begin{center}
+\includegraphics[width=12cm]{V-73bis}
+\caption{Dynamic boundary conditions}
+\label{fig6_e5}
+\end{center}
+\end{figure}
 
 \newpage
 For the scalar boundary conditions, the temperature of the cold inlet is
@@ -161,16 +183,19 @@ For the scalar boundary conditions, the temperature of the cold inlet is
 
 \begin{figure}[h!]
 \begin{center}
-\begin{tabular}{c}
-\includegraphics[width=8.5cm]{c5_capture09} \\
-\\
-\includegraphics[width=8.5cm]{c5_capture10}
-\end{tabular}
+\includegraphics[width=8cm]{V-74}
 \caption{Temperature boundary conditions}
 \label{fig8_e5}
 \end{center}
 \end{figure}
 
+\begin{figure}[h!]
+\begin{center}
+\includegraphics[width=8cm]{V-74bis}
+\caption{Temperature boundary conditions}
+\label{fig8_e5}
+\end{center}
+\end{figure}
 
 \newpage
 Tick the appropriate box for the time step to be variable in time and uniform in
@@ -202,7 +227,7 @@ And activate the option
 
 \begin{figure}[h!]
 \begin{center}
-\includegraphics[width=12cm]{c5_capture11}
+\includegraphics[width=13cm]{V-75}
 \caption{Time step}
 \label{fig11_e5}
 \end{center}
@@ -231,33 +256,31 @@ Points & X(m) & Y(m) & Z(m)\\
 
 \begin{figure}[h!]
 \begin{center}
-\begin{tabular}{c}
-\includegraphics[width=7cm]{c5_capture12} \\
-\\
-\includegraphics[width=7cm]{c5_capture13}
-\end{tabular}
-\caption{Outpput management and monitoring points}
+\includegraphics[width=12cm]{V-76}
+\caption{Output management}
 \label{fig12_e5}
 \end{center}
 \end{figure}
 
+\begin{figure}[h!]
+\begin{center}
+\includegraphics[width=12cm]{V-76bis}
+\caption{Monitoring points}
+\label{fig12bis_e5}
+\end{center}
+\end{figure}
 
 \newpage
-Before running the calculation, fill the {\itshape usphyv.F} file to specify the
-variation of the density and the viscosity with the temperature. Refer to the
-other cases or the example in the TEST\_CASES directory for more
-information.
-
 For the advanced post-processing features, copy the three routines
-{\itshape usdpst.F}, {\itshape usmpst.F} and {\itshape usvpst.F} in the FORT
+{\itshape usdpst.f90}, {\itshape usmpst.f90} and {\itshape usvpst.f90} in the SRC
 directory. The general content of these routines is described in the user manual
-or in the examples available in the directory FORT/USERS/base. The modified
-routines adapted to this test case are available in the TEST\_CASES
+or in the examples available in the directory SRC/REFERENCE/base. The modified
+routines adapted to this test case are available in the \texttt{examples}
 directory. Only the main elements are mentionned here.
 
 
 
-$\bullet$ {\bfseries usdpst.F}\\
+$\bullet$ {\bfseries usdpst.f90}\\
 This routine is called only once, at the beginning of the calculation. It allows
 to define the different writers and parts.
 
@@ -286,8 +309,8 @@ combinations of cells and faces are not}.\\
 The first part, the clip plane, will be created by detecting the internal faces
 which have a center of gravity (CDGFAC) between -0.01 and 0.01.\\
 The second part, the cells where the temperature is lower than 21\degresC, will
-be specified in {\itshape usmpst.F}. Yet it must be initialized in
-{\itshape usdpst.F}. The easiest is to set \mbox{NLCEL=NCEL}, total number of
+be specified in {\itshape usmpst.f90}. Yet it must be initialized in
+{\itshape usdpst.f90}. The easiest is to set \mbox{NLCEL=NCEL}, total number of
 cells (and when doing so, there is no need to specify the LSTCEL array).
 
 Eventually, the different parts must be associated with the different writers,
@@ -295,7 +318,7 @@ through the PSTASS routine. Part 1 is associated to the writer -1, and part 2 to
 the writer 1.
 
 
-$\bullet$ {\bfseries usmpst.F}\\
+$\bullet$ {\bfseries usmpst.f90}\\
 This routine is called at each time step. It allows to redefine the content of
 certain parts using any variable, especially the temperature for this case.
 
@@ -304,7 +327,7 @@ where the temperature is lower than 21\degresC\ and hence calculate the number
 of cells NCELPS in the part and the list of cells LSTCEL.
 
 
-$\bullet$ {\bfseries usvpst.F}\\
+$\bullet$ {\bfseries usvpst.f90}\\
 This routine is called at each time step. It allows to specify which variable
 will be written on which part.
 
@@ -314,13 +337,13 @@ PSTEVA are:
 
 \begin{tabular}{@{$\bullet\ $}l@{$\quad$}p{10cm}}
 IPART & part number\\
-NAMVER & character string of the name under which the variable will be written\\
+NAMEVR & character string of the name under which the variable will be written\\
 IDIMT & dimension of the variable (1 or 3 for scalars or vectors)\\
 IENTLA & for vectors, indicates if the components are interlaced (=1) or not
 (=0)\\
 IVARPR & shortcut option for specific situations, set to 0 here\\
-NTCABS & current time step (passed to {\itshape usvpst.F} with the right value)\\
-TTCABS & current physical time (passed to {\itshape usvpst.F} with the right
+NTCABS & current time step (passed to {\itshape usvpst.f90} with the right value)\\
+TTCABS & current physical time (passed to {\itshape usvpst.f90} with the right
 value)\\
 TRACEL & array for variables on cells\\
 TRAFAC & array for variables on internal faces\\
diff --git a/doc/user/Makefile.am b/doc/user/Makefile.am
index ea1f1fe..853cc2d 100644
--- a/doc/user/Makefile.am
+++ b/doc/user/Makefile.am
@@ -28,7 +28,6 @@ TEXMAIN = user.tex
 
 TEXOTHERS = \
 a1_autovalid.tex \
-ale.tex \
 biblio.tex \
 saturne1.tex \
 saturne2.tex \
diff --git a/doc/user/Makefile.in b/doc/user/Makefile.in
index f95a992..ef09448 100644
--- a/doc/user/Makefile.in
+++ b/doc/user/Makefile.in
@@ -72,15 +72,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -126,6 +137,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -149,6 +161,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -200,6 +213,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -256,6 +270,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -293,7 +308,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -327,7 +341,6 @@ TEXMAIN = user.tex
 # Other LaTex document
 TEXOTHERS = \
 a1_autovalid.tex \
-ale.tex \
 biblio.tex \
 saturne1.tex \
 saturne2.tex \
diff --git a/doc/user/a1_autovalid.tex b/doc/user/a1_autovalid.tex
index a7171de..20b0f22 100644
--- a/doc/user/a1_autovalid.tex
+++ b/doc/user/a1_autovalid.tex
@@ -58,10 +58,10 @@ the variable differences.
 
 For each test cases, the detailed actions are the following:
 \begin{list}{$\bullet$}{}
-\item preparation of the study with the {\it cs\_create} utility,
+\item preparation of the study with the {\tt code\_saturne~create} command,
 \item copy of all the necessary files (meshes, XML data file, user
       fortran files) from the reference base,
-\item execution of the case with the {\it runcase} utility,
+\item execution of the case with the {\tt runcase} utility,
 \item comparison between the reference results and the test results,
 \item update of the report file.
 \end{list}
@@ -69,7 +69,7 @@ For each test cases, the detailed actions are the following:
 First, an empty directory named BASETEST is generated by the user.
 In this directory, the command to launch the script is the following:
 \begin{center}
-{\it autovalid -f [xml file name] [-d [tmp directory]] }
+{\tt autovalid -f [xml file name] [-d [tmp directory]] }
 \end{center}
 where {\it xml file name} is the data file containing the settings
 necessary to the autovalidation. The reference base has to be easily
@@ -88,9 +88,9 @@ The typical architecture is given in the following section:
 \begin{list}{$\bullet$}{}
 \item a directory BASEREF containing all the reference studies
       (five elementary tests GRADIENT and LAPLACIEN) and the XML data
-      file {\it autovalid.xml},
+      file {\tt autovalid.xml},
 \item the user has to create a directory BASETEST and to copy
-      the XML data file {\it autovalid.xml} in this directory before
+      the XML data file {\tt autovalid.xml} in this directory before
       launching the script,
 \item a directory Autovalid containing all the python source files.
 \end{list}
@@ -115,25 +115,16 @@ The elementary tests are performed on a cubical mesh composed by
 hexahedrons and tetrahedrons with non-conforming merging. The mesh is
 generated using Simail-6.4 mesher (file with extension {\it .des}).
 
-All the tests are contained in the fortran file {\it testel.F} called by
-the fortran file {\it caltri.F}. To activate the elementary tests,
-we use the existing parameter IVERIF in the main program {\it
-cs\_main.c}. IVERIF is initialised to -1 (no action). If IVERIF takes
-the value 0, there is no difference with the standard version. If
-IVERIF $>$ 0, {\it testel.F} will be called with :
-\begin{list}{$\bullet$}{}
-\item IVERIF = 1: IMRGRA = 0
-\item IVERIF = 2: IMRGRA = 1
-\item IVERIF = 3: IMRGRA = 2
-\item IVERIF = 4: IMRGRA = 3
-\item IVERIF = 5: IMRGRA = 4
-\end{list}
+All the tests are contained in the fortran file {\tt testel.f90} called by
+the fortran file {\tt caltri.f90}. To activate the elementary tests,
+we use the existing parameter {\tt iverif} in the main program {\tt cs\_solver.c};
+{\tt iverif} is initialised to -1 (no action).
 
-A new keyword ARG\_CS\_VERIF refering to IVERIF is added in the
-universal launch script {\it lance}, so that the command line is:
-{\it cs14.exe -v ARG\_CS\_VERIF}.
+A new keyword ARG\_CS\_VERIF refering to {\tt iverif} is added in the
+universal launch script {\tt runcase}, so that the command line is:
+{\tt cs\_solver \$ARG\_CS\_VERIF}.
 
-The test case consists in calculating the gradient of sin(x+2y+3z)
+The test case consists in calculating the gradient of $sin(x+2y+3z)$
 with the different methods implemented in \CS (boundary conditions
 are treated with Dirichlet condition). We compare the result to the
 reference solution (not to the exact solution).
@@ -147,8 +138,8 @@ The mesh is the same as for the previous elementary tests.
 
 The case consists in the resolution of a stationary equation without
 convection terms for a passive scalar. The source term and Dirichlet
-boundary conditions are specified so that the solution is sin(x+2y+3z).
-The source term is imposed in the fortran file {\it ustssc.F}.
+boundary conditions are specified so that the solution is $sin(x+2y+3z)$.
+The source term is imposed in the fortran file {\tt ustssc.f90}.
 We compare the result with the reference solution (not with the exact
 solution).
 
@@ -160,7 +151,7 @@ solution).
 
 In the directory Autovalid, the user finds all the python source
 files necessary to the execution of the procedure. The main file
-{\it autovalid} runs the autovalidation and manages the general
+{\tt autovalid} runs the autovalidation and manages the general
 printouts.
 
 
@@ -171,19 +162,19 @@ printouts.
 All the python files are listed here:
 
 \begin{list}{$\bullet$}{}
-\item {\it Common.py}: this file contains the global variables (XML
+\item {\tt Common.py}: this file contains the global variables (XML
       file name, reference version, reference path, temporary directory
       and local directory),
-\item {\it CommandLine.py}: this file manages the command line usage,
-\item {\it Parser.py}: this file defines the parser class which loads
+\item {\tt CommandLine.py}: this file manages the command line usage,
+\item {\tt Parser.py}: this file defines the parser class which loads
       and reads the XML data file,
-\item {\it Study.py}: this file defines the study class which contains
+\item {\tt Study.py}: this file defines the study class which contains
       case objects,
-\item {\it Case.py}: this file defines the case class which contains
+\item {\tt Case.py}: this file defines the case class which contains
       the launch script and the listing and chrono comparisons,
-\item {\it Listing.py}: this file defines the listing class which
+\item {\tt Listing.py}: this file defines the listing class which
       contains minima/maxima variables and clippings,
-\item {\it Chrono.py}: this file defines the chrono class which
+\item {\tt Chrono.py}: this file defines the chrono class which
       contains a list of values and creates, if necessary, a part
       EnSight (if tolerance $>$ specified value).
 \end{list}
@@ -237,16 +228,16 @@ For example, this previous sequence means that the user wants to run
 
 There are three kinds of report file :
 \begin{list}{$\bullet$}{}
-\item {\it report.txt}: this general file contains just OK, NOK,
+\item {\tt report.txt}: this general file contains just OK, NOK,
       'Execution error' or 'Compilation error' for each case of
       each study,
-\item {\it STUDY\_listing.report}: this file depends on the study
+\item {\tt STUDY\_listing.report}: this file depends on the study
       and contains the listing files comparison for each selected
       variable at the last time step (min/max values, min/max norms,
       min/max clippings),
       $$Norm_{X_{max}}=\frac{\vert{X_{max_{Ref}}-X_{max_{Test}}}\vert}{\vert{X_{max_{Ref}}-X_{min_{Ref}}}+\varepsilon\vert}$$
       $$Norm_{X_{min}}=\frac{\vert{X_{min_{Ref}}-X_{min_{Test}}}\vert}{\vert{X_{max_{Ref}}-X_{min_{Ref}}}+\varepsilon\vert}$$
-\item {\it STUDY\_chrono.report}: this file depends on the study
+\item {\tt STUDY\_chrono.report}: this file depends on the study
       and contains the chrono files comparison for each selected
       variable at the last time step (maximum difference, mean
       difference and norm),
diff --git a/doc/user/graphics/Makefile.in b/doc/user/graphics/Makefile.in
index 9cfc8af..c349d29 100644
--- a/doc/user/graphics/Makefile.in
+++ b/doc/user/graphics/Makefile.in
@@ -72,20 +72,32 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -109,6 +121,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -160,6 +173,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -216,6 +230,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -253,7 +268,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/doc/user/graphics/cs_components.fig b/doc/user/graphics/cs_components.fig
index 63ae22d..d853cad 100644
--- a/doc/user/graphics/cs_components.fig
+++ b/doc/user/graphics/cs_components.fig
@@ -7,471 +7,471 @@ A4
 Single
 -2
 1200 2
-0 32 #bfb38c
-0 33 #e5f1f5
-0 34 #d5c19c
-0 35 #e5f1f5
-0 36 #868286
-0 37 #d5c19c
-0 38 #d5d9d5
-0 39 #868286
-0 40 #d5d9d5
+0 32 #beb28b
+0 33 #e4f0f4
+0 34 #d4c09b
+0 35 #e4f0f4
+0 36 #858185
+0 37 #d4c09b
+0 38 #d4d8d4
+0 39 #858185
+0 40 #d4d8d4
 0 41 #595559
 0 42 #414141
-0 43 #868286
-0 44 #bbbfbb
-0 45 #868286
-0 46 #bbbfbb
-0 47 #d5d9d5
-0 48 #868686
-0 49 #868686
+0 43 #858185
+0 44 #babeba
+0 45 #858185
+0 46 #babeba
+0 47 #d4d8d4
+0 48 #858585
+0 49 #858585
 0 50 #414141
-0 51 #868286
-0 52 #bbbfbb
-0 53 #d5d9d5
+0 51 #858185
+0 52 #babeba
+0 53 #d4d8d4
 0 54 #414141
-0 55 #868286
-0 56 #bbbfbb
-0 57 #d5d9d5
-0 58 #868286
-0 59 #bbbfbb
-0 60 #d5d9d5
-0 61 #bfb38c
-0 62 #e5f1f5
-0 63 #d5c19c
-0 64 #bfb38c
-0 65 #e5f1f5
-0 66 #d5c19c
-0 67 #a4a0a4
+0 55 #858185
+0 56 #babeba
+0 57 #d4d8d4
+0 58 #858185
+0 59 #babeba
+0 60 #d4d8d4
+0 61 #beb28b
+0 62 #e4f0f4
+0 63 #d4c09b
+0 64 #beb28b
+0 65 #e4f0f4
+0 66 #d4c09b
+0 67 #a39fa3
 0 68 #595559
-0 69 #868686
+0 69 #858585
 0 70 #414141
-0 71 #868286
-0 72 #bbbfbb
-0 73 #d5d9d5
+0 71 #858185
+0 72 #babeba
+0 73 #d4d8d4
 0 74 #414141
-0 75 #868286
-0 76 #bbbfbb
-0 77 #d5d9d5
-0 78 #868286
-0 79 #bbbfbb
-0 80 #d5d9d5
+0 75 #858185
+0 76 #babeba
+0 77 #d4d8d4
+0 78 #858185
+0 79 #babeba
+0 80 #d4d8d4
 0 81 #414141
-0 82 #868286
-0 83 #bbbfbb
+0 82 #858185
+0 83 #babeba
 0 84 #414141
-0 85 #bbbfbb
-0 86 #d5d9d5
+0 85 #babeba
+0 86 #d4d8d4
 0 87 #414141
-0 88 #868286
-0 89 #bbbfbb
-0 90 #868686
+0 88 #858185
+0 89 #babeba
+0 90 #858585
 0 91 #414141
-0 92 #868286
-0 93 #bbbfbb
-0 94 #d5d9d5
+0 92 #858185
+0 93 #babeba
+0 94 #d4d8d4
 0 95 #414141
-0 96 #868286
-0 97 #bbbfbb
-0 98 #d5d9d5
-0 99 #bbbbbb
+0 96 #858185
+0 97 #babeba
+0 98 #d4d8d4
+0 99 #bababa
 0 100 #515151
-0 101 #ddd9dd
+0 101 #dcd8dc
 0 102 #000049
 0 103 #797979
 0 104 #303430
 0 105 #414541
 0 106 #414141
-0 107 #868286
-0 108 #bbbfbb
-0 109 #d5d9d5
-0 110 #bfb790
-0 111 #e8f1f8
-0 112 #d5c49f
+0 107 #858185
+0 108 #babeba
+0 109 #d4d8d4
+0 110 #beb68f
+0 111 #e7f0f7
+0 112 #d4c39e
 0 113 #404040
 0 114 #808080
-0 115 #bfbfbf
-0 116 #d9d9d9
-0 117 #878887
-0 118 #a3a3a3
+0 115 #bebebe
+0 116 #d8d8d8
+0 117 #868786
+0 118 #a2a2a2
 0 119 #555555
-0 120 #bfbfbf
-0 121 #bfbfbf
-0 122 #d9d9d9
-0 123 #878887
-0 124 #878887
-0 125 #bfbfbf
-0 126 #d9d9d9
-0 127 #bfbfbf
-0 128 #d9d9d9
-0 129 #bfbfbf
-0 130 #d9d9d9
-0 131 #bfb790
-0 132 #e8f1f8
-0 133 #d5c49f
-0 134 #bfb790
-0 135 #e8f1f8
-0 136 #d5c49f
-0 137 #c0bfc0
-0 138 #e0dce0
-0 139 #bfbfbf
-0 140 #d9d9d9
-0 141 #878787
-0 142 #878887
+0 120 #bebebe
+0 121 #bebebe
+0 122 #d8d8d8
+0 123 #868786
+0 124 #868786
+0 125 #bebebe
+0 126 #d8d8d8
+0 127 #bebebe
+0 128 #d8d8d8
+0 129 #bebebe
+0 130 #d8d8d8
+0 131 #beb68f
+0 132 #e7f0f7
+0 133 #d4c39e
+0 134 #beb68f
+0 135 #e7f0f7
+0 136 #d4c39e
+0 137 #bfbebf
+0 138 #dfdbdf
+0 139 #bebebe
+0 140 #d8d8d8
+0 141 #868686
+0 142 #868786
 0 143 #444444
-0 144 #868686
-0 145 #c0c0c0
-0 146 #e0e0e0
-0 147 #f0f0f0
-0 148 #979797
+0 144 #858585
+0 145 #bfbfbf
+0 146 #dfdfdf
+0 147 #efefef
+0 148 #969696
 0 149 #717571
 0 150 #565151
-0 151 #e8f4f8
-0 152 #a3a3a3
+0 151 #e7f3f7
+0 152 #a2a2a2
 0 153 #666666
-0 154 #dbdbe7
-0 155 #8d8d93
-0 156 #d4d4d4
-0 157 #9a9ab7
+0 154 #dadae6
+0 155 #8c8c92
+0 156 #d3d3d3
+0 157 #9999b6
 0 158 #950000
-0 159 #e6e6e6
-0 160 #86a5f8
-0 161 #7070f8
-0 162 #bfb790
-0 163 #e8f1f8
-0 164 #d5c49f
-0 165 #bbbbbb
-0 166 #c0b38f
-0 167 #d0d0d0
-0 168 #a7a7a7
-0 169 #a3a3a3
-0 170 #878787
-0 171 #d0d0d0
-0 172 #878887
-0 173 #bfbfbf
-0 174 #d9d9d9
-0 175 #82807d
-0 176 #cbcbcb
+0 159 #e5e5e5
+0 160 #85a4f7
+0 161 #7070f7
+0 162 #beb68f
+0 163 #e7f0f7
+0 164 #d4c39e
+0 165 #bababa
+0 166 #bfb28e
+0 167 #cfcfcf
+0 168 #a6a6a6
+0 169 #a2a2a2
+0 170 #868686
+0 171 #cfcfcf
+0 172 #868786
+0 173 #bebebe
+0 174 #d8d8d8
+0 175 #81807d
+0 176 #cacaca
 0 177 #3a3a3a
-0 178 #4573a3
+0 178 #4573a2
 0 179 #000000
-0 180 #bfb790
-0 181 #e8f1f8
-0 182 #d5c49f
-0 183 #bfbfbf
-0 184 #d9d9d9
-0 185 #878887
-0 186 #c0bfc0
-0 187 #e0dce0
-0 188 #878787
-0 189 #c0c0c0
-0 190 #e0e0e0
-0 191 #f0f0f0
-0 192 #8d8d93
-0 193 #d4d4d4
-0 194 #9a9ab7
+0 180 #beb68f
+0 181 #e7f0f7
+0 182 #d4c39e
+0 183 #bebebe
+0 184 #d8d8d8
+0 185 #868786
+0 186 #bfbebf
+0 187 #dfdbdf
+0 188 #868686
+0 189 #bfbfbf
+0 190 #dfdfdf
+0 191 #efefef
+0 192 #8c8c92
+0 193 #d3d3d3
+0 194 #9999b6
 0 195 #950000
-0 196 #e6e6e6
-0 197 #86a5f8
-0 198 #7070f8
-0 199 #bbbbbb
-0 200 #c0b38f
-0 201 #d0d0d0
-0 202 #a7a7a7
-0 203 #a3a3a3
-0 204 #a7a7a7
-0 205 #bfbfbf
-0 206 #d9d9d9
-0 207 #bfbfbf
-0 208 #d9d9d9
-0 209 #bfbfbf
-0 210 #a7a7a7
-0 211 #878787
-0 212 #878787
-0 213 #878787
-0 214 #bfbfbf
-0 215 #d9d9d9
-0 216 #bfbfbf
-0 217 #cfd0cf
-0 218 #7b799e
-0 219 #bfb790
-0 220 #e8f1f8
-0 221 #bfbfbf
-0 222 #d9d9d9
-0 223 #878887
-0 224 #a3a3a3
-0 225 #d5c49f
-0 226 #c0bfc0
-0 227 #e0dce0
-0 228 #878787
-0 229 #c0c0c0
-0 230 #e0e0e0
-0 231 #dbdbe7
-0 232 #8d8d93
-0 233 #d4d4d4
-0 234 #9a9ab7
+0 196 #e5e5e5
+0 197 #85a4f7
+0 198 #7070f7
+0 199 #bababa
+0 200 #bfb28e
+0 201 #cfcfcf
+0 202 #a6a6a6
+0 203 #a2a2a2
+0 204 #a6a6a6
+0 205 #bebebe
+0 206 #d8d8d8
+0 207 #bebebe
+0 208 #d8d8d8
+0 209 #bebebe
+0 210 #a6a6a6
+0 211 #868686
+0 212 #868686
+0 213 #868686
+0 214 #bebebe
+0 215 #d8d8d8
+0 216 #bebebe
+0 217 #cecfce
+0 218 #7b799d
+0 219 #beb68f
+0 220 #e7f0f7
+0 221 #bebebe
+0 222 #d8d8d8
+0 223 #868786
+0 224 #a2a2a2
+0 225 #d4c39e
+0 226 #bfbebf
+0 227 #dfdbdf
+0 228 #868686
+0 229 #bfbfbf
+0 230 #dfdfdf
+0 231 #dadae6
+0 232 #8c8c92
+0 233 #d3d3d3
+0 234 #9999b6
 0 235 #950000
-0 236 #e6e6e6
-0 237 #86a5f8
-0 238 #7070f8
-0 239 #bbbbbb
-0 240 #c0b38f
-0 241 #d0d0d0
-0 242 #a7a7a7
-0 243 #82807d
-0 244 #cbcbcb
-0 245 #4573a3
-0 246 #f0f0f0
-0 247 #e8f4f8
-0 248 #979797
-0 249 #737586
-0 250 #635dc7
-0 251 #82807d
-0 252 #cbcbcb
-0 253 #4573a3
-0 254 #bfb790
-0 255 #e8f1f8
-0 256 #d5c49f
-0 257 #bfbfbf
-0 258 #d9d9d9
-0 259 #878887
-0 260 #c0bfc0
-0 261 #e0dce0
-0 262 #878787
-0 263 #c0c0c0
-0 264 #e0e0e0
-0 265 #f0f0f0
-0 266 #8d8d93
-0 267 #d4d4d4
-0 268 #9a9ab7
+0 236 #e5e5e5
+0 237 #85a4f7
+0 238 #7070f7
+0 239 #bababa
+0 240 #bfb28e
+0 241 #cfcfcf
+0 242 #a6a6a6
+0 243 #81807d
+0 244 #cacaca
+0 245 #4573a2
+0 246 #efefef
+0 247 #e7f3f7
+0 248 #969696
+0 249 #737585
+0 250 #635dc6
+0 251 #81807d
+0 252 #cacaca
+0 253 #4573a2
+0 254 #beb68f
+0 255 #e7f0f7
+0 256 #d4c39e
+0 257 #bebebe
+0 258 #d8d8d8
+0 259 #868786
+0 260 #bfbebf
+0 261 #dfdbdf
+0 262 #868686
+0 263 #bfbfbf
+0 264 #dfdfdf
+0 265 #efefef
+0 266 #8c8c92
+0 267 #d3d3d3
+0 268 #9999b6
 0 269 #950000
-0 270 #e6e6e6
-0 271 #86a5f8
-0 272 #7070f8
-0 273 #bbbbbb
-0 274 #c0b38f
-0 275 #d0d0d0
-0 276 #a7a7a7
-0 277 #a3a3a3
-0 278 #979797
-0 279 #e8f4f8
-0 280 #dbdbe7
-0 281 #cfd0cf
-0 282 #737586
-0 283 #bfb790
-0 284 #e8f1f8
-0 285 #d5c49f
-0 286 #bfbfbf
-0 287 #d9d9d9
-0 288 #878887
-0 289 #a3a3a3
-0 290 #c0bfc0
-0 291 #e0dce0
-0 292 #878787
-0 293 #e8f4f8
-0 294 #dbdbe7
-0 295 #8d8d93
-0 296 #d4d4d4
-0 297 #9a9ab7
+0 270 #e5e5e5
+0 271 #85a4f7
+0 272 #7070f7
+0 273 #bababa
+0 274 #bfb28e
+0 275 #cfcfcf
+0 276 #a6a6a6
+0 277 #a2a2a2
+0 278 #969696
+0 279 #e7f3f7
+0 280 #dadae6
+0 281 #cecfce
+0 282 #737585
+0 283 #beb68f
+0 284 #e7f0f7
+0 285 #d4c39e
+0 286 #bebebe
+0 287 #d8d8d8
+0 288 #868786
+0 289 #a2a2a2
+0 290 #bfbebf
+0 291 #dfdbdf
+0 292 #868686
+0 293 #e7f3f7
+0 294 #dadae6
+0 295 #8c8c92
+0 296 #d3d3d3
+0 297 #9999b6
 0 298 #950000
-0 299 #e6e6e6
-0 300 #86a5f8
-0 301 #7070f8
-0 302 #bbbbbb
-0 303 #c0b38f
-0 304 #d0d0d0
-0 305 #a7a7a7
-0 306 #82807d
-0 307 #cbcbcb
-0 308 #4573a3
-0 309 #c0c0c0
-0 310 #e0e0e0
-0 311 #f0f0f0
-0 312 #979797
-0 313 #cfd0cf
-0 314 #737586
-0 315 #bfb790
-0 316 #e8f1f8
-0 317 #d5c49f
-0 318 #bfbfbf
-0 319 #d9d9d9
-0 320 #878887
-0 321 #a3a3a3
-0 322 #c0bfc0
-0 323 #e0dce0
-0 324 #878787
-0 325 #e8f4f8
-0 326 #dbdbe7
-0 327 #8d8d93
-0 328 #d4d4d4
-0 329 #9a9ab7
+0 299 #e5e5e5
+0 300 #85a4f7
+0 301 #7070f7
+0 302 #bababa
+0 303 #bfb28e
+0 304 #cfcfcf
+0 305 #a6a6a6
+0 306 #81807d
+0 307 #cacaca
+0 308 #4573a2
+0 309 #bfbfbf
+0 310 #dfdfdf
+0 311 #efefef
+0 312 #969696
+0 313 #cecfce
+0 314 #737585
+0 315 #beb68f
+0 316 #e7f0f7
+0 317 #d4c39e
+0 318 #bebebe
+0 319 #d8d8d8
+0 320 #868786
+0 321 #a2a2a2
+0 322 #bfbebf
+0 323 #dfdbdf
+0 324 #868686
+0 325 #e7f3f7
+0 326 #dadae6
+0 327 #8c8c92
+0 328 #d3d3d3
+0 329 #9999b6
 0 330 #950000
-0 331 #e6e6e6
-0 332 #86a5f8
-0 333 #7070f8
-0 334 #bbbbbb
-0 335 #c0b38f
-0 336 #d0d0d0
-0 337 #a7a7a7
-0 338 #82807d
-0 339 #cbcbcb
-0 340 #4573a3
-0 341 #c0c0c0
-0 342 #e0e0e0
-0 343 #f0f0f0
-0 344 #979797
-0 345 #cfd0cf
-0 346 #737586
-0 347 #635dc7
-0 348 #878887
-0 349 #bfbfbf
-0 350 #d9d9d9
-0 351 #bfbfbf
-0 352 #d9d9d9
-0 353 #bbbbbb
-0 354 #e0dce0
-0 355 #bbbbbb
-0 356 #bbbbbb
-0 357 #e0dce0
-0 358 #c0b38f
-0 359 #bbbbbb
-0 360 #878787
-0 361 #878787
-0 362 #bbbbbb
-0 363 #bbbbbb
-0 364 #bfbfbf
-0 365 #d9d9d9
-0 366 #c0bfc0
-0 367 #e0dce0
-0 368 #bfbfbf
-0 369 #d9d9d9
-0 370 #878787
-0 371 #878887
-0 372 #878887
-0 373 #878787
-0 374 #878787
-0 375 #c0c0c0
-0 376 #e0e0e0
-0 377 #f0f0f0
-0 378 #979797
-0 379 #e0dce0
-0 380 #c0c0c0
+0 331 #e5e5e5
+0 332 #85a4f7
+0 333 #7070f7
+0 334 #bababa
+0 335 #bfb28e
+0 336 #cfcfcf
+0 337 #a6a6a6
+0 338 #81807d
+0 339 #cacaca
+0 340 #4573a2
+0 341 #bfbfbf
+0 342 #dfdfdf
+0 343 #efefef
+0 344 #969696
+0 345 #cecfce
+0 346 #737585
+0 347 #635dc6
+0 348 #868786
+0 349 #bebebe
+0 350 #d8d8d8
+0 351 #bebebe
+0 352 #d8d8d8
+0 353 #bababa
+0 354 #dfdbdf
+0 355 #bababa
+0 356 #bababa
+0 357 #dfdbdf
+0 358 #bfb28e
+0 359 #bababa
+0 360 #868686
+0 361 #868686
+0 362 #bababa
+0 363 #bababa
+0 364 #bebebe
+0 365 #d8d8d8
+0 366 #bfbebf
+0 367 #dfdbdf
+0 368 #bebebe
+0 369 #d8d8d8
+0 370 #868686
+0 371 #868786
+0 372 #868786
+0 373 #868686
+0 374 #868686
+0 375 #bfbfbf
+0 376 #dfdfdf
+0 377 #efefef
+0 378 #969696
+0 379 #dfdbdf
+0 380 #bfbfbf
 0 381 #757575
-0 382 #979797
-0 383 #c0bfc0
-0 384 #878787
-0 385 #878787
-0 386 #c0bfc0
-0 387 #e0dce0
-0 388 #e8f4f8
-0 389 #e0dce0
-0 390 #878787
-0 391 #c0bfc0
-0 392 #878787
-0 393 #bfbfbf
-0 394 #d9d9d9
-0 395 #ececec
-0 396 #ececec
-0 397 #a3a3a3
-0 398 #878787
-0 399 #878787
-0 400 #a3a3a3
-0 401 #878787
-0 402 #c0bfc0
-0 403 #bfbfbf
-0 404 #d9d9d9
-0 405 #878787
-0 406 #878787
-0 407 #878787
-0 408 #d0ccd0
-0 409 #a7a3a7
-0 410 #bfbfbf
-0 411 #e0e0e0
-0 412 #e0e0e0
-0 413 #ececec
-0 414 #e0e0e0
-0 415 #e0e0e0
-0 416 #bfbfbf
-0 417 #e0e0e0
-0 418 #e0e0e0
-0 419 #ececec
-0 420 #e0e0e0
-0 421 #e0e0e0
+0 382 #969696
+0 383 #bfbebf
+0 384 #868686
+0 385 #868686
+0 386 #bfbebf
+0 387 #dfdbdf
+0 388 #e7f3f7
+0 389 #dfdbdf
+0 390 #868686
+0 391 #bfbebf
+0 392 #868686
+0 393 #bebebe
+0 394 #d8d8d8
+0 395 #ebebeb
+0 396 #ebebeb
+0 397 #a2a2a2
+0 398 #868686
+0 399 #868686
+0 400 #a2a2a2
+0 401 #868686
+0 402 #bfbebf
+0 403 #bebebe
+0 404 #d8d8d8
+0 405 #868686
+0 406 #868686
+0 407 #868686
+0 408 #cfcbcf
+0 409 #a6a2a6
+0 410 #bebebe
+0 411 #dfdfdf
+0 412 #dfdfdf
+0 413 #ebebeb
+0 414 #dfdfdf
+0 415 #dfdfdf
+0 416 #bebebe
+0 417 #dfdfdf
+0 418 #dfdfdf
+0 419 #ebebeb
+0 420 #dfdfdf
+0 421 #dfdfdf
 0 422 #303030
 0 423 #515551
-0 424 #878787
-0 425 #c0c0c0
-0 426 #c0c0c0
-0 427 #878787
-0 428 #f0ecf0
-0 429 #878787
-0 430 #878787
-0 431 #d9d9d9
-0 432 #878887
-0 433 #c0bfc0
-0 434 #e0dce0
-0 435 #c0c0c0
-0 436 #c0c0c0
-0 437 #878787
-0 438 #c0bfc0
-0 439 #e0dce0
-0 440 #c0bfc0
+0 424 #868686
+0 425 #bfbfbf
+0 426 #bfbfbf
+0 427 #868686
+0 428 #efebef
+0 429 #868686
+0 430 #868686
+0 431 #d8d8d8
+0 432 #868786
+0 433 #bfbebf
+0 434 #dfdbdf
+0 435 #bfbfbf
+0 436 #bfbfbf
+0 437 #868686
+0 438 #bfbebf
+0 439 #dfdbdf
+0 440 #bfbebf
 0 441 #717171
-0 442 #e0dce0
-0 443 #c0bfc0
-0 444 #e0dce0
-0 445 #ececec
-0 446 #878787
-0 447 #878787
-0 448 #bfbfbf
-0 449 #d9d9d9
-0 450 #bfbfbf
-0 451 #d9d9d9
-0 452 #878787
-0 453 #c5b796
-0 454 #eef7fe
-0 455 #dbcaa5
-0 456 #8d8e8d
-0 457 #a9a9a9
-0 458 #8d8e8d
-0 459 #8d8e8d
-0 460 #c5b796
-0 461 #eef7fe
-0 462 #dbcaa5
-0 463 #c5b796
-0 464 #eef7fe
-0 465 #dbcaa5
-0 466 #c6c2c6
-0 467 #a9a9a9
-0 468 #8d8d8d
-0 469 #d6d6d6
-0 470 #8d8e8d
-0 471 #84807d
-0 472 #d1d1d1
-0 473 #4573a9
-0 474 #adadad
-0 475 #adadad
-0 476 #8d8d8d
-0 477 #8d8d8d
-0 478 #8d8d8d
-0 479 #7b79a4
-0 480 #73758b
-0 481 #73758b
-0 482 #f6f6f6
-0 483 #635dcd
-0 484 #8d8e8d
-0 485 #bdbdbd
-0 486 #e6e2e6
-0 487 #bdbdbd
-0 488 #bdbdbd
-0 489 #e6e2e6
-0 490 #c6b595
-0 491 #bdbdbd
-0 492 #8d8d8d
-0 493 #8d8d8d
-0 494 #bdbdbd
-0 495 #bdbdbd
-0 496 #8d8d8d
+0 442 #dfdbdf
+0 443 #bfbebf
+0 444 #dfdbdf
+0 445 #ebebeb
+0 446 #868686
+0 447 #868686
+0 448 #bebebe
+0 449 #d8d8d8
+0 450 #bebebe
+0 451 #d8d8d8
+0 452 #868686
+0 453 #c4b695
+0 454 #edf6fd
+0 455 #dac9a4
+0 456 #8c8d8c
+0 457 #a8a8a8
+0 458 #8c8d8c
+0 459 #8c8d8c
+0 460 #c4b695
+0 461 #edf6fd
+0 462 #dac9a4
+0 463 #c4b695
+0 464 #edf6fd
+0 465 #dac9a4
+0 466 #c5c1c5
+0 467 #a8a8a8
+0 468 #8c8c8c
+0 469 #d5d5d5
+0 470 #8c8d8c
+0 471 #83807d
+0 472 #d0d0d0
+0 473 #4573a8
+0 474 #acacac
+0 475 #acacac
+0 476 #8c8c8c
+0 477 #8c8c8c
+0 478 #8c8c8c
+0 479 #7b79a3
+0 480 #73758a
+0 481 #73758a
+0 482 #f5f5f5
+0 483 #635dcc
+0 484 #8c8d8c
+0 485 #bcbcbc
+0 486 #e5e1e5
+0 487 #bcbcbc
+0 488 #bcbcbc
+0 489 #e5e1e5
+0 490 #c5b495
+0 491 #bcbcbc
+0 492 #8c8c8c
+0 493 #8c8c8c
+0 494 #bcbcbc
+0 495 #bcbcbc
+0 496 #8c8c8c
 6 5985 0 8640 990
 2 2 0 0 0 44 54 0 20 0.000 0 0 -1 0 0 5
 	 6210 0 7785 0 7785 315 6210 315 6210 0
@@ -482,25 +482,6 @@ Single
 4 0 0 50 0 16 14 0.0000 4 165 1095 6255 225 Partitioner\001
 4 0 6 50 0 2 12 0.0000 4 180 1515 6210 675 Mesh partitioning\001
 -6
-6 2430 0 5085 2250
-6 2610 495 4950 900
-2 4 0 0 0 9 50 0 20 0.000 0 0 7 0 0 5
-	 4950 900 2625 900 2625 500 4950 500 4950 900
-4 0 6 50 0 2 12 0.0000 4 180 2100 2700 765 Read and append meshes\001
--6
-6 2610 1080 4950 2070
-2 4 0 0 0 21 50 0 20 0.000 0 0 7 0 0 5
-	 4950 2070 2625 2070 2625 1085 4950 1085 4950 2070
-4 0 7 50 0 0 12 0.0000 4 180 2040 2715 1310 Descending connectivity\001
-4 0 6 50 0 2 12 0.0000 4 180 1575 2715 1670 Conformal joining\001
-4 0 6 50 0 2 12 0.0000 4 180 1770 2805 1940 and periodicity setup\001
--6
-2 2 0 0 0 44 54 0 20 0.000 0 0 -1 0 0 5
-	 2670 5 4245 5 4245 320 2670 320 2670 5
-2 4 0 1 0 34 52 0 20 0.000 0 0 7 0 0 5
-	 5085 2250 2445 2250 2445 320 5085 320 5085 2250
-4 0 0 50 0 16 14 0.0000 4 210 1425 2715 230 Preprocessor\001
--6
 6 720 315 1665 1620
 5 1 0 1 -1 -1 0 0 -1 0.000 0 1 0 0 1185.000 -92.500 735 590 1185 725 1635 590
 5 1 0 1 -1 -1 0 0 -1 0.000 0 1 0 0 1185.000 762.500 735 1445 1185 1580 1635 1445
@@ -546,30 +527,6 @@ Single
 4 1 -1 0 0 0 10 0.0000 6 105 450 8226 2378 domain\001
 4 1 -1 0 0 0 10 0.0000 6 105 465 8226 2603 number\001
 -6
-6 9720 0 12600 3015
-6 9900 495 12420 810
-2 4 0 1 0 36 50 0 20 0.000 0 0 7 0 0 5
-	 12420 810 9915 810 9915 500 12420 500 12420 810
-4 0 7 50 0 0 12 0.0000 4 180 1665 10005 725 Mesh and data setup\001
--6
-6 9900 2250 12420 2610
-2 4 0 1 0 36 50 0 20 0.000 0 0 7 0 0 5
-	 12420 2610 9900 2610 9900 2250 12420 2250 12420 2610
-4 0 7 50 0 0 12 0.0000 4 180 1860 9990 2520 Post-processing output\001
--6
-2 2 0 0 0 44 53 0 20 0.000 0 0 -1 0 0 5
-	 10095 0 10845 0 10845 320 10095 320 10095 0
-2 4 0 1 0 15 50 0 20 0.000 0 0 7 0 0 5
-	 12420 2115 9915 2115 9915 995 12420 995 12420 2115
-2 4 0 1 0 34 52 0 20 0.000 0 0 7 0 0 5
-	 12600 3015 9720 3015 9720 315 12600 315 12600 3015
-4 0 0 50 0 0 14 0.0000 4 165 645 10140 230 Kernel\001
-4 0 7 50 0 0 12 0.0000 4 180 1320 10005 1220 Specific physics\001
-4 0 6 50 0 2 12 0.0000 4 135 2085 9990 1755 Navier-Stokes resolution\001
-4 0 7 50 0 0 12 0.0000 4 135 930 9990 1485 Turbulence\001
-4 0 7 50 0 0 12 0.0000 4 135 1845 9990 2025 User-defined functions\001
-4 0 0 50 0 0 12 0.0000 4 135 1665 10305 2880 MPI communication\001
--6
 6 13500 0 14445 1305
 5 1 0 1 -1 -1 0 0 -1 0.000 0 1 0 0 13988.000 -382.500 13538 300 13988 435 14438 300
 5 1 0 1 -1 -1 0 0 -1 0.000 0 1 0 0 13988.000 472.500 13538 1155 13988 1290 14438 1155
@@ -619,14 +576,35 @@ Single
 	 10935 -360 8340 -360 8340 -1300 10935 -1300 10935 -360
 4 0 0 50 0 16 14 0.0000 4 165 435 8610 -1390 GUI\001
 -6
+6 9900 495 12420 1125
+2 4 0 1 0 36 50 0 20 0.000 0 0 7 0 0 5
+	 12420 1125 9915 1125 9915 500 12420 500 12420 1125
+4 0 7 50 0 0 12 0.0000 4 135 1545 10005 725 Mesh modification\001
+4 0 7 50 0 0 12 0.0000 4 180 1665 9990 990 Mesh and data setup\001
+-6
+6 9900 1305 12420 2430
+2 4 0 1 0 15 50 0 20 0.000 0 0 7 0 0 5
+	 12420 2430 9915 2430 9915 1310 12420 1310 12420 2430
+4 0 6 50 0 2 12 0.0000 4 135 2085 9990 1485 Navier-Stokes resolution\001
+4 0 7 50 0 0 12 0.0000 4 135 1845 9990 1755 User-defined functions\001
+4 0 7 50 0 0 12 0.0000 4 135 930 9990 2025 Turbulence\001
+4 0 7 50 0 0 12 0.0000 4 180 1320 9990 2295 Specific physics\001
+-6
+6 9900 2610 12420 2970
+2 4 0 1 0 36 50 0 20 0.000 0 0 7 0 0 5
+	 12420 2970 9900 2970 9900 2610 12420 2610 12420 2970
+4 0 7 50 0 0 12 0.0000 4 180 1860 9990 2880 Post-processing output\001
+-6
+6 2610 495 4950 900
+2 4 0 0 0 9 50 0 20 0.000 0 0 7 0 0 5
+	 4950 900 2625 900 2625 500 4950 500 4950 900
+4 0 6 50 0 2 12 0.0000 4 180 2100 2700 765 Read and append meshes\001
+-6
 2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2
 	1 0 1.00 60.00 120.00
 	 1665 720 2430 720
 2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2
 	1 0 1.00 60.00 120.00
-	 5085 1890 6030 1890
-2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2
-	1 0 1.00 60.00 120.00
 	 6480 1440 6480 990
 2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2
 	1 0 1.00 60.00 120.00
@@ -639,7 +617,7 @@ Single
 	 6480 2745 6480 3015 9180 3015 9180 810 9720 810
 2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 4
 	1 0 1.00 60.00 120.00
-	 2437 1845 2070 1845 2070 2565 1665 2565
+	 2437 1479 2069 1479 2070 2565 1665 2565
 2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2
 	1 0 1.00 60.00 120.00
 	 12592 2430 13550 2430
@@ -653,3 +631,21 @@ Single
 2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2
 	1 0 1.00 60.00 120.00
 	 10935 -900 11700 -900
+2 2 0 0 0 44 53 0 20 0.000 0 0 -1 0 0 5
+	 10095 0 10845 0 10845 320 10095 320 10095 0
+2 4 0 1 0 34 52 0 20 0.000 0 0 7 0 0 5
+	 12600 3375 9720 3375 9720 315 12600 315 12600 3375
+2 2 0 0 0 44 54 0 20 0.000 0 0 -1 0 0 5
+	 2670 5 4245 5 4245 320 2670 320 2670 5
+2 4 0 0 0 21 50 0 20 0.000 0 0 7 0 0 5
+	 4944 1715 2625 1715 2625 1085 4944 1085 4944 1715
+2 4 0 1 0 34 52 0 20 0.000 0 0 7 0 0 5
+	 5079 1872 2445 1872 2445 320 5079 320 5079 1872
+2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2
+	1 0 1.00 60.00 120.00
+	 5079 1792 6024 1792
+4 0 0 50 0 0 14 0.0000 4 165 645 10140 230 Kernel\001
+4 0 0 50 0 0 12 0.0000 4 135 1665 10350 3240 MPI communication\001
+4 0 0 50 0 16 14 0.0000 4 210 1425 2715 230 Preprocessor\001
+4 0 7 50 0 0 12 0.0000 4 180 2040 2715 1310 Descending connectivity\001
+4 0 7 50 0 0 12 0.0000 4 180 1560 2713 1575 Verification output\001
diff --git a/doc/user/saturne1.tex b/doc/user/saturne1.tex
index e94d84d..14ed1cd 100644
--- a/doc/user/saturne1.tex
+++ b/doc/user/saturne1.tex
@@ -317,10 +317,11 @@ the
 \label{prg_library}%
 Information about the content of the \CS base directories is given below. It
 is not of vital interest for the user, but given only as general
-information. Indeed, the case preparer command \texttt{cs~create} automatically extracts the
-necessary files and prepares the launch script without the user having to go
-directly into the \CS base directories (see \S\ref{prg_cscreate}).
-The \texttt{cs~info} command gives direct
+information. Indeed, the case preparer command \texttt{code\_saturne~create}
+automatically extracts the necessary files and prepares the launch script
+without the user having to go directly into the \CS base directories
+(see \S\ref{prg_cscreate}).
+The \texttt{code\_saturne~info} command gives direct
 access to the most needed information (especially the user and programmer's
 guides and the tutorial) without the user having to look for them in the \CS
 directories.
@@ -344,8 +345,8 @@ under subdirectories corresponding to each module:
 \texttt{mati} (Matisse module),
 \texttt{pprt} (general specific physics routines) and
 \texttt{rayt} (radiative heat transfer).
-The case preparer command \texttt{cs~create} copies all these files in the
-user directory \texttt{SRC/REFERENCE} during the case preparation.
+The case preparer command \texttt{code\_saturne~create} copies all these files
+in the user directory \texttt{SRC/REFERENCE} during the case preparation.
 
 The ``include'' files are available in the directory
 \texttt{include}, under similar subdirectories corresponding to each module:
@@ -369,15 +370,16 @@ prepare and run a standard case:
 \begin{list}{$\bullet$}{}
 
 \item Check the version of \CS set for use in the environment variables
-(\texttt{cs~info --version}). If it does not correspond to the desired version,
-update the \texttt{.profile} file to set the environment
+(\texttt{code\_saturne~info --version}). If it does not correspond to
+the desired version, update the \texttt{.profile} file to set the environment
 variables correctly. Log out of the session and
 log in again to take the modifications into account properly (cf.
 \S\ref{prg_environementCS}).
 
-\item Prepare the different directories using the \texttt{cs~create} command
-(see \S\ref{prg_cscreate}) and, when needed, add the directories \texttt{DATA\_SYR}
-and \texttt{SRC\_SYR} which are required to accomodate the \syrthes files.
+\item Prepare the different directories using the \texttt{code\_saturne~create}
+command (see \S\ref{prg_cscreate}) and, when needed, add the directories
+\texttt{DATA\_SYR} and \texttt{SRC\_SYR} which are required to accomodate the
+\syrthes files.
 
 \item Place the mesh(es) in the directory \texttt{MESH}. Make sure they are
 in a format compliant with \CS (see \S\ref{prg_maillages}). There can be
@@ -693,21 +695,21 @@ way whenever they wish.
 \subsection{Case preparer}
 %==================================
 \label{prg_cscreate}%
-The case preparer command \texttt{cs~create} automatically creates a
+The case preparer command \texttt{code\_saturne~create} automatically creates a
 study directory according to the typical architecture and copies and
 pre-fills an example of calculation launch script.
 
-The syntax of \texttt{cs~create} is as follows:
+The syntax of \texttt{code\_saturne~create} is as follows:
 
 \noindent
-\texttt{cs~create --study STUDY CASE\_NAME1 CASE\_NAME2...}\\
+\texttt{code\_saturne~create --study STUDY CASE\_NAME1 CASE\_NAME2...}\\
 creates a study directory \texttt{STUDY} with case subdirectories
 \texttt{CASE\_NAME1} and \texttt{CASE\_NAME2}...
 If no case name is given, a default case directory called \texttt{CASE1} is
 created.
 
 \noindent
-\texttt{cs~create --case DEBIT3 --case DEBIT4}\\
+\texttt{code\_saturne~create --case DEBIT3 --case DEBIT4}\\
 executed in the directory \texttt{STUDY} adds the case directories
 \texttt{DEBIT3} and \texttt{DEBIT4}.
 
@@ -715,18 +717,19 @@ An option \texttt{--nogui} is available for the use of \CS
 without Graphic Interface (see \S\ref{prg_gui}). This option must
 be either the first or the last argument and appear only once.
 
-In the directory \texttt{DATA}, the \texttt{cs~create} command places a
-subdirectory \texttt{THCH} containing examples of thermochemical data
+In the directory \texttt{DATA}, the \texttt{code\_saturne~create} command
+places a subdirectory \texttt{THCH} containing examples of thermochemical data
 files used for pulverised coal combustion,
 gas combustion or electric arc. The file to be used for the calculation must be
 copied directly in the \texttt{DATA} directory and its name must be referenced
 in the launch script in the variable THERMOCHEMISTRY\_DATA. All other files in
 the \texttt{DATA} or in the \texttt{THCH} will be ignored.\\
-The \texttt{cs~create} command also places in the directory \texttt{DATA}
-the launch script for the Graphical User Interface: \texttt{SaturneGUI}.
+The \texttt{code\_saturne~create} command also places in the directory
+\texttt{DATA} the launch script for the Graphical User Interface:
+\texttt{SaturneGUI}.
 
 
-In the directory \texttt{SRC}, the \texttt{cs~create} command creates a
+In the directory \texttt{SRC}, the \texttt{code\_saturne~create} command creates a
 subdirectory \texttt{REFERENCE} containing all the user subroutines,
 classified by module type:  \texttt{base},
 \texttt{cfbl}, \texttt{cogz}, \texttt{cplv}, \texttt{elec}, \texttt{fuel},
@@ -734,7 +737,7 @@ classified by module type:  \texttt{base},
 Only the user subroutines placed directly under
 the directory \texttt{SRC} will be considered. The others will be ignored.
 
-In the directory \texttt{SCRIPTS}, the \texttt{cs~create} command copies and
+In the directory \texttt{SCRIPTS}, the \texttt{code\_saturne~create} command copies and
 pre-fills an example of the launch script: \texttt{runcase}.
 The study, case and user name are filled
 automatically in the launch script, as are the paths leading to the
@@ -778,7 +781,6 @@ from the file suffix: %
 {\em``\texttt{.ccm}''} for STAR-CCM+,
 {\em``\texttt{.cgns}''} for CGNS,
 {\em``\texttt{.des}''} for \simail,
-{\em``\texttt{.hex}''} for IGG/Hexa,
 {\em``\texttt{.med}''} for \med,
 {\em``\texttt{.msh}''} for \gmsh,
 {\em``\texttt{.neu}''} for \gambit neutral,
@@ -848,7 +850,7 @@ the I-deas tool has not focused on the CFD (or even meshing) market since
 many years, it is handled (at least in part) by many tools, and may
 be considered as a major ``legacy'' format. It may contain many different
 datasets, relative to CAD, meshing, materials, calculation results,
-or part representation. Most of these datasets are ignored by CS,
+or part representation. Most of these datasets are ignored by \CS,
 and only those relative to vertex, element, group, and coordinate system
 definitions are handled.
 
@@ -1606,7 +1608,7 @@ command line options.
 %==================================
 \label{prg_runcase}%
 
-The case preparer command \texttt{cs~create} places an example of launch script,
+The case preparer command \texttt{code\_saturne~create} places an example of launch script,
 \texttt{runcase}, in the \texttt{SCRIPTS} directory. This script is quite general
 and known to work on every architecture \CS has been tested on. The beginning
 if the script contains the definition of certain parameters (environment
@@ -1641,10 +1643,10 @@ Kernel (see \ref{prg_optappelnoy})
 
 \begin{list}{$\bullet$}{}
 \item \texttt{STUDY}: name of the study directory (automatically set by
-\texttt{cs~create}, see \S\ref{prg_architecture})
+\texttt{code\_saturne~create}, see \S\ref{prg_architecture})
 
 \item \texttt{CASE}: name of the case directory (automatically set by
-\texttt{cs~create}, see \S\ref{prg_architecture})
+\texttt{code\_saturne~create}, see \S\ref{prg_architecture})
 
 \item \texttt{PARAM}: name of the Interface parameter file, if necessary (see
 \ref{prg_optappelnoy})
@@ -1746,23 +1748,23 @@ adaptation with the software Homard. This option is still under development and
 restricted to developpers use.
 
 \item \texttt{CASEDIR}: root directory of the calculation. This variable is
-automatically set by \texttt{cs~create} and should not be changed.
+automatically set by \texttt{code\_saturne~create} and should not be changed.
 
 \item \texttt{DATA}: DATA directory of the case (see \ref{prg_architecture}).
-This variable is automatically set by \texttt{cs~create} and should not be
+This variable is automatically set by \texttt{code\_saturne~create} and should not be
 changed.
 
 \item \texttt{RESU}: RESU directory of the case (see \ref{prg_architecture}).
-This variable is automatically set by \texttt{cs~create} and should not be
+This variable is automatically set by \texttt{code\_saturne~create} and should not be
 changed.
 
 \item \texttt{SRC}: SRC directory of the case (see \ref{prg_architecture}).
-This variable is automatically set by \texttt{cs~create} and should not be
+This variable is automatically set by \texttt{code\_saturne~create} and should not be
 changed.
 
 \item \texttt{SCRIPTS}: SCRIPTS directory of the case (see
 \ref{prg_architecture}). This variable is automatically set by
-\texttt{cs~create} and should not be changed.
+\texttt{code\_saturne~create} and should not be changed.
 
 \item \texttt{RESTART\_IN}: directory containing the files for calculation
 restart.
@@ -1771,7 +1773,7 @@ restart.
 
 \item \texttt{MESHDIR}: directory containing the mesh files (see
 \ref{prg_architecture}). This variable is automatically set by
-\texttt{cs~create} and should generally not be changed.
+\texttt{code\_saturne~create} and should generally not be changed.
 
 \item \texttt{DATA\_SYR}: directory for the \syrthes data. This directory has
 to be created by the user. It is advised to keep the location proposed
@@ -1906,20 +1908,20 @@ Prepare batch analysis), the PARAM section is filled automatically as are the
 other parameters specified through the Interface.
 
 
-\minititre{Note: option \texttt{--nogui} of the \texttt{cs~create} command}
+\minititre{Note: option \texttt{--nogui} of the \texttt{code\_saturne~create} command}
 When a calculation is using the Interface but, for some reason, some extra
 parameters need to be specified in the subroutine \texttt{usini1}, the latter
 must be placed in the directory \texttt{SRC}. But, while doing this, all the
 parameters appearing in \texttt{usini1} will also be taken into account. In
 order to prevent the user from having to respecify in \texttt{usini1} all that
-he has already specified through the Interface, \texttt{cs~create} automatically
+he has already specified through the Interface, \texttt{code\_saturne~create} automatically
 comments out the examples in \texttt{usini1} (\texttt{Cex} at the beginning of
 each line) while copying it in the directory \texttt{REFERENCE}. Therefore, the user
 only needs to uncomment the specific parts of \texttt{usini1} he wants to modify,
 and the rest of the examples will be ignored.\\
 On the contrary, if the Interface will not be used, then all the parameters in
 \texttt{usini1} have to be specified. In that case, using the \texttt{--nogui}
-option of \texttt{cs~create} will prevent it from commenting \texttt{usini1}
+option of \texttt{code\_saturne~create} will prevent it from commenting \texttt{usini1}
 out, thus saving the user the tedious task of uncommenting all the lines (and
 the risk of skipping some of them).
 
@@ -2127,7 +2129,7 @@ and does not detailed knowledge of the \pcs command line.
 Nonetheless, it may be useful to call the \pcs manually
 in certain situations, especially for frequent verification when
 building a mesh, so its use is described here. Verification
-may also be done using the \texttt{cs~check\_mesh} command,
+may also be done using the \texttt{code\_saturne~check\_mesh} command,
 which takes a subset of the same command-line arguments.
 
 The \pcs is controlled using command-line arguments, some of these
@@ -4249,7 +4251,7 @@ subroutine. In the case that a parameter is specified in the interface
  and in the user subroutine, it is the value in the user subroutine that
  is taken into acount. It is for that reason that all the examples of
  user subroutines are placed in the \texttt{REFERENCE} directory by the
- case preparer \texttt{cs~create}.
+ case preparer \texttt{code\_saturne~create}.
 
 
 
@@ -4408,11 +4410,11 @@ $\bullet\ $ When using the interface, only the
 supplementary parameters (which can not be defined in the interface)
 should appear in \texttt{usini1}. To spare the user the necessity to
 delete the other parameters appearing as examples in the subroutine, the
-utility program \texttt{cs~create} comments automatically all the
+utility program \texttt{code\_saturne~create} comments automatically all the
 example lines of \texttt{usini1} with a code \texttt{!ex}. The user
 needs then only to uncomment the lines which are useful in his
 case. This function of
-\texttt{cs~create} can be inactivated with
+\texttt{code\_saturne~create} can be deactivated with
 the option \texttt{--nogui} (useful if the user knows that he will not
 use the interface).
 
@@ -4444,7 +4446,7 @@ For more details about the treatment of boundary conditions, the user
 may refer to the theoretical and computer documentation \cite{theory} of
 the subroutine \texttt{condli} (for the wall conditions, see
 \texttt{clptur}) (to access to this document on a workstation, use
-\mbox{\texttt{cs~info --guide theory}}).
+\mbox{\texttt{code\_saturne~info --guide theory}}).
 
 From the user point of view, the boundary conditions are totally
 determined by three arrays\footnote{except with Lagrangian}:
diff --git a/doc/user/saturne2.tex b/doc/user/saturne2.tex
index 673fc19..26f0b47 100644
--- a/doc/user/saturne2.tex
+++ b/doc/user/saturne2.tex
@@ -1709,7 +1709,7 @@ always useful}
 the gradient calculation with {\tt imrgra}=3.\\
 {\tt anomax}=0 will yield the same result as {\tt imrgra}=2 (full extended
 neighborhood). {\tt anomax}=$\pi/2$ will yield the same result as
-{\tt imrgra}=2
+{\tt imrgra}=1
 (first neighbors only)\footnote{except for pathological cases where the
 non-orthogonality angle of a face would be larger than $\pi/2$}\\
 useful if and only if {\tt imrgra}=3}
diff --git a/examples/1-simple_junction/case1/case1.xml b/examples/1-simple_junction/case1/case1.xml
index 63e12af..8973acb 100644
--- a/examples/1-simple_junction/case1/case1.xml
+++ b/examples/1-simple_junction/case1/case1.xml
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE1" study="SIMPLE_JUNCTION" version="1.0">
+<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE1" study="SIMPLE_JUNCTION" version="2.0">
 	<solution_domain>
 		<volumic_conditions>
 			<zone head_losses="off" initialization="on" label="all_cells" mass_source_term="off" momentum_source_term="off" name="1" scalar_source_term="off" thermal_source_term="off">all[]</zone>
@@ -9,22 +9,21 @@
 		<join_meshes status="off"/>
 		<faces_cutting status="off"/>
 		<reorientation status="off"/>
-		<syrthes_coupling status="off"/>
 		<periodic_boundary/>
 		<standalone/>
 	</solution_domain>
 	<thermophysical_models>
 		<velocity_pressure>
-			<variable label="Pression" name="pressure">
+			<variable label="Pressure" name="pressure">
 				<reference_pressure>101325</reference_pressure>
 			</variable>
-			<variable label="VitesseX" name="velocity_U">
+			<variable label="VelocityX" name="velocity_U">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseY" name="velocity_V">
+			<variable label="VelocityY" name="velocity_V">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseZ" name="velocity_W">
+			<variable label="VelocityZ" name="velocity_W">
 				<blending_factor>1</blending_factor>
 			</variable>
 			<property label="total_pressure" name="total_pressure"/>
@@ -34,28 +33,30 @@
 		</velocity_pressure>
 		<ale_method status="off"/>
 		<turbulence model="k-epsilon">
-			<variable label="EnerTurb" name="turb_k"/>
+			<variable label="TurbEnergy" name="turb_k"/>
 			<variable label="Dissip" name="turb_eps"/>
-			<property label="visc. tu" name="turb_viscosity"/>
+			<property label="TurbVisc" name="turb_viscosity"/>
 			<initialization choice="reference_velocity">
 				<reference_velocity>1</reference_velocity>
 			</initialization>
-			<scale_model>1</scale_model>
-			<gravity_terms status="on"/>
 		</turbulence>
 		<thermal_scalar model="temperature_celsius">
-			<property label="Flux_thermique_entrant" name="input_thermal_flux" support="boundary"/>
+			<property label="Input_thermal_flux" name="input_thermal_flux" support="boundary"/>
 		</thermal_scalar>
 		<radiative_transfer model="off">
 			<restart status="off"/>
 			<absorption_coefficient type="constant">0</absorption_coefficient>
 		</radiative_transfer>
+		<conjugate_heat_transfer>
+			<external_coupling status="off"/>
+			<external_coupling status="off"/>
+			<external_coupling status="on"/>
+		</conjugate_heat_transfer>
 		<gas_combustion model="off"/>
 		<pulverized_coal model="off"/>
 		<joule_effect model="off"/>
-		<atmospheric_flows model="off">
-			<read_meteo_data status="off"/>
-		</atmospheric_flows>
+		<atmospheric_flows model="off"/>
+		<heads_losses/>
 	</thermophysical_models>
 	<numerical_parameters>
 		<multigrid status="on"/>
@@ -67,22 +68,22 @@
 	</numerical_parameters>
 	<physical_properties>
 		<fluid_properties>
-			<property choice="constant" label="Masse vo" name="density">
+			<property choice="constant" label="Density" name="density">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>725.735</initial_value>
 			</property>
-			<property choice="constant" label="Visc. la" name="molecular_viscosity">
+			<property choice="constant" label="Molecular_visc" name="molecular_viscosity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
-				<initial_value>8.95e-05</initial_value>
+				<initial_value>8.951e-05</initial_value>
 			</property>
-			<property choice="constant" label="Ch.spec." name="specific_heat">
+			<property choice="constant" label="Sp_heat" name="specific_heat">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>5483</initial_value>
 			</property>
-			<property choice="constant" label="Cond. th" name="thermal_conductivity">
+			<property choice="constant" label="Th_conduc" name="thermal_conductivity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>0.02495</initial_value>
@@ -96,16 +97,16 @@
 		<hydrostatic_pressure status="off"/>
 	</physical_properties>
 	<additional_scalars>
-		<scalar label="Temp.C" name="temperature_celsius" type="thermal">
-			<initial_value zone="1">20.0</initial_value>
-			<min_value>-1e+12</min_value>
-			<max_value>1e+12</max_value>
+		<scalar label="TempC" name="temperature_celsius" type="thermal">
+			<initial_value label="all_cells" zone="1">20.0</initial_value>
+			<min_value>0</min_value>
+			<max_value>400</max_value>
 			<blending_factor>1</blending_factor>
 		</scalar>
 	</additional_scalars>
 	<boundary_conditions>
-		<boundary label="Inlet" name="1" nature="inlet">1</boundary>
-		<inlet label="Inlet">
+		<boundary label="inlet" name="1" nature="inlet">1</boundary>
+		<inlet label="inlet">
 			<velocity_pressure choice="norm" direction="coordinates">
 				<norm>1</norm>
 				<direction_x>1</direction_x>
@@ -115,34 +116,31 @@
 			<turbulence choice="hydraulic_diameter">
 				<hydraulic_diameter>0.5</hydraulic_diameter>
 			</turbulence>
-			<scalar choice="dirichlet" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="dirichlet" label="TempC" name="temperature_celsius" type="thermal">
 				<dirichlet>300</dirichlet>
 			</scalar>
 		</inlet>
-		<boundary label="Outlet" name="2" nature="outlet">5</boundary>
-		<outlet label="Outlet">
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
-				<neumann>0</neumann>
+		<boundary label="outlet" name="2" nature="outlet">5</boundary>
+		<boundary label="symmetry" name="3" nature="symmetry">8 or 9</boundary>
+		<boundary label="walls" name="4" nature="wall">2 or 3 or 4 or 6 or 7</boundary>
+		<symmetry label="symmetry"/>
+		<outlet label="outlet">
+			<scalar choice="dirichlet" label="TempC" name="temperature_celsius" type="thermal">
+				<dirichlet>0</dirichlet>
 			</scalar>
 		</outlet>
-		<boundary label="Symmetry" name="3" nature="symmetry">8 or 9</boundary>
-		<symmetry label="Symmetry"/>
-		<boundary label="Walls" name="4" nature="wall">2 or 3 or 4 or 6 or 7</boundary>
-		<wall label="Walls">
-			<velocity_pressure choice="off">
-				<dirichlet name="velocity_U">0</dirichlet>
-				<dirichlet name="velocity_V">0</dirichlet>
-				<dirichlet name="velocity_W">0</dirichlet>
-			</velocity_pressure>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+		<variable/>
+		<wall label="walls">
+			<velocity_pressure choice="off"/>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 		</wall>
-		<variable/>
 	</boundary_conditions>
 	<analysis_control>
 		<output>
 			<postprocessing_mesh_options choice="0"/>
+			<syrthes_boundary status="off"/>
 			<domain_boundary status="off"/>
 			<listing_printing_frequency>1</listing_printing_frequency>
 			<postprocessing_frequency>-1</postprocessing_frequency>
@@ -152,11 +150,10 @@
 			<postprocessing_options choice="binary"/>
 		</output>
 		<time_parameters>
-			<property label="Nb Courant" name="courant_number"/>
-			<property label="Nb Fourier" name="fourier_number"/>
 			<time_step_ref>0.1</time_step_ref>
 			<iterations>10</iterations>
 			<time_passing>0</time_passing>
+			<zero_time_step status="off"/>
 		</time_parameters>
 		<steady_management status="on">
 			<zero_iteration status="off"/>
@@ -164,8 +161,15 @@
 			<relaxation_coefficient>0.9</relaxation_coefficient>
 		</steady_management>
 		<time_averages/>
+		<profiles/>
 	</analysis_control>
 	<calcul_management>
+		<start_restart>
+			<restart status="off"/>
+			<frozen_field status="off"/>
+			<restart_rescue>0</restart_rescue>
+			<restart_with_auxiliary status="on"/>
+		</start_restart>
 		<integer_user_array>
 			<ncelet>0</ncelet>
 			<nfac>0</nfac>
@@ -178,6 +182,18 @@
 			<nfabor>0</nfabor>
 			<dimless>0</dimless>
 		</real_user_array>
+		<integer_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</integer_work_array>
+		<real_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</real_work_array>
 	</calcul_management>
 	<lagrangian model="off"/>
 </Code_Saturne_GUI>
diff --git a/examples/1-simple_junction/case1/runcase b/examples/1-simple_junction/case1/runcase
deleted file mode 100755
index 97d4218..0000000
--- a/examples/1-simple_junction/case1/runcase
+++ /dev/null
@@ -1,1125 +0,0 @@
-#!/bin/sh
-# bin/runcase.  Generated from runcase.in by configure.
-#============================================================================
-#
-#     This file is part of the Code_Saturne Kernel, element of the
-#     Code_Saturne CFD tool.
-#
-#     Copyright (C) 1998-2009 EDF S.A., France
-#
-#     contact: saturne-support at edf.fr
-#
-#     The Code_Saturne Kernel is free software; you can redistribute it
-#     and/or modify it under the terms of the GNU General Public License
-#     as published by the Free Software Foundation; either version 2 of
-#     the License, or (at your option) any later version.
-#
-#     The Code_Saturne Kernel 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 General Public License for more details.
-#
-#     You should have received a copy of the GNU General Public License
-#     along with the Code_Saturne Kernel; if not, write to the
-#     Free Software Foundation, Inc.,
-#     51 Franklin St, Fifth Floor,
-#     Boston, MA  02110-1301  USA
-#
-#============================================================================
-#
-########################################################################
-#
-#                  BATCH FILE FOR THE CCRT (Platine under LSF)
-#                  ===========================================
-#
-#BSUB -n 2
-#BSUB -W 00:05
-#BSUB -o simple_junctioncase1o.%J
-#BSUB -e simple_junctioncase1e.%J
-#BSUB -J simple_junctioncase1
-#
-#  -n : number of processors
-#  -W : walltime as hh:mm
-#  -o : output file name
-#  -e : error file name
-#  -J : job name
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE FOR THE Chatou CLUSTER (PBS)
-#                  =======================================
-#
-#PBS -l nodes=4:ppn=2
-#PBS -l walltime=1:00:00
-#PBS -l mem=320mb
-#
-#PBS -j eo
-#PBS -N simple_junctioncase1
-#
-#  nodes    : number of nodes
-#  ppn      : number of process per node
-#  walltime : wall clock time (hh:mm:ss)
-#  mem      : memory
-#
-#WARNING: when coupling with SYRTHES, 1 processor will be reserved for each
-#         instance of SYRTHES. The Kernel will be executed on the remaining
-#         processors, so make sure to reserve a sufficiently high number
-#         of processors.
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (University of Manchester Cluster)
-#                  =============================================
-#
-# set the name of the job
-##$ -N simple_junctioncase1
-#
-# request between 2 and 4 slots
-##$ -pe mpich 2-4
-#
-# Execute the job from the current working directory
-# Job output will appear in this directory
-##$ -cwd
-#   can use -o dirname to redirect stdout
-#   can use -e dirname to redirect stderr
-
-#  Export these environment variables
-##$ -v MPI_HOME
-
-#set -x
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (AIX, Loadlever)
-#                  ===========================
-#
-#@ shell = /bin/sh
-#
-#@ job_name = simple_junctioncase1
-#
-#@ job_type = parallel
-#@ cpus = 128
-#@ node_usage = not_shared
-#
-#@ network.MPI = csss,shared,US
-#@ bulkxfer = yes
-#
-#@ wall_clock_limit = 00:20:00
-#@ account_no = z001
-#
-#@ output = $(job_name).$(schedd_host).$(jobid).out
-#@ error  = $(job_name).$(schedd_host).$(jobid).err
-#@ notification = never
-#
-#@ queue
-# suggested environment settings:
-#  export MP_EAGER_LIMIT=65536
-#  export MP_SHARED_MEMORY=yes
-#  export MEMORY_AFFINITY=MCM
-#  export MP_TASK_AFFINITY=MCM
-#
-########################################################################
-#
-# BEGINNING OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-# runcase.help gives more details about the different variables.
-#
-#                    -------------------------------
-#
-SOLCOM=0
-#
-# On some systems, some external libraries may require TERM to be defined.
-export TERM=xterm
-#
-STUDY=SIMPLE_JUNCTION
-CASE=CASE1
-PARAM=case1.xml
-MESH=downcomer.des
-COMMAND_REORIENT=
-COMMAND_JOIN=
-COMMAND_CWF=
-COMMAND_PERIO=
-THERMOCHEMISTRY_DATA=
-METEO_DATA=
-#
-# Choose the total number of processors used (if empty, automatic detection
-# through the batch system if possible, set to 1 otherwise).
-# When coupling with SYRTHES with COUPLING_MODE=MPI, the 1st processor is
-# used by SYRTHES, so the effective number of processors assigned to the
-# Kernel is reduced by 1.
-# The processors list is only usable when not running on a batch system
-# (as such a system usually already defines a similar list)
-NUMBER_OF_PROCESSORS=
-PROCESSOR_LIST=
-#
-PARTITION_LIST=
-#
-USER_INPUT_FILES=
-USER_OUTPUT_FILES=
-#
-# Working directory (leave empty for automatic default directory)
-CS_TMP_PREFIX=
-#CS_TMP_PREFIX=/local00/users/`whoami`
-#
-CS_LIB_ADD=
-VALGRIND=
-#
-ARG_CS_VERIF=
-ARG_CS_OUTPUT=
-#
-# Adaptation using HOMARD
-ADAPTATION=
-#
-summary=summary
-CASEDIR=/home/saturne/TEST_CASE/SIMPLE_JUNCTION/CASE1
-DATA=$CASEDIR/DATA
-RESU=$CASEDIR/RESU
-SRC=$CASEDIR/SRC
-SCRIPTS=$CASEDIR/SCRIPTS
-RESTART_IN=$DATA/RESTART
-PREPROCESSOR_OUTPUT_IN=$DATA/preprocessor_output
-PARTITION_OUTPUT_IN=$DATA/PARTITION_OUTPUT
-MESHDIR=$CASEDIR/../MESH
-#
-# The following variables are only used in case of coupling with SYRTHES.
-#  DATA_SYR: directory where to find SYRTHES_ENV
-#  SRC_SYR:  directory where to find possible user source files
-DATA_SYR=$CASEDIR/DATA_SYR
-SRC_SYR=$CASEDIR/SRC_SYR
-SYRTHES_ENV=syrthes.env
-#
-# The possible coupling mode with SYRTHES may be chosen here.
-#
-#  COUPLING_MODE=MPI        : should work on most machines.
-#  COUPLING_MODE=sockets    : should be activated on clusters when the MPI rank
-#                             of a process is not determinable or if MPI can
-#                             not be used.
-COUPLING_MODE=MPI
-ECHO_SYR_COMM=""
-#
-#  Indicate which steps should be executed; if both the Preprocessor and the
-#  Kernel are executed, the "preprocessor_output" and eventual "domain_number_*"
-#  files are not saved. If only the preprocessor and / or partitioner are
-#  executed, the corresponding files will be saved in a RESU/PREPROCESSOR_OUTPUT
-#  and RESU/PARTITION directory. If the Preprocessor is not executed,
-#  "preprocessor_output" will be read from $PREPROCESSOR_OUTPUT_IN. If the
-#  Partitioner is not executed, "domain_number_*" will be read from
-#  $PARTITION_OUTPUT_IN if available (otherwise, unoptimized default
-#  partitioning will be used).
-#
-#  EXEC_PREPROCESS : should the Preprocessor be run ? (yes/no)
-#  EXEC_PARTITION  : should the Partitioner be run ? (yes/no)
-#  EXEC_KERNEL     : should the Kernel be run ? (yes/no)
-#
-EXEC_PREPROCESS=yes
-EXEC_PARTITION=yes
-EXEC_KERNEL=yes
-#
-#
-#
-########################################################################
-#
-# END OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-########################################################################
-#
-# Kernel installation parameters
-#
-prefix=/home/saturne/Code_Saturne/2.0-beta2/arch/Linux_x86_64
-#
-exec_prefix=${prefix}
-bindir=${exec_prefix}/bin
-datarootdir=${prefix}/share
-datadir=${datarootdir}
-pkgdatadir=${datadir}/ncs
-#
-# Preprocessor installation parameters
-#
-ecs_prefix=
-#
-ecs_exec_prefix=${ecs_prefix}
-ecs_bindir=${ecs_exec_prefix}/bin
-#
-# HOMARD installation parameters (to be completed if needed)
-#
-homard_prefix=
-#
-########################################################################
-#  Mesh Adaptation
-#
-if [ ! -z  "${ADAPTATION}" ] ; then
-  if [ "${ADAPTATION}" = "-help" ] ; then
-    ${homard_prefix}/saturne_homard ${ADAPTATION}
-    exit 0
-  else
-    HOMARD_options="  -v"
-    ${homard_prefix}/saturne_homard -Saturne_Script $0 -Donnees_Calcul $CASEDIR \
-                    -Pilotage_Adaptation $ADAPTATION $HOMARD_options || exit 1
-  fi
-fi
-#
-#########################################################################
-#
-N_SYRTHES_COUPLINGS=0
-if [ -f "${SRC}/ussyrc.f90" ] ; then
-  N_SYRTHES_COUPLINGS=`grep -e ^' ' ${SRC}/ussyrc.f90 | grep -i -c defsyr`
-fi
-#
-if [ $N_SYRTHES_COUPLINGS = 0 ] ; then
-  SYRTHES_COUPLING=no
-else
-  SYRTHES_COUPLING=yes
-  export SYRTHES
-  if [ $N_SYRTHES_COUPLINGS -gt 1 ] ; then
-   echo "This script can not handle multiple couplings with SYRTHES"
-   echo "Number of SYRTHES couplings requested: $N_SYRTHES_COUPLINGS"
-  fi
-fi
-#
-if [ $SYRTHES_COUPLING = yes ] ; then
-  if [ $SOLCOM -eq 1 ] ; then
-   echo "SYRTHES coupling is not compatible with SOLCOM-type meshes"
-   exit 1
-  fi
-else
-  COUPLING_MODE=
-fi
-#
-########################################################################
-#
-# Parameters for execution
-#
-# General variables
-THISSCRIPT=$0
-USER=`whoami`
-DATE=`date '+%m%d%H%M'`
-SUFFIX=$DATE
-EXE=cs_solver
-EXE_SYR=syrthes
-#
-# Copy runcase before changing to the working directory
-# (as after that, the relative path will not be up to date).
-#
-cp $0 $RESU/runcase.$SUFFIX
-#
-# Execution directory (reachable by all the processors)
-#
-if [ ! -z "$CS_TMP_PREFIX" ] ; then
-  RUN=${CS_TMP_PREFIX}/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-else
-#  Default if not specified by the user
-#
-#  On the CCRT, there is no TMPDIR. We work by default in SCRATCHDIR
-  if [ "$SCRATCHDIR" != "" ] ; then
-    RUN=$SCRATCHDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-  elif [ "$TMPDIR" != "" -a "$TMPDIR" != "/tmp" ] ; then
-    RUN=$TMPDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-  else
-    RUN=$HOME/tmp_Saturne/$STUDY.$CASE.$DATE
-  fi
-fi
-#
-# Create directory if necessary
-if [ "$RUN" != "$TMPDIR" ] ; then
-  if [ ! -d $RUN ] ; then
-    mkdir -p $RUN || exit 1
-  else
-    echo "RUN=$RUN already exists."
-    echo "The simulation will not be run."
-    exit 1
-  fi
-fi
-#
-# Create a temporary file for Salome (equivalent to "ficstp")
-if [ "$ARG_CS_OUTPUT" = "--log 0" ] ; then
-  echo $RUN > $SCRIPTS/runningstd.$DATE
-else
-  echo $RUN > $SCRIPTS/runningext.$DATE
-fi
-#
-cd $RUN
-#
-########################################################################
-#
-# Set up MPI environment
-#
-# Use makefile query to obtain the path to MPI binaries if those are
-# not on the default path. This is a peculiar use of make, but allows
-# us to avoid defining the MPI configuration in multiple files.
-
-CS_MPI_PATH=/home/saturne/opt/openmpi-1.3.1/arch/Linux_x86_64/bin
-
-# NUMBER_OF_PROCESSORS is determined here if not already set;
-# MPIHOSTS, MPIRUN, MPIBOOT, MPIHALT, and NUMBER_OF_NODES are
-# defined by the sourced script, and PATH may be updated.
-#
-. ${pkgdatadir}/runcase_mpi_env
-#
-# Check for the number of requested processors
-nproc_kernel="${NUMBER_OF_PROCESSORS}"
-echo
-echo
-if [ $SYRTHES_COUPLING = yes ] ; then
-  echo "Coupling of Code_Saturne and SYRTHES activated."
-  #  1 processor is reserved for SYRTHES if coupled through MPI.
-  if [ "$COUPLING_MODE" = "MPI" ] ; then
-    (( nproc_kernel = nproc_kernel - N_SYRTHES_COUPLINGS ))
-    if [ $nproc_kernel -lt 1 ] ; then
-      echo
-      echo
-      echo " Warning, if COUPLING_MODE = MPI, SYRTHES reserves 1 processor"
-      echo " (which need not be a physical processor)."
-      echo " Here, NUMBER_OF_PROCESSORS=${NUMBER_OF_PROCESSORS}, while it must"
-      echo " be strictly greater than 1."
-      echo " Increase the number of requested processors."
-      echo
-      exit 1
-    fi
-  fi
-fi
-if [ $nproc_kernel -gt 1 ] ; then
-  echo "Parallel Code_Saturne with partitioning in $nproc_kernel sub-domains"
-  if [ $SOLCOM = 1 ] ; then
-    echo
-    echo
-    echo " Parallel run impossible with SOLCOM = $SOLCOM "
-    echo " Use SOLCOM = 0 "
-    echo
-    exit 1
-  fi
-else
-  echo "Single processor Code_Saturne simulation"
-fi
-if [ ! -z "$MPIHOSTS" ] ; then
-  echo "Total number of processors: $NUMBER_OF_PROCESSORS"
-fi
-#
-# In parallel mode, the corresponding argument must be set
-if [ $nproc_kernel -gt 1 ] ; then
-  ARG_CS_MPI=" --mpi"
-else
-  ARG_CS_MPI=""
-fi
-#
-#
-########################################################################
-#
-# Communications
-#
-# To help debug coupling problems, make communication more verbose
-if [ ! -z "$ECHO_SYR_COMM" ] ; then
-  ECHOCOMMSYR="-echo-comm $ECHO_SYR_COMM"
-else
-  ECHOCOMMSYR=""
-fi
-########################################################################
-# Greeting message
-#
-echo ' '
-echo '                      Code_Saturne is running '
-echo '                      *********************** '
-echo ' '
-echo ' Working directory (to be periodically cleaned) : '
-echo '    ' $RUN
-#
-########################################################################
-#
-# Compilation and link
-#
-# Note: we also check the for the presence of certain user subroutines here.
-#
-echo
-echo ' Kernel version:          ' $prefix
-echo ' Preprocessor version:    ' $ecs_prefix
-
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  cur_dir=`pwd`
-
-  source_cas=$SRC
-
-  #
-  # Copy of the parameter file
-  if [ ! -z "$PARAM" ] ; then
-    var=$DATA/$PARAM
-    if [ -f $var ] ; then
-      COMMAND_PARAM="--param $PARAM"
-      cp $var .
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The parameters file ' $var
-      echo ' can not be accessed.'
-      exit 1
-    fi
-  fi
-
-  src_files=`ls ${source_cas}/*.[fF]90 ${source_cas}/*.[ch] 2>/dev/null`
-
-  if [ ! -z "${src_files}" ] ; then
-
-    echo
-    echo  "  ***************************************************************"
-    echo  "   Compilation of user subroutines and linking of Code_Saturne"
-    echo  "  ***************************************************************"
-
-    if [ -f compil.log ] ; then
-      rm -f compil.log
-    fi
-
-    src_dir="src_saturne"
-
-    # Copy of the user source files
-    # (no links: the directory is copied later)
-    mkdir ${src_dir}
-    for f in ${src_files} ; do
-      if [ -f $f ] ; then
-        cp ${f} ${src_dir}/
-      fi
-    done
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --source=$src_dir --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    # Compilation
-    if [ ! -z "${CS_LIB_ADD}" ] ; then
-      OPTLIBS="--opt-libs=${CS_LIB_ADD}"
-    fi
-    ${bindir}/cs compile \
-      --source=$src_dir ${OPTLIBS} 2>>$cur_dir/compil.log 1>&2
-    if [ $? -ne 0 ]
-    then
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-      echo "COMPILE OR LINK ERROR"
-      rm -f *.o
-      exit 1
-    else
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-    fi
-
-  else
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    ln -s ${bindir}/$EXE .
-
-  fi
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-
-    ${pkgdatadir}/runcase_syrthes -compile \
-      -cs-bindir=${bindir} -src-syr=${SRC_SYR} \
-      -src-copy=${RESU}/SRC_SYR.${SUFFIX} -log=${RESU}/compil_syrthes.log.${SUFFIX}
-
-  fi
-
-fi # EXEC_KERNEL = yes
-
-#
-########################################################################
-#
-# Data setup
-#
-echo
-echo  "  ********************************************"
-echo  "             Preparing calculation            "
-echo  "  ********************************************"
-echo
-#
-ERROR=false
-PREPROCESS_ERROR=false
-PARTITION_ERROR=false
-EXECUTION_ERROR=false
-#
-if [ $SOLCOM = 1 ]
-then
-  EXEC_PREPROCESS=no
-  EXEC_PARTITION=no
-  ln -s $MESHDIR/$MESH geomet || exit 1
-fi
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ]
-then
-  for var in $MESH ; do
-    ln -s $MESHDIR/$var $var || exit 1
-    # Special case for meshes in EnSight format: link to .geo file necessary
-    # (retrieve name through .case file)
-    var2=`basename $var .case`
-    if [ $var2 != $var ] ; then
-      ficgeo_ensight=`awk '/^model:/ {print $2}' $var`
-      ln -s $MESHDIR/$ficgeo_ensight $ficgeo_ensight || FIN
-    fi
-  done
-else
-  if [ -f ${PREPROCESSOR_OUTPUT_IN} ] ; then
-    ln -s ${PREPROCESSOR_OUTPUT_IN} preprocessor_output || exit 1
-  else
-    echo "Error: no preprocessor output file is available;"
-    echo "       (${PREPROCESSOR_OUTPUT_IN} does not exist."
-    echo "       or is not a standard file."
-    exit 1
-  fi
-fi
-#
-if [ $nproc_kernel -eq 1 -a "${EXEC_KERNEL}" = "yes" ] ; then
-  EXEC_PARTITION=no
-elif [ "${EXEC_PARTITION}" = "no" -a "${PARTITION_OUTPUT_IN}" != "" ]
-then
-  if [ -f ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} ] ; then
-    ln -s ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} .
-  else
-    echo "Warning: no partitioning file is available;"
-    echo "         (no ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel})."
-    echo
-    echo "         Unoptimized partitioning will be used."
-    echo "         Parallel performance may be degraded."
-  fi
-fi
-#
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  for var in ${RESTART_IN}/* ; do
-    if [ -f $var ] ; then
-      varb=`basename $var`
-      if   [ $varb = suiava ] ; then
-        vara=suiamo
-      elif [ $varb = suiavx ] ; then
-        vara=suiamx
-      elif [ $varb = vorava ] ; then
-        vara=voramo
-      elif [ $varb = t1dava ] ; then
-        vara=t1damo
-      elif [ $varb = rayava ] ; then
-        vara=rayamo
-      elif [ $varb = lagava ] ; then
-        vara=lagamo
-      elif [ $varb = lasava ] ; then
-        vara=lasamo
-      else
-        vara=$varb
-      fi
-      ln -s $var $vara
-    fi
-  done
-  #
-  if [ "$THERMOCHEMISTRY_DATA" != "" ] ; then
-    var=$DATA/$THERMOCHEMISTRY_DATA
-    if [ -f $var ] ; then
-      cp $var dp_tch
-      # Copy so as to have correct name upon backup
-      if [ "$THERMOCHEMISTRY_DATA" != "dp_tch" ] ; then
-        cp dp_tch $THERMOCHEMISTRY_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The thermochemistry file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  if [ "$METEO_DATA" != "" ] ; then
-    var=$DATA/$METEO_DATA
-    if [ -f $var ] ; then
-      cp $var meteo
-      # Copy so as to have correct name upon backup
-      if [ "$METEO_DATA" != "meteo" ] ; then
-        cp meteo $METEO_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The meteo profile file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  for f in uscpcl.f90 usd3pc.f90 usebuc.f90 uslwcc.f90 usfucl.f90
-  do
-    if [ -f "${SRC}/${f}" -a ! -f JANAF ] ; then
-      cp ${datadir}/data/thch/JANAF JANAF
-    fi
-  done
-  #
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    #
-    ${pkgdatadir}/runcase_syrthes -copy-data -syrthes-env=${DATA_SYR}/$SYRTHES_ENV
-    #
-  fi
-  #
-  if [ ! -z "$USER_INPUT_FILES" ] ; then
-    for f in $USER_INPUT_FILES ; do
-      cp $DATA/$f .
-    done
-  fi
-  #
-fi # EXEC_KERNEL = yes
-
-########################################################################
-# Maximum time for PBS (done here so as to leave time for PBS to
-# realize that things have started).
-#
-if [ "$PBS_JOBID" != "" ] ; then
-  CS_MAXTIME=`qstat -r $PBS_JOBID | grep $PBS_JOBID | sed -e's/ \{1,\}/ /g' | cut -d ' ' -f 9`
-  export CS_MAXTIME
-fi
-#
-########################################################################
-#
-# Summary: start
-#
-CURDATE=`unset LANG ; date`
-#
-echo '========================================================'>>$summary
-echo '   Start time       : ' $CURDATE                         >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Kernel          : ' $prefix                          >>$summary
-echo '    Preprocessor    : ' $ecs_prefix                      >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    HOMARD          : ' $homard_prefix                   >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    CS_MPI_PATH     : ' $CS_MPI_PATH                     >>$summary
-echo '    PATH            : ' $PATH                            >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    User            : ' $USER                            >>$summary
-echo '========================================================'>>$summary
-echo '    Machine         : '                                  >>$summary
-     uname -a                                                  >>$summary
-if [ -z "$NUMBER_OF_PROCESSORS" ] ; then
-  echo '    N Procs         : ' 1                              >>$summary
-else
-  echo '    N Procs         : ' $NUMBER_OF_PROCESSORS          >>$summary
-fi
-if [ -z "$PROCESSOR_LIST" ] ; then
-  echo '    Processors      : ' default                        >>$summary
-else
-  echo '    Processors      : ' $PROCESSOR_LIST                >>$summary
-fi
-echo '========================================================'>>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Case            : ' $CASE                            >>$summary
-echo '      DATA          : ' $DATA                            >>$summary
-echo '      SRC           : ' $SRC                             >>$summary
-echo '      RESU          : ' $RESU                            >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Exec. dir.      : ' $RUN                             >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-if [ "$EXEC_PREPROCESSOR" = "yes" ] ; then
-  echo '    Preprocessor    : ' ${ecs_bindir}/cs_preprocess    >>$summary
-fi
-if [ "$EXEC_PARTITION" = "yes" ] ; then
-  echo '    Partitioner     : ' ${ecs_bindir}/cs_partition     >>$summary
-fi
-if [ "$EXEC_KERNEL" = "yes" ] ; then
-  echo '    Executable      : ' $EXE                           >>$summary
-fi
-echo '  ----------------------------------------------------'  >>$summary
-#
-# Execution
-echo
-echo  "  ********************************************"
-echo  "             Starting calculation"
-echo  "  ********************************************"
-echo
-#
-# Preprocessor start
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ] ; then
-  #
-  ${ecs_bindir}/cs_preprocess --mesh $MESH "--case" $CASE \
-                   $COMMAND_REORIENT $COMMAND_JOIN $COMMAND_PERIO \
-                   > listpre 2>&1
-  if [ $? != 0 ] ; then
-    echo "Error running the preprocessor."
-    echo "Check preprocessor log (listpre) for details."
-    echo
-    PREPROCESS_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PREPROCESSOR_OUTPUT_OUT=$RESU/preprocessor_output.$SUFFIX
-    cp preprocessor_output ${PREPROCESSOR_OUTPUT_OUT}
-  fi
-  #
-fi
-#
-# Partitioner start
-#
-if [ ! -f ${ecs_bindir}/cs_partition ] ; then
-  echo "Warning: ${ecs_bindir}/cs_partition not found."
-  echo
-  echo "The partitioner may not have been installed"
-  echo "  (this is the case if neither METIS nor."
-  echo "  SCOTCH are avaialable)."
-  echo
-  echo "Unoptimized partitioning will be used, so"
-  echo "parallel performance may be degraded."
-  echo
-  EXEC_PARTITION=no
-fi
-#
-if [ "${EXEC_PARTITION}" = "yes" ] ; then
-  #
-  if [ "${EXEC_KERNEL}" = "yes" ] ; then
-    ${ecs_bindir}/cs_partition $nproc_kernel > listpart 2>&1
-  else
-    if [ -z "$PARTITION_LIST" ] ; then
-      echo "Error running the partitioner."
-      echo "PARTITION_LIST is not set."
-      echo "This variable should contain the number of processors"
-      echo "for which we partition (or a list of such numbers)."
-      PARTITION_ERROR=true
-      ERROR=true
-    else
-      ${ecs_bindir}/cs_partition $PARTITION_LIST > listpart 2>&1
-    fi
-  fi
-  if [ $? != 0 -a $PARTITION_ERROR = false ] ; then
-    echo "Error running the partitioner."
-    echo "Check partitioner log (listpart) for details."
-    echo
-    PARTITION_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PARTITION_OUTPUT_OUT=$RESU/PARTITION_OUTPUT.$SUFFIX
-    mkdir $PARTITION_OUTPUT_OUT
-    cp -r domain_number_* ${PARTITION_OUTPUT_OUT}/
-  fi
-#
-fi
-#
-# Run calculation proper.
-#
-if [ "$ERROR" != "true" -a "$EXEC_KERNEL" = "yes" ] ; then
-#
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    # MPI Communication
-    #
-    # Make sure to transmit possible additional arguments assigned by mpirun to
-    # the executable with some MPI-1 implementations (vanilla MPICH 1.2 sets the
-    # parameters needed by MPI_Init through argc/argv): we use $@ to forward
-    # arguments passed to localexec to the true executable files.
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo "MPI_RANK=\`${pkgdatadir}/runcase_mpi_rank \$@\`" >> $localexec
-    echo cd $RUN >> $localexec
-    echo "if [ \$MPI_RANK -eq 0 ] ; then" >> $localexec
-    echo "  $RUN/$EXE_SYR \$@ -app-num 0 -comm-mpi 1 $ECHOCOMMSYR > listsyr 2>&1" >> $localexec
-    echo "else" >> $localexec
-    echo "  $VALGRIND $RUN/$EXE \$@ --mpi 1 $COMMAND_CWF "\
-         "$ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM " >> $localexec
-    echo "fi" >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    #
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  elif [ $SYRTHES_COUPLING = yes  ] ; then
-    # Socket communications
-    #
-    # We provide the executables with a "random" port number.
-    PORT=35623
-    SOCKETNCS="--syr-socket $PORT"
-    SOCKETSYR="-comm-socket $PORT"
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI $COMMAND_CWF "\
-                 " $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-                 " $COMMAND_PARAM $SOCKETNCS " >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true &
-    #
-    ./$EXE_SYR $ECHOCOMMSYR $SOCKETSYR > listsyr 2>&1
-    #
-    $MPIHALT
-    #
-  elif [ $SOLCOM = 0 ] ; then
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI "\
-         " $COMMAND_CWF $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-         " $COMMAND_PARAM "  >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  else # cas SOLCOM = 1
-    #
-    $VALGRIND $RUN/$EXE --solcom \
-          $ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM \
-          || EXECUTION_ERROR=true
-    #
-  fi
-#
-fi
-#
-# Remove the Salome temporary files
-rm -f $SCRIPTS/running*.$DATE
-#
-########################################################################
-#
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    echo "Error running the coupled calculation."
-    echo "Either the Kernel or SYRTHES may have failed."
-    echo
-    echo "Check Kernel log (listing) and SYRTHES log (listsyr) for details,"
-    echo "as well as eventual error* files."
-    echo
-  else
-    echo "Error running the calculation."
-    echo
-    echo "Check Kernel log (listing) and error* files for details"
-    echo
-  fi
-  ERROR=true
-fi
-#
-# Treatment of the ouput files:
-#   Starts with the restart files
-#   (in case of full disk, increases chances of being able to continue).
-#
-if [ $EXEC_KERNEL = yes ] ; then
-
-  RESTART_OUT=$RESU/RESTART.$SUFFIX
-  iok=1
-  mkdir ${RESTART_OUT} || iok=0
-  if [ $iok = 1 ] ; then
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f ${RESTART_OUT}
-      fi
-    done
-  else
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f $RESU/$f.$SUFFIX
-      fi
-    done
-  fi
-
-  resuser=0
-  for f in ${USER_OUTPUT_FILES} ; do
-    if [ -f $f ] ; then
-      resuser=1
-    fi
-  done
-  if [ ${resuser} = 1 ] ; then
-    RES_USER=$RESU/RES_USER.$SUFFIX
-    iok=1
-    mkdir ${RES_USER} || iok=0
-    if [ $iok = 1 ] ; then
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f ${RES_USER}
-        fi
-      done
-    else
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f $RESU/$f.$SUFFIX
-        fi
-      done
-    fi
-  fi
-
-  for f in $PARAM $THERMOCHEMISTRY_DATA $METEO_DATA ; do
-    if [ -f $f ] ; then
-      cp $f $RESU/$f.$SUFFIX
-    fi
-  done
-
-  for f in probes_*.dat ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-  for f in ush* ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-
-fi  # output files
-
-for f in list* error* *.med *.cgns ; do
-  if [ -f $f ] ; then
-    cp $f $RESU/$f.$SUFFIX
-  fi
-done
-
-# Treatment of EnSight and MED files
-#   The $dir (=*.ensight and/or *.med) directories are copied
-#   to $DIR.$SUFFIX
-
-#   We place directories $dir (=*.ensight and/or *.med)
-#   in $DIR.$SUFFIX
-
-cas=`echo $CASE |tr "[:upper:]" "[:lower:]"`
-
-for dir in *.ensight *.med ; do
-  if [ -d $dir ] ; then
-    DIR=`echo $dir |tr "[:lower:]" "[:upper:]"`
-    mkdir $RESU/$DIR.$SUFFIX
-    if [ $? -ne 0 ] ; then
-      echo Creating $RESU/$DIR.$SUFFIX failed
-    else
-      for f in $dir/*  ; do
-        if [ -f $f ] ; then
-          cp -R ${f} $RESU/$DIR.$SUFFIX/.
-        fi
-      done
-    fi
-  fi
-done
-
-if [ $EXEC_KERNEL = yes ] ; then
-
-  rayt_list=`ls bord* 2>/dev/null`
-  if [ ! -z "${rayt_list}" ] ; then
-    for f in $rayt_list ; do
-      if [ ! -d $RESU/CHR.$SUFFIX ] ; then
-        mkdir $RESU/CHR.$SUFFIX
-      fi
-      cp $f $RESU/CHR.$SUFFIX/.
-    done
-  fi
-
-  lagr_list=`ls debug* deplacement* trajectoire* frontiere* 2>/dev/null`
-  if [ ! -z "${lagr_list}" ] ; then
-    mkdir $RESU/LAGR.$SUFFIX
-    for f in $lagr_list ; do
-      cp $f $RESU/LAGR.$SUFFIX
-    done
-  fi
-
-  # Matisse output files
-  if [ -f ${RUN}/resuMatisse ] ; then
-    matisse=`grep -i matisse $DATA/$PARAM`
-    if [ ! -z "$matisse" ] ; then
-  # The date is added to the first line of resuMatisse
-      AFDATE="Date of the case                                       : "$DATE
-      sed  "1i\ ${AFDATE}" ${RUN}/resuMatisse >> ${RUN}/resuMatisse.mod
-      mv ${RUN}/resuMatisse.mod ${RUN}/resuMatisse
-    fi
-    cp ${RUN}/resuMatisse ${RESU}/resuMatisse.$SUFFIX
-  fi
-
-  for dir in src_saturne ; do
-    if [ -d $dir ] ; then
-      mkdir $RESU/SRC.$SUFFIX
-      if [ $? -ne 0 ] ; then
-        echo Failure creating $RESU/SRC.$SUFFIX
-      else
-        for f in $dir/*.[fF]90 $dir/*.[ch] ; do
-          if [ -f ${f} ] ; then
-            cp -R ${f} $RESU/SRC.$SUFFIX/.
-            fbase=`basename ${f}`
-            chmod a-w $RESU/SRC.$SUFFIX/${fbase}
-          fi
-        done
-      fi
-    fi
-  done
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    ${pkgdatadir}/runcase_syrthes -copy-results \
-      -result-dir=${RESU}/RESU_SYR.${SUFFIX}
-  fi
-
-fi  # input data and outputs
-#
-########################################################################
-#
-# Summary: end
-#
-if  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  EXEC_PREPROCESS="failed"
-fi
-echo "    Preprocessing   : " $EXEC_PREPROCESS                 >>$summary
-if  [ "$PARTITION_ERROR" = "true" ] ; then
-  EXEC_PARTITION="failed"
-fi
-echo "    Partitioning    : " $EXEC_PARTITION                  >>$summary
-if  [ "$EXECUTION_ERROR" = "true" ] ; then
-  EXEC_KERNEL="failed"
-fi
-echo "    Calculation     : " $EXEC_KERNEL                     >>$summary
-#
-CURDATE=`unset LANG ; date`
-#
-echo '  ----------------------------------------------------'  >>$summary
-echo '   Finish time      : ' $CURDATE                         >>$summary
-echo '========================================================'>>$summary
-#
-cp $summary  $RESU/$summary.$SUFFIX
-#
-########################################################################
-#
-#
-# Finish
-#
-echo
-echo  "  ********************************************"
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  echo  "         Error in calculation stage."
-elif  [ "$PARTITION_ERROR" = "true" ] ; then
-  echo  "         Error in partitioning stage."
-elif  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  echo  "         Error in preprocessing stage."
-else
-  echo  "           Normal simulation finish"
-fi
-echo  "  ********************************************"
-
-if [ "$ERROR" = "true" ] ; then
-  exit 1
-else
-  exit 0
-fi
-#
-########################################################################
diff --git a/examples/2-full_domain/case2/case2.xml b/examples/2-full_domain/case2/case2.xml
index ab97d24..6dbfe2a 100644
--- a/examples/2-full_domain/case2/case2.xml
+++ b/examples/2-full_domain/case2/case2.xml
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE2" study="FULL_DOMAIN" version="1.0">
+<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE2" study="FULL_DOMAIN" version="2.0">
 	<solution_domain>
 		<volumic_conditions>
 			<zone head_losses="off" initialization="on" label="all_cells" mass_source_term="off" momentum_source_term="off" name="1" scalar_source_term="off" thermal_source_term="off">all[]</zone>
@@ -17,17 +17,16 @@
 		</join_meshes>
 		<faces_cutting status="off"/>
 		<reorientation status="off"/>
-		<syrthes_coupling status="off"/>
 		<periodic_boundary/>
 		<standalone/>
 	</solution_domain>
 	<thermophysical_models>
 		<velocity_pressure>
-			<variable label="Pression" name="pressure">
+			<variable label="Pressure" name="pressure">
 				<reference_pressure>101325</reference_pressure>
 				<listing_printing status="off"/>
 			</variable>
-			<variable label="VitesseX" name="velocity_U">
+			<variable label="VelocityX" name="velocity_U">
 				<probes choice="5">
 					<probe_recording name="1"/>
 					<probe_recording name="2"/>
@@ -37,43 +36,49 @@
 				</probes>
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseY" name="velocity_V">
+			<variable label="VelocityY" name="velocity_V">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseZ" name="velocity_W">
+			<variable label="VelocityZ" name="velocity_W">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<property label="total_pressure" name="total_pressure"/>
+			<property label="total_pressure" name="total_pressure">
+				<probes choice="0"/>
+			</property>
 			<property label="Yplus" name="yplus" support="boundary"/>
 			<property label="Efforts" name="effort" support="boundary"/>
 			<property label="all_variables" name="all_variables" support="boundary"/>
 		</velocity_pressure>
 		<ale_method status="off"/>
 		<turbulence model="k-epsilon">
-			<variable label="EnerTurb" name="turb_k">
+			<variable label="TurbEnergy" name="turb_k">
 				<listing_printing status="off"/>
 			</variable>
 			<variable label="Dissip" name="turb_eps">
 				<listing_printing status="off"/>
 			</variable>
-			<property label="visc. tu" name="turb_viscosity"/>
+			<property label="TurbVisc" name="turb_viscosity"/>
 			<initialization choice="reference_velocity">
 				<reference_velocity>1</reference_velocity>
 			</initialization>
 		</turbulence>
 		<thermal_scalar model="temperature_celsius">
-			<property label="Flux_thermique_entrant" name="input_thermal_flux" support="boundary"/>
+			<property label="Input_thermal_flux" name="input_thermal_flux" support="boundary"/>
 		</thermal_scalar>
 		<radiative_transfer model="off">
 			<restart status="off"/>
 			<absorption_coefficient type="constant">0</absorption_coefficient>
 		</radiative_transfer>
+		<conjugate_heat_transfer>
+			<external_coupling status="off"/>
+			<external_coupling status="off"/>
+			<external_coupling status="on"/>
+		</conjugate_heat_transfer>
 		<gas_combustion model="off"/>
 		<pulverized_coal model="off"/>
 		<joule_effect model="off"/>
-		<atmospheric_flows model="off">
-			<read_meteo_data status="off"/>
-		</atmospheric_flows>
+		<atmospheric_flows model="off"/>
+		<heads_losses/>
 	</thermophysical_models>
 	<numerical_parameters>
 		<multigrid status="on"/>
@@ -85,22 +90,22 @@
 	</numerical_parameters>
 	<physical_properties>
 		<fluid_properties>
-			<property choice="constant" label="Masse vo" name="density">
+			<property choice="constant" label="Density" name="density">
+				<initial_value>725.735</initial_value>
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
-				<initial_value>725.735</initial_value>
 			</property>
-			<property choice="constant" label="Visc. la" name="molecular_viscosity">
+			<property choice="constant" label="Molecular_visc" name="molecular_viscosity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
-				<initial_value>8.95e-05</initial_value>
+				<initial_value>8.951e-05</initial_value>
 			</property>
-			<property choice="constant" label="Ch.spec." name="specific_heat">
+			<property choice="constant" label="Sp_heat" name="specific_heat">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>5483</initial_value>
 			</property>
-			<property choice="constant" label="Cond. th" name="thermal_conductivity">
+			<property choice="constant" label="Th_cond" name="thermal_conductivity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>0.02495</initial_value>
@@ -108,20 +113,20 @@
 		</fluid_properties>
 		<gravity>
 			<gravity_x>0</gravity_x>
-			<gravity_y>0</gravity_y>
+			<gravity_y>-9.81</gravity_y>
 			<gravity_z>0</gravity_z>
 		</gravity>
 		<hydrostatic_pressure status="off"/>
 	</physical_properties>
 	<additional_scalars>
-		<scalar label="Temp.C" name="temperature_celsius" type="thermal">
-			<initial_value zone="1">20.0</initial_value>
+		<scalar label="TempC" name="temperature_celsius" type="thermal">
+			<initial_value label="all_cells" zone="1">20.0</initial_value>
 			<min_value>0</min_value>
 			<max_value>400</max_value>
 			<blending_factor>1</blending_factor>
 		</scalar>
 		<scalar label="scalar_2" name="scalar2" type="user">
-			<initial_value zone="1">10.0</initial_value>
+			<initial_value label="all_cells" zone="1">10.0</initial_value>
 			<min_value>0</min_value>
 			<max_value>400</max_value>
 			<property choice="constant" label="Dscal1" name="diffusion_coefficient_2">
@@ -133,13 +138,6 @@
 	<boundary_conditions>
 		<boundary label="inlet" name="1" nature="inlet">1</boundary>
 		<boundary label="outlet" name="2" nature="outlet">34</boundary>
-		<boundary label="symmetry" name="3" nature="symmetry">8 or 9 or 28 or 29 or 38 or 39</boundary>
-		<boundary label="Wall_1" name="4" nature="wall">24 and 0.1<=X and 0.5>=X</boundary>
-		<boundary label="Wall_2" name="5" nature="wall">2 or 3</boundary>
-		<boundary label="Wall_3" name="6" nature="wall">4 or 7 or 21 or 22 or 23</boundary>
-		<boundary label="Wall_4" name="7" nature="wall">6 and Y>1</boundary>
-		<boundary label="Wall_5" name="8" nature="wall">6 and Y<=1</boundary>
-		<boundary label="Wall_6" name="9" nature="wall">31 or 33</boundary>
 		<inlet label="inlet">
 			<velocity_pressure choice="norm" direction="coordinates">
 				<norm>1</norm>
@@ -150,7 +148,7 @@
 			<turbulence choice="hydraulic_diameter">
 				<hydraulic_diameter>0.5</hydraulic_diameter>
 			</turbulence>
-			<scalar choice="dirichlet" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="dirichlet" label="TempC" name="temperature_celsius" type="thermal">
 				<dirichlet>300</dirichlet>
 			</scalar>
 			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
@@ -158,70 +156,81 @@
 			</scalar>
 		</inlet>
 		<outlet label="outlet">
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
 				<neumann>0</neumann>
 			</scalar>
 		</outlet>
+		<boundary label="symmetry" name="3" nature="symmetry">8 or 9 or 28 or 29 or 38 or 39</boundary>
 		<symmetry label="symmetry"/>
-		<wall label="Wall_1">
-			<velocity_pressure choice="off">
-				<dirichlet name="velocity_U">0</dirichlet>
-				<dirichlet name="velocity_V">0</dirichlet>
-				<dirichlet name="velocity_W">0</dirichlet>
-			</velocity_pressure>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+		<boundary label="wall_2" name="5" nature="wall">2 or 3</boundary>
+		<boundary label="wall_3" name="6" nature="wall">4 or 7 or 21 or 22 or 23</boundary>
+		<boundary label="wall_4" name="7" nature="wall">6 and Y>1</boundary>
+		<boundary label="wall_5" name="8" nature="wall">6 and Y<=1</boundary>
+		<boundary label="wall_6" name="9" nature="wall">31 or 33</boundary>
+		<wall label="wall_2">
+			<velocity_pressure choice="off"/>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>0</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>5</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_3">
+		<wall label="wall_4">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>0</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>25</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_2">
+		<wall label="wall_3">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>5</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>0</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_4">
+		<boundary label="wall_1" name="4" nature="wall">24 and 0.1<=X and 0.5>=X</boundary>
+		<wall label="wall_6">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>25</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>40</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_5">
-			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+		<wall label="wall_5">
+			<velocity_pressure choice="off">
+				<dirichlet name="velocity_U">0</dirichlet>
+				<dirichlet name="velocity_V">0</dirichlet>
+				<dirichlet name="velocity_W">0</dirichlet>
+			</velocity_pressure>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>320</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>320</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_6">
-			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+		<wall label="wall_1">
+			<velocity_pressure choice="off">
+				<dirichlet name="velocity_U">0</dirichlet>
+				<dirichlet name="velocity_V">0</dirichlet>
+				<dirichlet name="velocity_W">0</dirichlet>
+			</velocity_pressure>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>40</neumann>
+				<neumann>0</neumann>
 			</scalar>
 		</wall>
 		<variable/>
@@ -229,9 +238,10 @@
 	<analysis_control>
 		<output>
 			<postprocessing_mesh_options choice="0"/>
+			<syrthes_boundary status="off"/>
 			<postprocessing_format choice="EnSight"/>
 			<postprocessing_options choice="binary"/>
-			<domain_boundary status="on"/>
+			<domain_boundary status="off"/>
 			<listing_printing_frequency>1</listing_printing_frequency>
 			<postprocessing_frequency>2</postprocessing_frequency>
 			<probe_recording_frequency>1</probe_recording_frequency>
@@ -283,15 +293,15 @@
 			</probe>
 		</output>
 		<time_parameters>
-			<property label="Nb Courant" name="courant_number">
+			<time_step_ref>0.05</time_step_ref>
+			<iterations>300</iterations>
+			<time_passing>0</time_passing>
+			<property label="CFL_number" name="courant_number">
 				<postprocessing_recording status="off"/>
 			</property>
-			<property label="Nb Fourier" name="fourier_number">
+			<property label="Fourier_number" name="fourier_number">
 				<postprocessing_recording status="off"/>
 			</property>
-			<time_step_ref>0.05</time_step_ref>
-			<iterations>300</iterations>
-			<time_passing>0</time_passing>
 			<zero_time_step status="off"/>
 		</time_parameters>
 		<steady_management status="off"/>
@@ -299,6 +309,10 @@
 		<profiles/>
 	</analysis_control>
 	<calcul_management>
+		<start_restart>
+			<restart status="off"/>
+			<frozen_field status="off"/>
+		</start_restart>
 		<integer_user_array>
 			<ncelet>0</ncelet>
 			<nfac>0</nfac>
@@ -311,12 +325,18 @@
 			<nfabor>0</nfabor>
 			<dimless>0</dimless>
 		</real_user_array>
-		<start_restart>
-			<restart status="off"/>
-			<frozen_field status="off"/>
-			<restart_rescue>0</restart_rescue>
-			<restart_with_auxiliary status="on"/>
-		</start_restart>
+		<integer_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</integer_work_array>
+		<real_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</real_work_array>
 	</calcul_management>
 	<lagrangian model="off"/>
 </Code_Saturne_GUI>
diff --git a/examples/2-full_domain/case2/lance b/examples/2-full_domain/case2/lance
deleted file mode 100644
index ff4652f..0000000
--- a/examples/2-full_domain/case2/lance
+++ /dev/null
@@ -1,1612 +0,0 @@
-#!/bin/sh
-#============================================================================
-#
-#                    Code_Saturne version 1.3
-#                    ------------------------
-#
-#
-#     This file is part of the Code_Saturne Kernel, element of the
-#     Code_Saturne CFD tool.
-#
-#     Copyright (C) 1998-2008 EDF S.A., France
-#
-#     contact: saturne-support at edf.fr
-#
-#     The Code_Saturne Kernel is free software; you can redistribute it
-#     and/or modify it under the terms of the GNU General Public License
-#     as published by the Free Software Foundation; either version 2 of
-#     the License, or (at your option) any later version.
-#
-#     The Code_Saturne Kernel 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 General Public License for more details.
-#
-#     You should have received a copy of the GNU General Public License
-#     along with the Code_Saturne Kernel; if not, write to the
-#     Free Software Foundation, Inc.,
-#     51 Franklin St, Fifth Floor,
-#     Boston, MA  02110-1301  USA
-#
-#============================================================================
-#
-########################################################################
-#
-# Exemple de fichier de lancement Code_Saturne
-#
-########################################################################
-########################################################################
-#
-#                  CARTES BATCH POUR LE CCRT (Tantale/Platine sous LSF)
-#                  ====================================================
-#
-#BSUB -n 2
-#BSUB -W 00:05  
-#BSUB -o full_domaincaseo.%J 
-#BSUB -e full_domaincasee.%J 
-#BSUB -J full_domaincase
-#
-#  -n : nombre de processeurs
-#  -c : temps limite pour le job (cumul par processeur de tous les process du job)
-#       au format hh:mm (heures:minutes)
-#  -o : nom du listing de sortie
-#  -e : nom du listing d'erreur
-#  -J : nom du job
-#
-#ATTENTION : Les calculs lances sur Tantale sont executes sur Tantale, mais pour
-#            Nickel/Chrome, la machine d'execution (Nickel Ou Chrome) est definie
-#            par la classe du calcul et pas par la machine qui a execute la commande
-#            "bsub". Attention aux disques WORKDIR non partages entre Nickel et
-#            Chrome.
-#ATTENTION : En cas de couplage avec Syrthes, 1 processeur
-#            sera reserve pour chacune des instances de Syrthes.
-#            Le Noyau ne sera execute que sur les processeurs restants.
-#            Pensez  reserver un nombre suffisant de processeurs.
-#
-# ------------------------------------------------------------------
-#
-#                  CARTES BATCH POUR LE CLUSTER CHATOU sous PBS
-#                  ============================================
-#
-#PBS -l nodes=4:ppn=2,walltime=1:00:00,mem=320mb
-#PBS -j eo -N full_domaincase
-#
-#  nodes= nombre de "noeuds" a reserver sur le cluster
-#  ppn  = nombre de processeurs par noeud (1 ou 2)
-#  cput     = cpu time (heures, minutes, secondes)
-#  walltime = wall clock time (heures, minutes, secondes)
-#  mem  = memoire
-#
-#ATTENTION : En cas de couplage avec Syrthes, 1 processeur
-#            sera reserve pour chacune des instances de Syrthes.
-#            Le Noyau ne sera execute que sur les processeurs restants.
-#            Pensez  reserver un nombre suffisant de processeurs.
-#
-# ------------------------------------------------------------------
-#
-#                  CARTES BATCH POUR LE CLUSTER de University of Manchester
-#                  ========================================================
-#
-# set the name of the job
-##$ -N full_domaincase
-#
-# request between 2 and 4 slots
-##$ -pe mpich 2-4
-#
-# Execute the job from the current working directory
-# Job output will appear in this directory
-##$ -cwd
-#   can use -o dirname to redirect stdout
-#   can use -e dirname to redirect stderr
-
-#  Export these environment variables
-##$ -v MPI_HOME
-
-#set -x
-########################################################################
-#
-# Definition du cas 
-#        : rubrique utilisateur
-#
-# Se reporter au fichier joint "lance.help" pour toute information
-#   sur les rubriques a remplir et les valeurs possibles.
-#
-#
-#                    -------------------------------
-#
-#
-#
-#                 NE PAS LAISSER DE BLANCS (c'est un script)
-#
-#
-#                    -------------------------------
-#
-SOLCOM=0
-LONGIA=1000000
-LONGRA=5000000
-#
-# Sur certaines machines, dont Tantale, des librairies externes
-# peuvent necessiter la definition de la variable TERM
-export TERM=xterm
-#
-ETUDE=FULL_DOMAIN
-CAS=CASE2
-PARAM=case2.xml
-MAILLAGE="downcomer.des fdc.des pic.des"
-COMMANDE_RC="-j -color 5 24 32 -fraction 0.1 -plane 0.8"
-COMMANDE_DF=
-COMMANDE_PERIO=
-COMMANDE_SYRTHES=
-DONNEES_THERMOCHIMIE=
-#
-# Choix du nombre total de processeurs utilises (si vide, detection automatique
-# via le systeme de queue si possible, mise a 1 sinon).
-# En cas de couplage Syrthes avec MODE_COUPLAGE=MPI, le 1er processeur est
-# utilise pour Syrthes, donc le nombre effectif de processeurs dedies au noyau
-# est reduit de 1.
-# La liste des processeurs n'est utilisable qu'hors systeme de queue
-# (un tel systeme fournissant lui-meme une liste equivalente)
-NOMBRE_DE_PROCESSEURS=
-LISTE_PROCESSEURS=
-#
-FICHIERS_DONNEES_UTILISATEUR=
-FICHIERS_RESULTATS_UTILISATEUR=
-#
-# Repertoire temporaire local (vide pour valeur automatique par defaut)
-CS_TMP_PREFIX=/local00/users
-#CS_TMP_PREFIX=/local00/users/`whoami`
-#
-OPTIMISATION=
-LISTE_LIB_SAT=
-OPTION_LIB_EXT=
-VALGRIND=
-#
-ARG_CS_VERIF=
-ARG_CS_OUTPUT=
-ECHOCOMM=""
-#
-#Pilotage du couplage avec HOMARD
-PILOTAGE_ADAPTATION=
-#
-resume=resume
-REPBASE=/home/saturne/TEST_CASES/FULL_DOMAIN/CASE2
-DATA=$REPBASE/DATA
-RESU=$REPBASE/RESU
-FORT=$REPBASE/FORT
-SCRIPTS=$REPBASE/SCRIPTS
-SUITE_AMONT=$DATA/SUITE
-PRE_TRAITEMENT_AMONT=$DATA/PRE_TRAITEMENT
-REPMAIL=$REPBASE/../MAILLAGE
-#
-# Les variables suivantes ne sont utiles que dans les cas couples avec SYRTHES
-#  DATA_SYR : repertoire ou trouver SYRTHES_ENV
-#  FORT_SYR : repertoire ou trouver les fichiers utilisateur eventuels
-DATA_SYR=$REPBASE/DATA_SYR
-SYRTHES_ENV=syrthes.env 
-FORT_SYR=$REPBASE/FORT_SYR
-#
-# Le mode de couplage eventuel avec Syrthes peut etre choisi ici.
-# (attention aux majuscules/minuscules).
-# Si l'on n'a pas de couplage, cette variable sera mise a zero par la suite.
-#
-#  MODE_COUPLAGE=MPI     : recommande sur tout cluster (CCRT ou Chatou notamment).
-#  MODE_COUPLAGE=sockets : solution de secours sur cluster si l'on ne sait
-#                          determiner le rang MPI d'un process a priori
-#                          (i.e. si rang_mpi.sh ne peut etre adapte)
-#                          ou si l'on ne dispose pas de MPI.
-#  MODE_COUPLAGE=pipes   : sur station de travail ou autre machine a memoire
-#                          partagee uniquement (les pipes n'etant visibles
-#                          que localement, et ne "traversant" pas le reseau).
-MODE_COUPLAGE=MPI
-#
-# On peut utiliser 3 modes d'execution.
-# (attention aux minuscules/majuscules)
-#
-#  MODE_EXEC=complet        : choix par defaut (Preprocesseur puis calcul).
-#  MODE_EXEC=pre_traitement : lancement du Preprocesseur seul, pour generer
-#                             les fichiers preprocessor_output/*.
-#  MODE_EXEC=calcul         : lancement du calcul seul, en utilisant des
-#                             fichiers preprocessor_output/* deja generes et
-#                             accessibles dans le repertoire $PRE_TRAITEMENT_AMONT.
-#
-MODE_EXEC=complet
-#
-#
-#
-#
-########################################################################
-#
-# FIN DE ZONE UTILISATEUR POUR CALCULS STANDARDS
-# END OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-########################################################################
-#
-#  Adresse de la bibliotheque du noyau    
-CS_HOME=/home/saturne/Noyau/ncs-1.3.2
-export CS_HOME
-#
-# Parametres d'installation
-#
-. $CS_HOME/bin/cs_profile
-#
-#Verification de la compatibilite de la bibliotheque
-if [ ! -f ${CS_HOME}/bin/macros_${NOM_ARCH}.mk ]
-then
-  echo Architecture ${NOM_ARCH} non supportee par la version de Code_Saturne
-  echo ${CS_HOME}
-  exit 1
-fi
-#
-########################################################################
-#  Adaptation de maillage
-#
-if [ ! -z  "${PILOTAGE_ADAPTATION}" ] ; then
-  if [ "${PILOTAGE_ADAPTATION}" = "-aide" -o "${PILOTAGE_ADAPTATION}" = "-help" ] ; then
-    ${CSHOMARD_HOME}/saturne_homard ${PILOTAGE_ADAPTATION}
-    exit 0
-  else
-    Options_HOMARD="  -v"
-    ${CSHOMARD_HOME}/saturne_homard -Saturne_Script $0 -Donnees_Calcul $REPBASE \
-                    -Pilotage_Adaptation $PILOTAGE_ADAPTATION $Options_HOMARD || exit 1
-  fi
-fi
-#
-#########################################################################
-#  
-#
-N_COUPLAGE_SYRTHES=0
-N_COUPLAGE_SYRTHES=`echo $COMMANDE_SYRTHES | grep -c syrthes`
-if [ $N_COUPLAGE_SYRTHES = 0 ] ; then 
-  COUPLAGE_SYRTHES=non
-else
-  COUPLAGE_SYRTHES=oui
-  export SYRTHES
-  if [ $N_COUPLAGE_SYRTHES -gt 1 ] ; then
-   echo "Ce script ne prend pas en charge plusieurs couplage Syrthes"
-   echo "Nombre de couplages Syrthes demande : $N_COUPLAGE_SYRTHES"
-  fi
-fi
-#
-if [ $COUPLAGE_SYRTHES = oui ] ; then 
-  if [ $SOLCOM -eq 1 ] ; then
-   echo "Le couplage avec Syrthes n est pas compatible avec les"
-   echo "maillages de type SOLCOM"
-   exit 1
-  fi
-else
-  MODE_COUPLAGE=
-fi
-#
-########################################################################
-#
-# Definition des parametres d'execution
-#
-#   Variables generales
-THISSCRIPT=$0
-USER=`whoami`
-DATE=`date '+%m%d%H%M'`
-SUFFIXE=$DATE
-EXE=cs13.exe
-EXE_SYR=syrthes
-#
-# on recopie le script de lancement avant de se positionner dans le
-# repertoire de travail (car ensuite, un chemin relatif ne sera
-# plus a jour)
-
-cp $0 $RESU/lance.$SUFFIXE
-#
-#   Repertoire d'execution (accessible depuis tous les procs)
-#
-if [ ! -z "$CS_TMP_PREFIX" ] ; then
-  RUN=${CS_TMP_PREFIX}/tmp_Saturne/$ETUDE.$CAS.$DATE
-#
-else
-#  Valeur par defaut si l'utilisateur n'a rien specifie
-#
-#  A priori sur Nickel/Chrome, c'est mieux avec TMPDIR, sauf si on veut
-#    debuguer (car $TMPDIR est detruit a la fin du job)
-  if [ "$NOM_ARCH" = "OSF1" ] ; then
-    RUN=$TMPDIR
-#   RUN=/scratch/scratchdir/$USER/TMPDIR/$ETUDE.$CAS.$DATE
-#
-#  Sur Tantale, il n'y a pas de TMPDIR. On se met par defaut dans SCRATCHDIR
-  elif [ "$NOM_ARCH" = "Linux_CCRT" ] ; then
-    RUN=$SCRATCHDIR/tmp_Saturne/$ETUDE.$CAS.$DATE
-#
-#  Sur Argent, il n'y a pas de TMPDIR. On se met par defaut dans SCRATCHDIR
-  elif [ "$NOM_ARCH" = "Linux_IA64" ] ; then
-    RUN=$SCRATCHDIR/tmp_Saturne/$ETUDE.$CAS.$DATE
-#
-#  Sur l'ancien cluster MFEE, il y a un TMPDIR, mais il correspond
-#  a un repertoire local, non partage par les noeuds. On ne peut
-#  donc pas l'utiliser
-  elif [ "$NOM_ARCH" = "Linux_SCALI" ] ; then
-    RUN=$HOME/tmp_Saturne/$ETUDE.$CAS.$DATE
-#
-#  Sur station classique ou cluster generique, on
-#  n'utilisera TMPDIR que s'il est defini
-#  (via un systeme batch en general)
-  elif [ "$TMPDIR" != "" -a "$TMPDIR" != "/tmp" ] ; then
-    RUN=$TMPDIR
-  else
-    RUN=$HOME/tmp_Saturne/$ETUDE.$CAS.$DATE
-  fi
-fi
-#
-# Creation automatique du repertoire si necessaire
-if [ "$RUN" != "$TMPDIR" ] ; then
-  if [ ! -d $RUN ] ; then
-    mkdir -p $RUN || exit 1
-  else
-    echo "Le repertoire RUN=$RUN existe deja."
-    echo "Le calcul ne peut pas etre execute."
-    exit 1
-  fi
-fi
-#
-cd $RUN
-#
-########################################################################
-#
-# Parallelisme
-#
-# Liste des processeurs
-#
-if [ -f "$TMPDIR/machines" ] ; then   # avec systeme de queue Manchester
-   MPIHOSTS="$TMPDIR/machines"
-elif [ ! -z "$PBS_NODEFILE" ] ; then    # avec system de queue PBS
-   MPIHOSTS="$PBS_NODEFILE"
-elif [ ! -z "$LSB_HOSTS" ] ; then       # avec systeme de queue LSF
-   \rm -f $RUN/hostsfile
-   echo $LSB_HOSTS | awk '{ for (ii = 1; ii < NF+1; ++ii) print $ii }' >> $RUN/hostsfile
-   MPIHOSTS="$RUN/hostsfile"
-elif [ ! -z "$LISTE_PROCESSEURS" ] ; then
-   \rm -f $RUN/hostsfile
-   localproc=`hostname`
-   echo $LISTE_PROCESSEURS | grep -q $localproc || LISTE_PROCESSEURS="$localproc & $LISTE_PROCESSEURS"
-   echo $LISTE_PROCESSEURS | awk  -F\& '{ for (ii = 1; ii < NF+1; ++ii) print $ii }' >> $RUN/hostsfile
-   MPIHOSTS="$RUN/hostsfile"
-fi
-# Verification du nombre de processeurs
-if [ -z  "${NOMBRE_DE_PROCESSEURS}" ] ; then
-  if [ ! -z  "${NSLOTS}" ] ; then
-    # pour systeme de queue cluster Manchester
-    NOMBRE_DE_PROCESSEURS=$NSLOTS
-  elif [ ! -z "${SLURM_NPROCS}" ] ; then
-    # pour systeme de queue LSF avec Slurm
-    NOMBRE_DE_PROCESSEURS=$SLURM_NPROCS
-  elif [ ! -z "${LSB_HOSTS}" ] ; then
-    # pour systeme de queue LSF sans Slurm
-    NOMBRE_DE_PROCESSEURS=`echo $LSB_HOSTS | wc -w`
-  elif [ ! -z  "${MPIHOSTS}" ] ; then
-    # pour systeme de queue cluster MFEE ou des que MPIHOSTS est defini
-    NOMBRE_DE_PROCESSEURS=`cat $MPIHOSTS | wc -l`
-  else
-    NOMBRE_DE_PROCESSEURS=1
-  fi
-fi
-#
-# Verification du nombre de noeuds si possible
-NOMBRE_DE_NOEUDS=1
-if [ -z  "${NOMBRE_DE_PROCESSEURS}" ] ; then
-  if [ ! -z  "${MPIHOSTS}" ] ; then
-    NOMBRE_DE_NOEUDS=`sort $MPIHOSTS | sed -e 's/:/ /' | cut -f 1 -d" " | uniq | wc -l`
-  fi
-fi
-#
-# Verification du nombre de processeurs demandes
-nproc_noy=${NOMBRE_DE_PROCESSEURS}
-echo
-echo
-if [ $COUPLAGE_SYRTHES = oui ] ; then
-  echo "Couplage de Code_Saturne avec Syrthes active"
-  if [ ! -z "$MPIHOSTS" ] ; then
-  #  si on utilise Syrthes en batch par MPI, on lui reserve un processeur par instance
-    if [ "$MODE_COUPLAGE" = "MPI" ] ; then
-      (( nproc_noy = nproc_noy - N_COUPLAGE_SYRTHES ))
-      if [ $nproc_noy -lt 1 ] ; then 
-        echo
-        echo
-        echo " Attention, avec MODE_COUPLAGE = MPI, Syrthes reserve un processeur."
-        echo "   Le nombre de processeurs demande ($NOMBRE_DE_PROCESSEURS)"
-        echo "   est donc insuffisant."
-        echo " Augmenter le nombre de processeurs reserves dans les cartes batch."
-        echo
-        exit 1
-      fi
-    fi
-  #  si on utilise Syrthes en batch pipe, on verifie que tout tient sur un seul noeud
-    if [ "$MODE_COUPLAGE" = "pipes" -a "$NOMBRE_DE_NOEUDS" != 1 ] ; then
-      echo
-      echo
-      echo " Attention, avec MODE_COUPLAGE = pipes, les transmissions  "
-      echo "   Syrthes-noyau se font par tubes (pipes). "
-      echo " Ici, plusieurs machines ont ete selectionnees pour "
-      echo "   realiser le calcul en parallele : "
-      cat "$MPIHOSTS"
-      echo " Les tubes (pipes) sont limites a un noeud et le calcul "
-      echo "   risque de ne pas pouvoir aboutir."
-      echo " Utiliser une autre valeur de MODE_COUPLAGE "
-      echo
-      exit 1
-    fi
-  else
-  #  si on n'est pas en batch et qu'on couple par MPI, on doit specifier un nombre
-  #    de processeurs superieur a 1 pour activer MPI
-    if [ "$MODE_COUPLAGE" = "MPI" ] ; then
-      (( nproc_noy = nproc_noy - N_COUPLAGE_SYRTHES ))
-      if [ $nproc_noy -lt 1 ] ; then 
-        echo
-        echo
-        echo " Attention, avec MODE_COUPLAGE = MPI, Syrthes reserve un processeur"
-        echo "   (eventuellement virtuel)."
-        echo "   Le nombre de processeurs demande ($NOMBRE_DE_PROCESSEURS)"
-        echo "   doit donc etre strictement superieur a 1."
-        echo " Augmenter NOMBRE_DE_PROCESSEURS."
-        echo
-        exit 1
-      fi
-    fi
-  #  si on n'est pas en batch et qu'on couple par pipes, on diminue aussi
-  #  NOMBRE_DE_PROCESSEURS pour ne pas avoir besoin de MPI si
-  #  Code_Saturne et Syrthes tournent chacun sur 1 processeur
-    if [ "$MODE_COUPLAGE" = "pipes" ] ; then
-      (( nproc_noy = nproc_noy - N_COUPLAGE_SYRTHES ))
-      (( NOMBRE_DE_PROCESSEURS = NOMBRE_DE_PROCESSEURS - 1 ))
-      if [ $nproc_noy -lt 1 ] ; then 
-        echo
-        echo
-        echo " Attention, avec MODE_COUPLAGE = pipes, Syrthes reserve un processeur"
-        echo "   (eventuellement virtuel)."
-        echo "   Le nombre de processeurs demande ($NOMBRE_DE_PROCESSEURS)"
-        echo "   doit donc etre strictement superieur a 1."
-        echo " Augmenter NOMBRE_DE_PROCESSEURS."
-        echo
-        exit 1
-      fi
-    fi
-  fi
-fi
-if [ $nproc_noy -gt 1 ] ; then
-  echo "Calcul Code_Saturne parallele avec decomposition en $nproc_noy sous-domaines"
-  if [ $SOLCOM = 1 ] ; then 
-    echo
-    echo
-    echo " Calcul en parallele impossible avec SOLCOM = $SOLCOM "
-    echo " Utiliser SOLCOM = 0 "
-    echo
-    exit 1
-  fi
-else
-  echo "Calcul Code_Saturne monoprocesseur"
-fi
-if [ ! -z "$MPIHOSTS" ] ; then
-  echo "$NOMBRE_DE_PROCESSEURS processeur(s) reserve(s) en tout"
-fi
-#
-# Si le noyau fonctionne en parallele, on doit lui preciser le nombre
-# de domaines, ainsi qu'au Preprocesseur
-if [ $nproc_noy -gt 1 ] ; then 
-  ARG_ECS_PAR=" -p $nproc_noy"
-  ARG_CS_PAR=" -p $nproc_noy"
-else
-  ARG_ECS_PAR=""
-  ARG_CS_PAR=""
-fi
-#
-# Parametres lies au systeme
-#
-if [ $NOMBRE_DE_PROCESSEURS -gt 1 ] ; then 
-#
-# Valeurs par defaut definies au depart
-  MPIBOOT=""
-  MPIHALT=""
-  MPIRUN="mpirun -np ${NOMBRE_DE_PROCESSEURS}"
-  if [ -d "$CS_MPI_PATH" ] ; then
-    export PATH=${CS_MPI_PATH}:$PATH
-  fi
-#
-  if [ "$NOM_ARCH" = "OSF1" ] ; then 
-    MPIRUN="prun -n ${NOMBRE_DE_PROCESSEURS} -stv"
-#
-  elif [ "$NOM_ARCH" = "Linux_CCRT" ] ; then
-    MPIRUN="mpirun -srun"
-#
-  elif [ "$NOM_ARCH" = "Linux_IA64" ] ; then
-    MPIRUN="srun -n ${NOMBRE_DE_PROCESSEURS}"
-#
-  elif [ "$NOM_ARCH" = "Linux_Ch" ] ; then 
-    MPIRUN="mpirun -np ${NOMBRE_DE_PROCESSEURS} -machinefile $PBS_NODEFILE"
-#
-  else 
-    if [ -d "$CS_MPI_PATH" ] ; then 
-      if [ -f "${CS_MPI_PATH}/mpdboot" ] ; then          # Si MPI de type MPICH2
-        MPIBOOT="${CS_MPI_PATH}/mpdboot"
-        MPIHALT="${CS_MPI_PATH}/mpdallexit"
-        MPIRUN="${CS_MPI_PATH}/mpiexec -n ${NOMBRE_DE_PROCESSEURS}" 
-        if [ ! -z "$MPIHOSTS" ] ; then
-          MPIBOOT="$MPIBOOT -n ${NOMBRE_DE_NOEUDS} -v -f $MPIHOSTS"
-	fi
-      elif [ -f "${CS_MPI_PATH}/ompi_info" ] ; then      # Si MPI de type Open MPI
-        MPIRUN="${CS_MPI_PATH}/mpiexec -n ${NOMBRE_DE_PROCESSEURS}" 
-        if [ ! -z "$MPIHOSTS" ] ; then
-          MPIRUN="$MPIRUN -machinefile $MPIHOSTS"
-        fi
-      elif [ -f "${CS_MPI_PATH}/lamboot" ] ; then        # Si MPI de type LAM MPI
-        MPIBOOT="${CS_MPI_PATH}/lamboot"
-        MPIHALT="${CS_MPI_PATH}/lamhalt"
-        MPIRUN="${CS_MPI_PATH}/mpirun -np ${NOMBRE_DE_PROCESSEURS}" 
-        if [ ! -z "$MPIHOSTS" ] ; then
-          MPIBOOT="$MPIBOOT -v $MPIHOSTS"
-          MPIHALT="$MPIHALT -v $MPIHOSTS"
-        fi
-      elif [ -f "${CS_MPI_PATH}/mpichversion" ] ; then   # Si MPI de type MPICH
-        MPIRUN="${CS_MPI_PATH}/mpirun -np ${NOMBRE_DE_PROCESSEURS}" 
-        if [ ! -z "$TMPDIR/machines" ] ; then   # avec systeme de queue Manchester
-          MPIRUN="$MPIRUN -machinefile $TMPDIR/machines"
-        elif [ ! -z "$MPIHOSTS" ] ; then
-          MPIRUN="$MPIRUN -machinefile $MPIHOSTS"
-        fi
-      fi
-    fi
-  fi
-#
-#   si on ne demande pas plusieurs processeurs
-#
-else
-#
-  MPIRUN=""
-  MPIBOOT=""
-  MPIHALT=""
-fi
-#
-########################################################################
-#
-# Communications
-#
-# Definition des sockets
-if [ $COUPLAGE_SYRTHES = oui -a "$MODE_COUPLAGE" = "sockets" ] ; then
-  SOCKETSYR="-comm-socket"
-else
-  SOCKETSYR=""
-fi
-# En prevision des echo comm si probleme
-if [ ! -z "$ECHOCOMM" ] ; then 
-  ECHOCOMMNB="$ECHOCOMM"
-  ECHOCOMMECS="-echo-comm $ECHOCOMMNB"
-  ECHOCOMMSYR="-echo-comm $ECHOCOMMNB"
-  ECHOCOMMNOY="--echo-comm $ECHOCOMMNB"
-else
-  ECHOCOMMNB=""
-  ECHOCOMMECS=""
-  ECHOCOMMSYR=""
-  ECHOCOMMNOY=""
-fi
-########################################################################
-# Message d'accueil 
-#
-echo ' '
-echo '                       Execution de Code_Saturne '
-echo '                       ************************* '
-echo ' '
-echo ' Repertoire de travail (penser a le purger periodiquement) : ' 
-echo '    ' $RUN
-#
-########################################################################
-
-# Fonction de reperage d'un sous programme utilisateur
-#  pour le moment, on fait simple 
-#   (on pourrait verifier que uslag2 contient bien uslag2 ou encore 
-#   qu'il n'est pas bidon ...) 
-presence () {
-
-  presence_sspgm=$1
-
-  if [ ! -f "${presence_sspgm}" ] ; then
-    presence_PRESENT="non"
-  else
-    presence_PRESENT="oui"
-  fi
-  echo ${presence_PRESENT} 
-}
-#
-########################################################################
-#
-# Compilation et edition des liens
-#
-# Remarque : on en profite pour reperer la presence de certains 
-#            sous-programmes utilisateurs.
-#
-if [ "$CS_HOME" = "" ]; then
-   echo
-   echo "WARNING: la variable CS_HOME n est pas positionnee"
-   echo
-   exit 1
-else
-  echo
-  echo ' Version noyau :          ' $CS_HOME
-  echo ' Version preprocesseur :  ' $ECS_HOME
-fi
-
-source_cas=$FORT
-
-if [ -f compil.log ] ; then
-  rm -f compil.log
-fi
-
-if [ $MODE_EXEC != pre_traitement ] ; then
-
-  echo
-  echo  "  *****************************************************************************"
-  echo  "   Compilation des sous-programmes utilisateur et edition de liens Code_Saturne"
-  echo  "  *****************************************************************************"
-
-  cur_dir=`pwd`
-
-  #
-  # Recopie du fichier parametrique
-  if [ ! -z "$PARAM" ] ; then 
-    var=$DATA/$PARAM
-    if [ -f $var ] ; then 
-      COMMANDE_PARAM="-param $PARAM"
-      cp $var .
-    else
-      echo ' ' 
-      echo ' -- ERREUR -- ' 
-      echo ' Le fichier de donnees parametrique ' $var
-      echo '   n est pas accessible ' 
-      exit 1
-    fi
-  fi
-
-  # Determination de la version des compilateurs 
-  ${CS_HOME}/bin/compiler_version -cshome ${CS_HOME} -nomarch ${NOM_ARCH} -output ${cur_dir}/compil.log
-
-  # Recopie des sources utilisateur 
-  #  (pas de liens : on recopie le repertoire ensuite)
-  mkdir fort_saturne
-  cd fort_saturne
-  for fich in ${source_cas}/*.[F,c,h] ; do 
-    if [ -f $fich ] ; then
-      cp ${fich} .
-    fi
-  done
-#
-# Detection de la presence de modules
-
-# Standard
-  USCLIM_PRESENT=`presence "usclim.F"`
-
-# Lagrangien
-  USLAG2_PRESENT=`presence "uslag2.F"`
-
-# Rayonnement
-  USRAY2_PRESENT=`presence "usray2.F"`
-  if [ ! -z "$PARAM" ] ; then 
-    NRAYT=`grep "radiative_transfer\ model" ${cur_dir}/$PARAM | grep -v "off" |wc -l`
-    if [ $NRAYT -eq 1 ] ; then
-      USRAY2_PRESENT="oui"
-    fi
-  fi
-
-# Charbon pulverise
-  USCPCL_PRESENT=`presence "uscpcl.F"`
-  if [ ! -z "$PARAM" ] ; then 
-    NCHARB=`grep "pulverized_coal\ model" ${cur_dir}/$PARAM | grep -v "off" |wc -l`
-    if [ $NCHARB -eq 1 ] ; then
-      USCPCL_PRESENT="oui"
-    fi
-  fi
-
-# Combustion gaz chimie 3 points
-  USD3PC_PRESENT=`presence "usd3pc.F"`
-
-# Combustion gaz EBU
-  USEBUC_PRESENT=`presence "usebuc.F"`
-
-# Combustion gaz LWC
-  USLWCC_PRESENT=`presence "uslwcc.F"`
-
-# Electrique
-  USELCL_PRESENT=`presence "uselcl.F"`
-
-# Compressible
-  USCFCL_PRESENT=`presence "uscfcl.F"`
-
-# Fuel
-  USFUCL_PRESENT=`presence "usfucl.F"`
-
-# Tests de compatibilite
-  if [ "${USCPCL_PRESENT}" = "oui" ] ; then
-    if [ "${USCLIM_PRESENT}" = "oui" ] ; then
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Lorsque le modele de combustion du charbon pulverise'
-      echo '  est active, usclim ne doit pas etre utilise'
-      echo '  Les conditions aux limites sont fournies dans'
-      echo '  l interface graphique ou dans uscpcl.'
-      echo ' '
-	exit 1
-    fi
-  fi
-  if [ "${USD3PC_PRESENT}" = "oui" ] ; then
-    if [ "${USCLIM_PRESENT}" = "oui" ] ; then
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Lorsque usd3pc est complete, usclim ne doit pas l etre'
-      echo '  (modele combustion chimie trois points)              '
-      echo '  Les conditions aux limites sont fournies dans usd3pc.'
-      echo ' '
-	exit 1
-    fi
-  fi
-  if [ "${USEBUC_PRESENT}" = "oui" ] ; then
-    if [ "${USCLIM_PRESENT}" = "oui" ] ; then
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Lorsque usebuc est complete, usclim ne doit pas l etre'
-      echo '  (modele combustion EBU)                              '
-      echo '  Les conditions aux limites sont fournies dans usebuc.'
-      echo ' '
-	exit 1
-    fi
-  fi
-  if [ "${USLWCC_PRESENT}" = "oui" ] ; then
-    if [ "${USCLIM_PRESENT}" = "oui" ] ; then
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Lorsque uslwcc est complete, usclim ne doit pas l etre'
-      echo '  (modele combustion LWC)                              '
-      echo '  Les conditions aux limites sont fournies dans uslwcc.'
-      echo ' '
-	exit 1
-    fi
-  fi
-  if [ "${USELCL_PRESENT}" = "oui" ] ; then
-    if [ "${USCLIM_PRESENT}" = "oui" ] ; then
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Lorsque uselcl est complete, usclim ne doit pas l etre'
-      echo '  (modele electrique)                                  '
-      echo '  Les conditions aux limites sont fournies dans uselcl.'
-      echo ' '
-	exit 1
-    fi
-  fi
-
-  if [ "${USCFCL_PRESENT}" = "oui" ] ; then
-    if [ "${USCLIM_PRESENT}" = "oui" ] ; then
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Lorsque uscfcl est complete, usclim ne doit pas l etre'
-      echo '  (modele compressible)                                  '
-      echo '  Les conditions aux limites sont fournies dans uscfcl.'
-      echo ' '
-	exit 1
-    fi
-  fi
-
-  if [ "${USFUCL_PRESENT}" = "oui" ] ; then
-    if [ "${USCLIM_PRESENT}" = "oui" ] ; then
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Lorsque usfucl est complete, usclim ne doit pas l etre'
-      echo '  (modele fuel)                              '
-      echo '  Les conditions aux limites sont fournies dans usfucl.'
-      echo ' '
-	exit 1
-    fi
-  fi
-
-# Traduction 
-  if [ "${USLAG2_PRESENT}" = "oui" ] ; then
-    LAGRANGIEN=oui
-    echo ' '
-    echo ' Utilisation du module lagrangien '  
-    echo ' '
-  else
-    LAGRANGIEN=non
-  fi
-  if [ "${USRAY2_PRESENT}" = "oui" ] ; then
-    RAYONNEMENT=oui
-    echo ' '
-    echo ' Utilisation du module rayonnement '  
-    echo ' '
-  else
-    RAYONNEMENT=non
-  fi
-  COMBUSTION=non
-  if [ "${USCPCL_PRESENT}" = "oui" ] ; then
-    COMBUSTION=oui
-    COMBUSTION_CPP=oui
-    echo ' '
-    echo ' Utilisation du module combustion charbon pulverise '  
-    echo ' '
-  else
-    COMBUSTION_CPP=non
-  fi
-  if [ "${USD3PC_PRESENT}" = "oui" ] ; then
-    COMBUSTION=oui
-    COMBUSTION_C3P=oui
-    echo ' '
-    echo ' Utilisation du module combustion chimie trois points '  
-    echo ' '
-  else
-    COMBUSTION_C3P=non
-  fi
-  if [ "${USEBUC_PRESENT}" = "oui" ] ; then
-    COMBUSTION=oui
-    COMBUSTION_EBU=oui
-    echo ' '
-    echo ' Utilisation du module combustion EBU '  
-    echo ' '
-  else
-    COMBUSTION_EBU=non
-  fi
-  if [ "${USLWCC_PRESENT}" = "oui" ] ; then
-    COMBUSTION=oui
-    COMBUSTION_LWC=oui
-    echo ' '
-    echo ' Utilisation du module combustion LWC '  
-    echo ' '
-  else
-    COMBUSTION_LWC=non
-  fi
-  if [ "${USELCL_PRESENT}" = "oui" ] ; then
-    ELECTRIQUE=oui
-    echo ' '
-    echo ' Utilisation du module electrique '  
-    echo ' '
-  else
-    ELECTRIQUE=non
-  fi
-
-  if [ "${USCFCL_PRESENT}" = "oui" ] ; then
-    COMPRESSIBLE=oui
-    echo ' '
-    echo ' Utilisation du module compressible '  
-    echo ' '
-  else
-    COMPRESSIBLE=non
-  fi
-
-  if [ "${USFUCL_PRESENT}" = "oui" ] ; then
-    FUEL=oui
-    echo ' '
-    echo ' Utilisation du module fuel '
-    echo ' '
-  else
-    FUEL=non
-  fi
-
-
-# Pas de lagrangien en parallele
-  if [ "${LAGRANGIEN}" = "oui" ] ; then 
-    if [ ${nproc_noy} -gt 1 ] ; then 
-      echo ' '
-      echo ' -- ERREUR -- '
-      echo ' Le mode parallele est incompatible avec le module Lagrangien'
-      echo '  dans la version courante.                          '
-      echo ' '
-	exit 1
-    fi
-  fi
-#
-  # Extraction du main sur HP (link avec f90) sauf s'il existe deja
-  # (devrait etre migre vers le Makefile si possible)
-  if [ "${NOM_ARCH}" = "HP-UX" ] ; then 
-    cheminlib=${CS_HOME}/lib/${NOM_ARCH}
-    main=cs_main
-    mainc=cs_main.c
-    maino=cs_main.o
-    if [ ! -f "$mainc" ] ; then 
-      libsaturneBASE=libsaturneBASE
-      if [ ! -z  "${LISTE_LIB_SAT}" ] ; then 
-        for module in ${LISTE_LIB_SAT} ; do 
-          if [ `echo ${module} | grep ${libsaturneBASE}` ] ; then 
-            ar -xv $cheminlib/${libsaturneBASE}${OPTIMISATION} $maino
-          fi
-        done 
-      else
-        ar -xv $cheminlib/${libsaturneBASE}${OPTIMISATION}.a  $maino
-      fi 
-    fi 
-  fi
-
-# Compilation
-  ln -s ${CS_HOME}/bin/Makefile .
-
-  make saturne OPT="${OPTIMISATION}" LIB="${LISTE_LIB_SAT}" OPTLIBS="${OPTION_LIB_EXT}"  2>>$cur_dir/compil.log 1>&2
-  if [ $? -ne 0 ]
-  then
-    cp $cur_dir/compil.log $RESU/compil.log.$SUFFIXE
-    echo ERREUR DE COMPILATION OU D\'EDITION DE LIENS
-    rm -f *.o
-    exit 1
-  else
-    cp $cur_dir/compil.log $RESU/compil.log.$SUFFIXE
-  fi
-
-# Nettoyage
-  make clean
-  mv $EXE ${cur_dir}/
-  cd ${cur_dir}
-
-  if [ $COUPLAGE_SYRTHES = oui ] ; then 
-
-    echo
-    echo  "  *****************************************************************************"
-    echo  "    Compilation des sous-programmes utilisateur et edition de liens SYRTHES    "
-    echo  "  *****************************************************************************"
-
-    cur_dir=`pwd`
-    mkdir fort_syrthes 
-    cd fort_syrthes
-    for fich in $FORT_SYR/*.[F,c,h] ; do 
-      cp ${fich} .
-    done
-    ln -s $SYRCS_HOME/bin/Makefile .
-    make syrthes NOM_ARCH=${NOM_ARCH} 2>>$cur_dir/compil.log 1>&2
-    if [ $? -ne 0 ]
-    then
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIXE
-      echo ERREUR DE COMPILATION OU D\'EDITION DE LIENS
-      rm -f *.o
-      exit 1
-    else
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIXE
-    fi
-    make clean
-    mv syrthes $cur_dir/
-    cd $cur_dir
-
-  fi
-
-fi # MODE_EXEC != pre_traitement
-
-#
-########################################################################
-#
-# Mise en place des donnees
-#
-echo
-echo  "  ********************************************"
-echo  "             Preparation du calcul            "
-echo  "  ********************************************"
-echo 
-if [ $SOLCOM = 1 ]
-then
-  ln -s $REPMAIL/$MAILLAGE geomet || exit 1
-elif [ $MODE_EXEC != calcul ]
-then
-  for var in $MAILLAGE ; do
-    ln -s $REPMAIL/$var $var || exit 1
-#   cas particulier des maillages au format EnSight : lien sur le fichier .geo 
-#   necessaire (recuperation du nom de fichier dans le fichier .case)
-    var2=`basename $var .case`
-    if [ $var2 != $var ] ; then
-      ficgeo_ensight=`awk '/^model:/ {print $2}' $var`
-      ln -s $REPMAIL/$ficgeo_ensight $ficgeo_ensight || FIN
-    fi
-  done
-elif [ $MODE_EXEC = calcul ]
-then
-    ln -s ${PRE_TRAITEMENT_AMONT} preprocessor_output || exit 1
-fi
-#
-if [ $MODE_EXEC != pre_traitement ] ; then
-
-  for var in ${SUITE_AMONT}/* ; do 
-    if [ -f $var ] ; then 
-      varb=`basename $var`
-      if   [ $varb = suiava ] ; then 
-        vara=suiamo
-      elif [ $varb = suiavx ] ; then 
-        vara=suiamx
-      elif [ $varb = vorava ] ; then 
-        vara=voramo
-      elif [ $varb = t1dava ] ; then 
-        vara=t1damo
-      elif [ $varb = rayava ] ; then 
-        vara=rayamo
-      elif [ $varb = lagava ] ; then 
-        vara=lagamo
-      elif [ $varb = lasava ] ; then 
-        vara=lasamo
-      else
-        vara=$varb
-      fi
-      ln -s $var $vara
-    fi
-  done
-  #
-  if [ "${COMBUSTION}" = "oui" -o "${ELECTRIQUE}" = "oui" -o "${FUEL}" = "oui"  ] ; then 
-    var=$DATA/$DONNEES_THERMOCHIMIE
-    if [ -f $var ] ; then 
-      cp $var dp_tch
-  # recopie pour avoir le bon nom a la sauvegarde
-      if [ "$DONNEES_THERMOCHIMIE" != "dp_tch" ] ; then 
-        cp dp_tch $DONNEES_THERMOCHIMIE
-      fi
-    else
-      echo ' ' 
-      echo ' -- ERREUR -- ' 
-      echo ' Le fichier de donnees thermochimie ' $var
-      echo '   n est pas accessible ' 
-      exit 1
-    fi    
-    if [ "${COMBUSTION}" = "oui" -o "${FUEL}" = "oui" ] ; then 
-      cp $CS_HOME/data/thch/JANAF JANAF
-    fi
-  fi
-  #
-  if [ $COUPLAGE_SYRTHES = oui ] ; then 
-    #
-    cp $DATA_SYR/$SYRTHES_ENV  .
-    #
-    # On extrait les informations de syrthes.env et on le modifie en csq 
-    #   (tous les fichiers seront locaux)
-    # On sauve le fichier auparavant pour pouvoir le recopier avec
-    #   les resultats ensuite
-    #
-    cp $SYRTHES_ENV  $SYRTHES_ENV.save
-    #
-    AMONT_SYR=`grep "AMONT :" $SYRTHES_ENV | awk -F: '{print $NF}' | sed -e "s/ //g"` 
-    AVAL_SYR=` grep "AVAL :"  $SYRTHES_ENV | awk -F: '{print $NF}' | sed -e "s/ //g"`
-    SUITE_SYR=`grep "SUITE :" $SYRTHES_ENV | awk -F: '{print $NF}' | sed -e "s/ //g"`
-    SYRTHES_DATA=`grep "DONNEES DU CALCUL :" $SYRTHES_ENV | awk -F: '{print $NF}'`
-    SYRTHES_GEOM=`grep "GEOMETRIE SOLIDE :" $SYRTHES_ENV | awk -F: '{print $NF}'`
-    SYRTHES_SUIT=`grep "SUITE SOLIDE RESU :" $SYRTHES_ENV | awk -F: '{print $NF}'`
-    SYRTHES_DATA_RAY=`grep "DONNEES POUR LE RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`
-    SYRTHES_MAIL_RAY=`grep "MAILLAGE RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`
-    SYRTHES_CORR=`grep "STOCKAGE DES CORRESPONDANTS :" $SYRTHES_ENV | awk -F: '{print $NF}'`
-    SYRTHES_FFOR_RAY=`grep "FACTEURS DE FORME RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`
-    SYRTHES_CORR_RAY=`grep "STOCKAGE DES CORRESPONDANTS RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_RES1=`grep "RESU SYRTHES 1 :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_RES2=`grep "RESU SYRTHES 2 :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_CHR2=`grep "CHRONO SYRTHES 2 :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_HIST=`grep "HISTORIQUE SOLIDE RESULTAT :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_MAIL_PEAU_FLUIDE=`grep "MAILLAGE PEAU FLUIDE :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_RESU_PEAU_FLUIDE=`grep "RESULTATS PEAU FLUIDE :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_CHR_PEAU_FLUIDE=`grep "CHRONO PEAU FLUIDE :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_MAIL_RAY=`grep "MAILLAGE DE RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_RESU_RAY=`grep "RESULTATS DE RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_CHR_RAY=`grep "CHRONO DE RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    SYRTHES_AVAL_HIST_RAY=`grep "HISTORIQUE RAYONNEMENT :" $SYRTHES_ENV | awk -F: '{print $NF}'`   
-    sed -e "s/:.*\//: /"              $SYRTHES_ENV > $SYRTHES_ENV.mod ; mv -f $SYRTHES_ENV.mod $SYRTHES_ENV
-    sed -e "s/AMONT :.*/AMONT : .\//" $SYRTHES_ENV > $SYRTHES_ENV.mod ; mv -f $SYRTHES_ENV.mod $SYRTHES_ENV
-    sed -e "s/AVAL :.*/AVAL : .\//"   $SYRTHES_ENV > $SYRTHES_ENV.mod ; mv -f $SYRTHES_ENV.mod $SYRTHES_ENV
-    sed -e "s/SUITE :.*/SUITE : .\//" $SYRTHES_ENV > $SYRTHES_ENV.mod ; mv -f $SYRTHES_ENV.mod $SYRTHES_ENV
-    #
-    # si vide, on prend les noms par defaut pour les resultats  : 
-    if [ -z "$SYRTHES_CORR" ] ; then 
-      SYRTHES_CORR="corresp"
-    fi
-    if [ -z "$SYRTHES_CORR_RAY" ] ; then 
-      SYRTHES_CORR_RAY="corresp_ray"
-    fi 
-    if [ -z "$SYRTHES_FFOR_RAY" ] ; then 
-      SYRTHES_FFOR_RAY="fdf_ray"
-    fi 
-    if [ -z "$SYRTHES_AVAL_RES1" ] ; then 
-      SYRTHES_AVAL_RES1="geoms"
-    fi 
-    if [ -z "$SYRTHES_AVAL_RES2" ] ; then 
-      SYRTHES_AVAL_RES2="resus"
-    fi 
-    if [ -z "$SYRTHES_AVAL_CHR2" ] ; then 
-      SYRTHES_AVAL_CHR2="chronos"
-    fi  
-    if [ -z "$SYRTHES_AVAL_HIST" ] ; then 
-      SYRTHES_AVAL_HIST="histos"
-    fi 
-    if [ -z "$SYRTHES_AVAL_MAIL_PEAU_FLUIDE" ] ; then 
-      SYRTHES_AVAL_MAIL_PEAU_FLUIDE="geomf_ef"
-    fi 
-    if [ -z "$SYRTHES_AVAL_RESU_PEAU_FLUIDE" ] ; then 
-      SYRTHES_AVAL_RESU_PEAU_FLUIDE="resuf_ef"
-    fi 
-    if [ -z "$SYRTHES_AVAL_CHR_PEAU_FLUIDE" ] ; then 
-      SYRTHES_AVAL_CHR_PEAU_FLUIDE="chronof_ef"
-    fi 
-    if [ -z "$SYRTHES_AVAL_MAIL_RAY" ] ; then 
-      SYRTHES_AVAL_MAIL_RAY="resu_ray.geom"
-    fi 
-    if [ -z "$SYRTHES_AVAL_RESU_RAY" ] ; then 
-      SYRTHES_AVAL_RESU_RAY="resu_ray"
-    fi 
-    if [ -z "$SYRTHES_AVAL_CHR_RAY" ] ; then 
-      SYRTHES_AVAL_CHR_RAY="chrono_ray"
-    fi 
-    if [ -z "$SYRTHES_AVAL_HIST_RAY" ] ; then 
-      SYRTHES_AVAL_HIST_RAY="histor"
-    fi 
-    #
-    #
-    # On transfere les fichiers syrthes
-    #
-    for var in $SYRTHES_DATA $SYRTHES_GEOM $SYRTHES_SUIT $SYRTHES_DATA_RAY $SYRTHES_MAIL_RAY ; do 
-      cp $AMONT_SYR/$var $RUN/`echo $var | sed -e "s/.*\///"`
-    done
-    for var in $SYRTHES_CORR $SYRTHES_FFOR_RAY $SYRTHES_CORR_RAY ; do 
-      cp $SUITE_SYR/$var $RUN/`echo $var | sed -e "s/.*\///"`
-    done
-    #
-  fi
-  #
-  if [ ! -z "$FICHIERS_DONNEES_UTILISATEUR" ] ; then 
-    for fich in $FICHIERS_DONNEES_UTILISATEUR ; do 
-      cp $DATA/$fich .
-    done
-  fi
-  #
-fi # MODE_EXEC != pre_traitement
-
-########################################################################
-# Temps limite pour PBS (on le fait ici pour laisser le temps a PBS
-#   de se rendre compte que ca a demarre)
-#
-if [ "$PBS_JOBID" != "" ] ; then 
-  CS_MAXTIME=`qstat -r $PBS_JOBID | grep $PBS_JOBID | sed -e's/ \{1,\}/ /g' | cut -d ' ' -f 9`
-  export CS_MAXTIME   
-fi
-#
-########################################################################
-#
-# Resume : debut
-#
-echo '========================================================'>>$resume
-echo '    DATE DE DEBUT   : ' $DATE                            >>$resume
-echo '  ----------------------------------------------------'  >>$resume
-echo '    CS_HOME         : ' $CS_HOME                         >>$resume
-echo '    ECS_HOME        : ' $ECS_HOME                        >>$resume
-echo '    ------------------------------------------------  '  >>$resume
-cat  $CS_HOME/bin/cs_profile                                   >>$resume
-echo '  ----------------------------------------------------'  >>$resume
-echo '    UTILISATEUR     : ' $USER                            >>$resume
-echo '    ARCHITECTURE    : ' $NOM_ARCH                        >>$resume
-echo '========================================================'>>$resume
-echo '    MACHINE         : '                                  >>$resume
-     uname -a                                                  >>$resume
-if [ -z "$NOMBRE_DE_PROCESSEURS" ] ; then 
-  echo '    N PROCS         : ' 1                              >>$resume
-else
-  echo '    N PROCS         : ' $NOMBRE_DE_PROCESSEURS         >>$resume
-fi
-if [ -z "$LISTE_PROCESSEURS" ] ; then 
-  echo '    PROCESSEURS     : ' par defaut                     >>$resume
-else
-  echo '    PROCESSEURS     : ' $NOMBRE_DE_PROCESSEURS         >>$resume
-fi
-echo '========================================================'>>$resume
-echo '  ----------------------------------------------------'  >>$resume
-echo '    CAS             : ' $CAS                             >>$resume
-echo '      CONFIG.       : ' $CONF                            >>$resume
-echo '        DATA        : ' $DATA                            >>$resume
-echo '        FORT        : ' $FORT                            >>$resume
-echo '        RESU        : ' $RESU                            >>$resume
-echo '  ----------------------------------------------------'  >>$resume
-echo '    REP. RUN        : ' $RUN                             >>$resume
-echo '  ----------------------------------------------------'  >>$resume
-echo '    EXECUTABLE      : ' $EXE                             >>$resume
-echo '      BIB           : ' $BIB                             >>$resume
-echo '      COMPILATEUR f : ' $COMPF                           >>$resume
-echo '      COMPILATEUR c : ' $COMPC                           >>$resume
-echo '      OPTIONS     f : ' $OPTCOMPF1                       >>$resume
-echo '  ----------------------------------------------------'  >>$resume
-#
-# Execution 
-echo
-echo  "  ********************************************"
-echo  "                    Execution                 "
-echo  "  ********************************************"
-echo 
-#
-ERROR=$RUN/error
-erreur()
-{
-echo ERREUR $1 >> $ERROR
-}
-#
-# Preparation supplementaire pour le couplage Syrthes
-#
-if [ $COUPLAGE_SYRTHES = oui ] ; then
-  #
-  if [ "$MODE_COUPLAGE" = "pipes" ] ; then
-    #
-    # Creation des pipes si besoin
-    #
-    if [ $nproc_noy -gt 1 ] ; then 
-      num=1
-      while [ $num -le $nproc_noy ] ; do 
-        numf=`echo $num | awk '{printf "%4.4i\n", $1}'`
-        for fich in solveur_n${numf}_vers_syrthes.0001 syrthes_vers_solveur_n$numf.0001 ; do
-          if [ -f $fich ] ; then
-            rm -f $fich
-          fi
-          mkfifo $fich
-        done
-        (( num = num + 1 ))
-      done
-    else
-      for fich in solveur_vers_syrthes.0001 syrthes_vers_solveur.0001 ; do
-        if [ -f $fich ] ; then 
-          rm -f $fich
-        fi
-        mkfifo $fich
-      done
-    fi
-    #
-  # Si sockets, on doit adapter la COMMANDE_SYRTHES 
-  #   (on ajoute -socket apres -syrthes)
-  #
-  elif [ "$MODE_COUPLAGE" = "sockets" ] ; then
-    cmdsyr=""
-    if [ ! -z "$COMMANDE_SYRTHES" ] ; then 
-      for var in $COMMANDE_SYRTHES ; do 
-        if [ "$var" = "-syrthes" ] ; then 
-          cmdsyr="$cmdsyr $var -socket"
-        else 
-          cmdsyr="$cmdsyr $var" 
-        fi 
-      done
-      COMMANDE_SYRTHES="$cmdsyr"
-    fi
-  fi
-  #
-fi
-#
-# Lancement du Preprocesseur
-#
-if [ $SOLCOM = 0 -a $MODE_EXEC != calcul ] ; then
-  #
-  ${ECS_HOME}/bin/ecs $ARG_ECS_PAR -mesh $MAILLAGE -case $CAS \
-                      $ECHOCOMMECS \
-                      $COMMANDE_RC $COMMANDE_PERIO > listenv 2>&1 \
-                   || erreur " A L'EXECUTION DU PREPROCESSEUR"
-  #
-  if [ $MODE_EXEC = pre_traitement ] ; then
-    #
-    PRE_TRAITEMENT_AVAL=$RESU/PRE_TRAITEMENT.$SUFFIXE
-    if [ -d ${PRE_TRAITEMENT_AVAL} ] ; then
-      echo "Le repertoire ${PRE_TRAITEMENT_AVAL} existe deja."
-      echo "Copie des fichiers preprocessor_output/n* impossible"
-    else
-      cp -r preprocessor_output ${PRE_TRAITEMENT_AVAL}
-    fi
-  fi
-#
-fi
-#
-# Lancement du calcul proprement dit
-#
-if [ ! -f $ERROR -a $MODE_EXEC != pre_traitement ] ; then
-#
-  if [ $COUPLAGE_SYRTHES = oui -a "$MODE_COUPLAGE" = "MPI" ] ; then
-    # Communication par MPI
-    #
-    # Attention a bien transmettre les eventuels arguments supplementaires
-    # fournis par mpirun a l'executable (pour le cas de MPICH 1.2 standard, qui
-    # fournit les parametres de MPI_Init via argc/argv) : on utilise donc $@
-    # pour transmettre les arguments fournis a localexec aux exectables appeles
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo "MPI_RANK=\`$CS_HOME/bin/rang_mpi.sh \$@\`" >> $localexec
-    echo cd $RUN >> $localexec 
-    echo "if [ \$MPI_RANK -eq 0 ] ; then" >> $localexec
-    echo "  $RUN/$EXE_SYR \$@ -comm-mpi 1 -nbr_sat $nproc_noy $ECHOCOMMSYR > listsyr 2>&1" >> $localexec
-    echo "else" >> $localexec
-    echo "  $VALGRIND $RUN/$EXE \$@ $ARG_CS_PAR $COMMANDE_SYRTHES -proc 0 $COMMANDE_DF "\
-         "$ARG_CS_VERIF $ARG_CS_OUTPUT $ECHOCOMMNOY -iasize $LONGIA -rasize $LONGRA "\
-         "$COMMANDE_PARAM " >> $localexec 
-    echo "fi" >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    #
-    $MPIBOOT
-    $MPIRUN $localexec || erreur " A L'EXECUTION DU NOYAU "
-    $MPIHALT
-    #
-  elif [ $COUPLAGE_SYRTHES = oui  ] ; then
-    # Communication par pipes ou sockets
-    #
-    # Lancement de saturne
-    # Attention a bien transmettre les eventuels arguments supplementaires
-    # fournis par mpirun a l'executable (pour le cas de MPICH 1.2 standard, qui
-    # fournit les parametres de MPI_Init via argc/argv) : on utilise donc $@
-    # pour transmettre les arguments fournis a localexec
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec 
-    echo cd $RUN >> $localexec 
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_PAR $COMMANDE_SYRTHES $COMMANDE_DF "\
-                 " $ARG_CS_VERIF $ARG_CS_OUTPUT $ECHOCOMMNOY -iasize $LONGIA "\
-                 " -rasize $LONGRA $COMMANDE_PARAM " >> $localexec 
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || erreur " A L'EXECUTION DU NOYAU " &
-    #
-    if [ "$MODE_COUPLAGE" = "sockets" ] ; then
-      # Il faut recuperer la machine et le port dans le listing ;
-      #   on utilise un sleep pour laisser le temps au noyau de demarrer et
-      #   ecrire ces informations; on evite le while qui pourrait attendre eternellement
-      sleep 5
-      MACHPORT=""
-      MACHPORT=`grep 'Communication possible sur' listing|sed -e "s/Communication possible sur //g"|sed -e "s/, port /:/g"`
-      SOCKETSYR="$SOCKETSYR $MACHPORT"
-    fi
-    #
-    # Lancement de syrthes
-    if [ $COUPLAGE_SYRTHES = oui ] ; then
-      ./$EXE_SYR -nbr_sat $nproc_noy $ECHOCOMMSYR $SOCKETSYR > listsyr 2>&1 
-    fi
-    #
-    $MPIHALT
-    #
-  elif [ $SOLCOM = 0 ] ; then
-    #
-    if [ ! -f $ERROR ] ; then 
-      localexec=$RUN/localexec
-      echo '#!/bin/sh' > $localexec 
-      echo cd $RUN >> $localexec 
-      echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_PAR "\
-           " $COMMANDE_DF $ARG_CS_VERIF $ARG_CS_OUTPUT $ECHOCOMMNOY "\
-	   "-iasize $LONGIA  -rasize $LONGRA $COMMANDE_PARAM "  >> $localexec 
-      echo "retour=\$?" >> $localexec
-      echo "exit \$retour" >> $localexec
-      chmod 700 $localexec
-      $MPIBOOT
-      $MPIRUN $localexec || erreur " A L'EXECUTION DU NOYAU "
-      $MPIHALT
-    fi
-    #
-  else # cas SOLCOM = 1
-    #
-    $VALGRIND $RUN/$EXE -solcom \
-          -iasize $LONGIA -rasize $LONGRA $ARG_CS_VERIF $ARG_CS_OUTPUT $COMMANDE_PARAM \
-          || erreur " A L'EXECUTION DU NOYAU "
-    #
-  fi
-#
-fi
-#
-########################################################################
-#
-# Recuperation des resultats :
-#   on commence par tous les fichiers suite
-#   (en cas de pb disque, on a plus de chances de pouvoir 
-#    poursuivre le calcul). 
-#
-if [ $MODE_EXEC != pre_traitement ] ; then
- 
-  SUITE_AVAL=$RESU/SUITE.$SUFFIXE
-  iok=1
-  mkdir ${SUITE_AVAL} || iok=0
-  if [ $iok = 1 ] ; then 
-    for fich in suiava suiavx t1dava vorava rayava lagava* lasava* ; do 
-      if [ -f $fich ] ; then 
-        cp $fich ${SUITE_AVAL}
-      fi
-    done
-  else
-    for fich in suiava suiavx t1dava vorava rayava lagava* lasava* ; do 
-      if [ -f $fich ] ; then 
-        cp $fich $RESU/$fich.$SUFFIXE
-      fi
-    done
-  fi
-
-  resuser=0
-  for fich in ${FICHIERS_RESULTATS_UTILISATEUR} ; do 
-    if [ -f $fich ] ; then 
-      resuser=1
-    fi
-  done
-  if [ ${resuser} = 1 ] ; then 
-    RES_USER=$RESU/RES_USER.$SUFFIXE
-    iok=1
-    mkdir ${RES_USER} || iok=0
-    if [ $iok = 1 ] ; then 
-      for fich in ${FICHIERS_RESULTATS_UTILISATEUR} ; do 
-        if [ -f $fich ] ; then 
-          cp $fich ${RES_USER}
-        fi
-      done
-    else
-      for fich in ${FICHIERS_RESULTATS_UTILISATEUR} ; do 
-        if [ -f $fich ] ; then 
-          cp $fich $RESU/$fich.$SUFFIXE
-        fi
-      done
-    fi
-  fi
-
-  for fich in $PARAM $DONNEES_THERMOCHIMIE rubmail dessin ; do 
-    if [ -f $fich ] ; then 
-      cp $fich $RESU/$fich.$SUFFIXE
-    fi
-  done
-
-  for fich in *.hst ; do
-    if [ -f $fich ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIXE ] ; then 
-        mkdir $RESU/HIST.$SUFFIXE
-      fi
-      cp $fich $RESU/HIST.$SUFFIXE
-    fi
-  done
-  for fich in ush* ; do
-    if [ -f $fich ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIXE ] ; then 
-        mkdir $RESU/HIST.$SUFFIXE
-      fi
-      cp $fich $RESU/HIST.$SUFFIXE
-    fi
-  done
-
-fi  # resultats de calcul
-
-for fich in list* erreur* *.med *.cgns ; do 
-  if [ -f $fich ] ; then 
-    cp $fich $RESU/$fich.$SUFFIXE
-  fi
-done
-
-# Recup des cas EnSight et MED
-#   les fichiers bord* sont des sorties rayonnement eventuelles 
-#   faites dans le noyau en reponse a un besoin urgent 
-#   elles seront revues. 
-
-#   On range les repertoires $dir (=*.ensight et/ou *.med)
-#   dans $DIR.$SUFFIXE
-
-cas=`echo $CAS |tr "[:upper:]" "[:lower:]"`
-
-for dir in *.ensight *.med ; do
-  if [ -d $dir ] ; then
-    DIR=`echo $dir |tr "[:lower:]" "[:upper:]"`
-    mkdir $RESU/$DIR.$SUFFIXE 
-    if [ $? -ne 0 ] ; then
-      echo Echec a la creation de $RESU/$DIR.$SUFFIXE
-    else
-      for fich in $dir/*  ; do 
-        if [ -f $fich ] ; then    
-          cp -R ${fich} $RESU/$DIR.$SUFFIXE/.
-        fi
-      done
-    fi
-  fi
-done
-
-if [ $MODE_EXEC != pre_traitement ] ; then
- 
-  if [ "${RAYONNEMENT}" = "oui" ] ; then 
-    for fich in bord* ; do
-      if [ -f $fich ] ; then  
-        if [ ! -d $RESU/CHR.$SUFFIXE ] ; then 
-          mkdir $RESU/CHR.$SUFFIXE 
-        fi
-        cp $fich $RESU/CHR.$SUFFIXE/.
-      fi
-    done
-  fi
-
-
-  if [ "${LAGRANGIEN}" = "oui" ] ; then 
-    mkdir $RESU/LAGR.$SUFFIXE
-    for fich in debug* deplacement* trajectoire* frontiere* ; do 
-      if [ -f $fich ] ; then 
-        cp $fich $RESU/LAGR.$SUFFIXE
-      fi
-    done
-  fi
-
-  # Fichier de resultats Matisse
-  if [ -f ${RUN}/resuMatisse ] ; then
-    matisse=`grep -i matisse $DATA/$PARAM`
-    if [ ! -z "$matisse" ] ; then
-  # Ajout de la date sur la premiere ligne du fichier resuMatisse
-      AFDATE="Date du cas                                             : "$DATE
-      sed  "1i\ ${AFDATE}" ${RUN}/resuMatisse >> ${RUN}/resuMatisse.mod
-      mv ${RUN}/resuMatisse.mod ${RUN}/resuMatisse  
-    fi
-    cp ${RUN}/resuMatisse ${RESU}/resuMatisse.$SUFFIXE
-  fi
-
-  for dir in fort_saturne ; do
-    if [ -d $dir ] ; then
-      mkdir $RESU/FORT.$SUFFIXE
-      if [ $? -ne 0 ] ; then
-        echo Echec a la creation de $RESU/FORT.$SUFFIXE
-      else
-        for fich in $dir/*.[f,F,c,h] ; do
-          if [ -f ${fich} ] ; then 
-            cp -R ${fich} $RESU/FORT.$SUFFIXE/. 
-            fichbase=`basename ${fich}`
-            chmod a-w $RESU/FORT.$SUFFIXE/${fichbase}
-          fi
-        done
-      fi
-    fi
-  done 
-
-  if [ $COUPLAGE_SYRTHES = oui ] ; then 
-    mkdir $RESU/RESU_SYR.$SUFFIXE 
-    if [ $? -ne 0 ] ; then
-      echo Echec a la creation de $RESU/RESU_SYR.$SUFFIXE
-    else
-      for var in   $SYRTHES_ENV.save $SYRTHES_DATA $SYRTHES_DATA_RAY \
-                   $SYRTHES_CORR $SYRTHES_CORR_RAY $SYRTHES_FFOR_RAY \
-                   $SYRTHES_AVAL_RES1 $SYRTHES_AVAL_RES2 $SYRTHES_AVAL_CHR2 \
-                   $SYRTHES_AVAL_HIST \
-                   $SYRTHES_AVAL_MAIL_PEAU_FLUIDE $SYRTHES_AVAL_RESU_PEAU_FLUIDE \
-                   $SYRTHES_AVAL_CHR_PEAU_FLUIDE \
-                   $SYRTHES_AVAL_MAIL_RAY $SYRTHES_AVAL_RESU_RAY \
-                   $SYRTHES_AVAL_CHR_RAY \
-                   $SYRTHES_AVAL_HIST_RAY   ; do
-          fich=$RUN/`echo $var | sed -e "s/.*\///"`
-          if [ -f $fich ] ; then 	
-            cp $fich $RESU/RESU_SYR.$SUFFIXE/.
-          fi
-      done
-    fi
-    #
-    for dir in fort_syrthes ; do
-      if [ -d $dir ] ; then
-        mkdir $RESU/FORT_SYR.$SUFFIXE
-        if [ $? -ne 0 ] ; then
-          echo Echec a la creation de $RESU/FORT_SYR.$SUFFIXE
-        else
-          for fich in $dir/*.[f,F,c,h] ; do
-            if [ -f ${fich} ] ; then 
-              cp -R ${fich} $RESU/FORT_SYR.$SUFFIXE/.
-              fichbase=`basename ${fich}`
-              chmod a-w $RESU/FORT_SYR.$SUFFIXE/${fichbase}
-            fi
-          done
-        fi
-      fi
-    done 
-  fi
-
-fi  # donnees d'entree et resultats de calcul
-#
-########################################################################
-#
-# Resume : fin
-#
-DATEFIN=`date '+%m%d%H%M'`
-echo '    DATE DE FIN     : ' $DATEFIN                         >>$resume
-echo '========================================================'>>$resume
-#
-cp $resume  $RESU/$resume.$SUFFIXE
-#
-########################################################################
-#
-#
-# Fin
-#
-if [ -f $ERROR ] ; then 
-#
-  echo
-  echo  "  ********************************************"
-  cat                        $ERROR
-  echo  "  ********************************************"
-  exit 1
-#
-else
-#
-  echo
-  echo  "  ********************************************"
-  echo  "             Fin normale du calcul            "
-  echo  "  ********************************************"
-  exit 0
-#
-fi
-#
-########################################################################
-#
-########################################################################
diff --git a/examples/2-full_domain/case2/runcase b/examples/2-full_domain/case2/runcase
deleted file mode 100755
index 6b17f75..0000000
--- a/examples/2-full_domain/case2/runcase
+++ /dev/null
@@ -1,1125 +0,0 @@
-#!/bin/sh
-# bin/runcase.  Generated from runcase.in by configure.
-#============================================================================
-#
-#     This file is part of the Code_Saturne Kernel, element of the
-#     Code_Saturne CFD tool.
-#
-#     Copyright (C) 1998-2009 EDF S.A., France
-#
-#     contact: saturne-support at edf.fr
-#
-#     The Code_Saturne Kernel is free software; you can redistribute it
-#     and/or modify it under the terms of the GNU General Public License
-#     as published by the Free Software Foundation; either version 2 of
-#     the License, or (at your option) any later version.
-#
-#     The Code_Saturne Kernel 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 General Public License for more details.
-#
-#     You should have received a copy of the GNU General Public License
-#     along with the Code_Saturne Kernel; if not, write to the
-#     Free Software Foundation, Inc.,
-#     51 Franklin St, Fifth Floor,
-#     Boston, MA  02110-1301  USA
-#
-#============================================================================
-#
-########################################################################
-#
-#                  BATCH FILE FOR THE CCRT (Platine under LSF)
-#                  ===========================================
-#
-#BSUB -n 2
-#BSUB -W 00:30
-#BSUB -o full_domaincaseo.%J 
-#BSUB -e full_domaincasee.%J 
-#BSUB -J full_domaincase
-#
-#  -n : number of processors
-#  -W : walltime as hh:mm
-#  -o : output file name
-#  -e : error file name
-#  -J : job name
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE FOR THE Chatou CLUSTER (PBS)
-#                  =======================================
-#
-#PBS -l nodes=4:ppn=2
-#PBS -l walltime=1:00:00
-#PBS -l mem=320mb
-#
-#PBS -j eo
-#PBS -N full_domaincase2
-#
-#  nodes    : number of nodes
-#  ppn      : number of process per node
-#  walltime : wall clock time (hh:mm:ss)
-#  mem      : memory
-#
-#WARNING: when coupling with SYRTHES, 1 processor will be reserved for each
-#         instance of SYRTHES. The Kernel will be executed on the remaining
-#         processors, so make sure to reserve a sufficiently high number
-#         of processors.
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (University of Manchester Cluster)
-#                  =============================================
-#
-# set the name of the job
-##$ -N full_domaincase2
-#
-# request between 2 and 4 slots
-##$ -pe mpich 2-4
-#
-# Execute the job from the current working directory
-# Job output will appear in this directory
-##$ -cwd
-#   can use -o dirname to redirect stdout
-#   can use -e dirname to redirect stderr
-
-#  Export these environment variables
-##$ -v MPI_HOME
-
-#set -x
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (AIX, Loadlever)
-#                  ===========================
-#
-#@ shell = /bin/sh
-#
-#@ job_name = full_domaincase2
-#
-#@ job_type = parallel
-#@ cpus = 128
-#@ node_usage = not_shared
-#
-#@ network.MPI = csss,shared,US
-#@ bulkxfer = yes
-#
-#@ wall_clock_limit = 00:20:00
-#@ account_no = z001
-#
-#@ output = $(job_name).$(schedd_host).$(jobid).out
-#@ error  = $(job_name).$(schedd_host).$(jobid).err
-#@ notification = never
-#
-#@ queue
-# suggested environment settings:
-#  export MP_EAGER_LIMIT=65536
-#  export MP_SHARED_MEMORY=yes
-#  export MEMORY_AFFINITY=MCM
-#  export MP_TASK_AFFINITY=MCM
-#
-########################################################################
-#
-# BEGINNING OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-# runcase.help gives more details about the different variables.
-#
-#                    -------------------------------
-#
-SOLCOM=0
-#
-# On some systems, some external libraries may require TERM to be defined.
-export TERM=xterm
-#
-STUDY=FULL_DOMAIN
-CASE=CASE2
-PARAM=case2.xml
-MESH="downcomer.des fdc.des pic.des"
-COMMAND_REORIENT=
-COMMAND_JOIN="--join --color 5 24 32 --fraction 0.1 --plane 0.8"
-COMMAND_CWF=
-COMMAND_PERIO=
-THERMOCHEMISTRY_DATA=
-METEO_DATA=
-#
-# Choose the total number of processors used (if empty, automatic detection
-# through the batch system if possible, set to 1 otherwise).
-# When coupling with SYRTHES with COUPLING_MODE=MPI, the 1st processor is
-# used by SYRTHES, so the effective number of processors assigned to the
-# Kernel is reduced by 1.
-# The processors list is only usable when not running on a batch system
-# (as such a system usually already defines a similar list)
-NUMBER_OF_PROCESSORS=
-PROCESSOR_LIST=
-#
-PARTITION_LIST=
-#
-USER_INPUT_FILES=""
-USER_OUTPUT_FILES=""
-#
-# Working directory (leave empty for automatic default directory)
-CS_TMP_PREFIX=
-#CS_TMP_PREFIX=/local00/users/`whoami`
-#
-CS_LIB_ADD=
-VALGRIND=
-#
-ARG_CS_VERIF=""
-ARG_CS_OUTPUT=""
-#
-# Adaptation using HOMARD
-ADAPTATION=
-#
-summary=summary
-CASEDIR=/home/saturne/TEST_CASE/FULL_DOMAIN/CASE2
-DATA=$CASEDIR/DATA
-RESU=$CASEDIR/RESU
-SRC=$CASEDIR/SRC
-SCRIPTS=$CASEDIR/SCRIPTS
-RESTART_IN=$DATA/RESTART
-PREPROCESSOR_OUTPUT_IN=$DATA/preprocessor_output
-PARTITION_OUTPUT_IN=$DATA/PARTITION_OUTPUT
-MESHDIR=$CASEDIR/../MESH
-#
-# The following variables are only used in case of coupling with SYRTHES.
-#  DATA_SYR: directory where to find SYRTHES_ENV
-#  SRC_SYR:  directory where to find possible user source files
-DATA_SYR=$CASEDIR/DATA_SYR
-SRC_SYR=$CASEDIR/SRC_SYR
-SYRTHES_ENV=syrthes.env
-#
-# The possible coupling mode with SYRTHES may be chosen here.
-#
-#  COUPLING_MODE=MPI        : should work on most machines.
-#  COUPLING_MODE=sockets    : should be activated on clusters when the MPI rank
-#                             of a process is not determinable or if MPI can
-#                             not be used.
-COUPLING_MODE=MPI
-ECHO_SYR_COMM=""
-#
-#  Indicate which steps should be executed; if both the Preprocessor and the
-#  Kernel are executed, the "preprocessor_output" and eventual "domain_number_*"
-#  files are not saved. If only the preprocessor and / or partitioner are
-#  executed, the corresponding files will be saved in a RESU/PREPROCESSOR_OUTPUT
-#  and RESU/PARTITION directory. If the Preprocessor is not executed,
-#  "preprocessor_output" will be read from $PREPROCESSOR_OUTPUT_IN. If the
-#  Partitioner is not executed, "domain_number_*" will be read from
-#  $PARTITION_OUTPUT_IN if available (otherwise, unoptimized default
-#  partitioning will be used).
-#
-#  EXEC_PREPROCESS : should the Preprocessor be run ? (yes/no)
-#  EXEC_PARTITION  : should the Partitioner be run ? (yes/no)
-#  EXEC_KERNEL     : should the Kernel be run ? (yes/no)
-#
-EXEC_PREPROCESS=yes
-EXEC_PARTITION=yes
-EXEC_KERNEL=yes
-#
-#
-#
-########################################################################
-#
-# END OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-########################################################################
-#
-# Kernel installation parameters
-#
-prefix=/home/saturne/Code_Saturne/2.0-beta2/arch/Linux_x86_64
-#
-exec_prefix=${prefix}
-bindir=${exec_prefix}/bin
-datarootdir=${prefix}/share
-datadir=${datarootdir}
-pkgdatadir=${datadir}/ncs
-#
-# Preprocessor installation parameters
-#
-ecs_prefix=
-#
-ecs_exec_prefix=${ecs_prefix}
-ecs_bindir=${ecs_exec_prefix}/bin
-#
-# HOMARD installation parameters (to be completed if needed)
-#
-homard_prefix=
-#
-########################################################################
-#  Mesh Adaptation
-#
-if [ ! -z  "${ADAPTATION}" ] ; then
-  if [ "${ADAPTATION}" = "-help" ] ; then
-    ${homard_prefix}/saturne_homard ${ADAPTATION}
-    exit 0
-  else
-    HOMARD_options="  -v"
-    ${homard_prefix}/saturne_homard -Saturne_Script $0 -Donnees_Calcul $CASEDIR \
-                    -Pilotage_Adaptation $ADAPTATION $HOMARD_options || exit 1
-  fi
-fi
-#
-#########################################################################
-#
-N_SYRTHES_COUPLINGS=0
-if [ -f "${SRC}/ussyrc.f90" ] ; then
-  N_SYRTHES_COUPLINGS=`grep -e ^' ' ${SRC}/ussyrc.f90 | grep -i -c defsyr`
-fi
-#
-if [ $N_SYRTHES_COUPLINGS = 0 ] ; then
-  SYRTHES_COUPLING=no
-else
-  SYRTHES_COUPLING=yes
-  export SYRTHES
-  if [ $N_SYRTHES_COUPLINGS -gt 1 ] ; then
-   echo "This script can not handle multiple couplings with SYRTHES"
-   echo "Number of SYRTHES couplings requested: $N_SYRTHES_COUPLINGS"
-  fi
-fi
-#
-if [ $SYRTHES_COUPLING = yes ] ; then
-  if [ $SOLCOM -eq 1 ] ; then
-   echo "SYRTHES coupling is not compatible with SOLCOM-type meshes"
-   exit 1
-  fi
-else
-  COUPLING_MODE=
-fi
-#
-########################################################################
-#
-# Parameters for execution
-#
-# General variables
-THISSCRIPT=$0
-USER=`whoami`
-DATE=`date '+%m%d%H%M'`
-SUFFIX=$DATE
-EXE=cs_solver
-EXE_SYR=syrthes
-#
-# Copy runcase before changing to the working directory
-# (as after that, the relative path will not be up to date).
-#
-cp $0 $RESU/runcase.$SUFFIX
-#
-# Execution directory (reachable by all the processors)
-#
-if [ ! -z "$CS_TMP_PREFIX" ] ; then
-  RUN=${CS_TMP_PREFIX}/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-else
-#  Default if not specified by the user
-#
-#  On the CCRT, there is no TMPDIR. We work by default in SCRATCHDIR
-  if [ "$SCRATCHDIR" != "" ] ; then
-    RUN=$SCRATCHDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-  elif [ "$TMPDIR" != "" -a "$TMPDIR" != "/tmp" ] ; then
-    RUN=$TMPDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-  else
-    RUN=$HOME/tmp_Saturne/$STUDY.$CASE.$DATE
-  fi
-fi
-#
-# Create directory if necessary
-if [ "$RUN" != "$TMPDIR" ] ; then
-  if [ ! -d $RUN ] ; then
-    mkdir -p $RUN || exit 1
-  else
-    echo "RUN=$RUN already exists."
-    echo "The simulation will not be run."
-    exit 1
-  fi
-fi
-#
-# Create a temporary file for Salome (equivalent to "ficstp")
-if [ "$ARG_CS_OUTPUT" = "--log 0" ] ; then
-  echo $RUN > $SCRIPTS/runningstd.$DATE
-else
-  echo $RUN > $SCRIPTS/runningext.$DATE
-fi
-#
-cd $RUN
-#
-########################################################################
-#
-# Set up MPI environment
-#
-# Use makefile query to obtain the path to MPI binaries if those are
-# not on the default path. This is a peculiar use of make, but allows
-# us to avoid defining the MPI configuration in multiple files.
-
-CS_MPI_PATH=/home/saturne/opt/openmpi-1.3.1/arch/Linux_x86_64/bin
-
-# NUMBER_OF_PROCESSORS is determined here if not already set;
-# MPIHOSTS, MPIRUN, MPIBOOT, MPIHALT, and NUMBER_OF_NODES are
-# defined by the sourced script, and PATH may be updated.
-#
-. ${pkgdatadir}/runcase_mpi_env
-#
-# Check for the number of requested processors
-nproc_kernel="${NUMBER_OF_PROCESSORS}"
-echo
-echo
-if [ $SYRTHES_COUPLING = yes ] ; then
-  echo "Coupling of Code_Saturne and SYRTHES activated."
-  #  1 processor is reserved for SYRTHES if coupled through MPI.
-  if [ "$COUPLING_MODE" = "MPI" ] ; then
-    (( nproc_kernel = nproc_kernel - N_SYRTHES_COUPLINGS ))
-    if [ $nproc_kernel -lt 1 ] ; then
-      echo
-      echo
-      echo " Warning, if COUPLING_MODE = MPI, SYRTHES reserves 1 processor"
-      echo " (which need not be a physical processor)."
-      echo " Here, NUMBER_OF_PROCESSORS=${NUMBER_OF_PROCESSORS}, while it must"
-      echo " be strictly greater than 1."
-      echo " Increase the number of requested processors."
-      echo
-      exit 1
-    fi
-  fi
-fi
-if [ $nproc_kernel -gt 1 ] ; then
-  echo "Parallel Code_Saturne with partitioning in $nproc_kernel sub-domains"
-  if [ $SOLCOM = 1 ] ; then
-    echo
-    echo
-    echo " Parallel run impossible with SOLCOM = $SOLCOM "
-    echo " Use SOLCOM = 0 "
-    echo
-    exit 1
-  fi
-else
-  echo "Single processor Code_Saturne simulation"
-fi
-if [ ! -z "$MPIHOSTS" ] ; then
-  echo "Total number of processors: $NUMBER_OF_PROCESSORS"
-fi
-#
-# In parallel mode, the corresponding argument must be set
-if [ $nproc_kernel -gt 1 ] ; then
-  ARG_CS_MPI=" --mpi"
-else
-  ARG_CS_MPI=""
-fi
-#
-#
-########################################################################
-#
-# Communications
-#
-# To help debug coupling problems, make communication more verbose
-if [ ! -z "$ECHO_SYR_COMM" ] ; then
-  ECHOCOMMSYR="-echo-comm $ECHO_SYR_COMM"
-else
-  ECHOCOMMSYR=""
-fi
-########################################################################
-# Greeting message
-#
-echo ' '
-echo '                      Code_Saturne is running '
-echo '                      *********************** '
-echo ' '
-echo ' Working directory (to be periodically cleaned) : '
-echo '    ' $RUN
-#
-########################################################################
-#
-# Compilation and link
-#
-# Note: we also check the for the presence of certain user subroutines here.
-#
-echo
-echo ' Kernel version:          ' $prefix
-echo ' Preprocessor version:    ' $ecs_prefix
-
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  cur_dir=`pwd`
-
-  source_cas=$SRC
-
-  #
-  # Copy of the parameter file
-  if [ ! -z "$PARAM" ] ; then
-    var=$DATA/$PARAM
-    if [ -f $var ] ; then
-      COMMAND_PARAM="--param $PARAM"
-      cp $var .
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The parameters file ' $var
-      echo ' can not be accessed.'
-      exit 1
-    fi
-  fi
-
-  src_files=`ls ${source_cas}/*.[fF]90 ${source_cas}/*.[ch] 2>/dev/null`
-
-  if [ ! -z "${src_files}" ] ; then
-
-    echo
-    echo  "  ***************************************************************"
-    echo  "   Compilation of user subroutines and linking of Code_Saturne"
-    echo  "  ***************************************************************"
-
-    if [ -f compil.log ] ; then
-      rm -f compil.log
-    fi
-
-    src_dir="src_saturne"
-
-    # Copy of the user source files
-    # (no links: the directory is copied later)
-    mkdir ${src_dir}
-    for f in ${src_files} ; do
-      if [ -f $f ] ; then
-        cp ${f} ${src_dir}/
-      fi
-    done
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --source=$src_dir --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    # Compilation
-    if [ ! -z "${CS_LIB_ADD}" ] ; then
-      OPTLIBS="--opt-libs=${CS_LIB_ADD}"
-    fi
-    ${bindir}/cs compile \
-      --source=$src_dir ${OPTLIBS} 2>>$cur_dir/compil.log 1>&2
-    if [ $? -ne 0 ]
-    then
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-      echo "COMPILE OR LINK ERROR"
-      rm -f *.o
-      exit 1
-    else
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-    fi
-
-  else
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    ln -s ${bindir}/$EXE .
-
-  fi
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-
-    ${pkgdatadir}/runcase_syrthes -compile \
-      -cs-bindir=${bindir} -src-syr=${SRC_SYR} \
-      -src-copy=${RESU}/SRC_SYR.${SUFFIX} -log=${RESU}/compil_syrthes.log.${SUFFIX}
-
-  fi
-
-fi # EXEC_KERNEL = yes
-
-#
-########################################################################
-#
-# Data setup
-#
-echo
-echo  "  ********************************************"
-echo  "             Preparing calculation            "
-echo  "  ********************************************"
-echo
-#
-ERROR=false
-PREPROCESS_ERROR=false
-PARTITION_ERROR=false
-EXECUTION_ERROR=false
-#
-if [ $SOLCOM = 1 ]
-then
-  EXEC_PREPROCESS=no
-  EXEC_PARTITION=no
-  ln -s $MESHDIR/$MESH geomet || exit 1
-fi
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ]
-then
-  for var in $MESH ; do
-    ln -s $MESHDIR/$var $var || exit 1
-    # Special case for meshes in EnSight format: link to .geo file necessary
-    # (retrieve name through .case file)
-    var2=`basename $var .case`
-    if [ $var2 != $var ] ; then
-      ficgeo_ensight=`awk '/^model:/ {print $2}' $var`
-      ln -s $MESHDIR/$ficgeo_ensight $ficgeo_ensight || FIN
-    fi
-  done
-else
-  if [ -f ${PREPROCESSOR_OUTPUT_IN} ] ; then
-    ln -s ${PREPROCESSOR_OUTPUT_IN} preprocessor_output || exit 1
-  else
-    echo "Error: no preprocessor output file is available;"
-    echo "       (${PREPROCESSOR_OUTPUT_IN} does not exist."
-    echo "       or is not a standard file."
-    exit 1
-  fi
-fi
-#
-if [ $nproc_kernel -eq 1 -a "${EXEC_KERNEL}" = "yes" ] ; then
-  EXEC_PARTITION=no
-elif [ "${EXEC_PARTITION}" = "no" -a "${PARTITION_OUTPUT_IN}" != "" ]
-then
-  if [ -f ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} ] ; then
-    ln -s ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} .
-  else
-    echo "Warning: no partitioning file is available;"
-    echo "         (no ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel})."
-    echo
-    echo "         Unoptimized partitioning will be used."
-    echo "         Parallel performance may be degraded."
-  fi
-fi
-#
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  for var in ${RESTART_IN}/* ; do
-    if [ -f $var ] ; then
-      varb=`basename $var`
-      if   [ $varb = suiava ] ; then
-        vara=suiamo
-      elif [ $varb = suiavx ] ; then
-        vara=suiamx
-      elif [ $varb = vorava ] ; then
-        vara=voramo
-      elif [ $varb = t1dava ] ; then
-        vara=t1damo
-      elif [ $varb = rayava ] ; then
-        vara=rayamo
-      elif [ $varb = lagava ] ; then
-        vara=lagamo
-      elif [ $varb = lasava ] ; then
-        vara=lasamo
-      else
-        vara=$varb
-      fi
-      ln -s $var $vara
-    fi
-  done
-  #
-  if [ "$THERMOCHEMISTRY_DATA" != "" ] ; then
-    var=$DATA/$THERMOCHEMISTRY_DATA
-    if [ -f $var ] ; then
-      cp $var dp_tch
-      # Copy so as to have correct name upon backup
-      if [ "$THERMOCHEMISTRY_DATA" != "dp_tch" ] ; then
-        cp dp_tch $THERMOCHEMISTRY_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The thermochemistry file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  if [ "$METEO_DATA" != "" ] ; then
-    var=$DATA/$METEO_DATA
-    if [ -f $var ] ; then
-      cp $var meteo
-      # Copy so as to have correct name upon backup
-      if [ "$METEO_DATA" != "meteo" ] ; then
-        cp meteo $METEO_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The meteo profile file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  for f in uscpcl.f90 usd3pc.f90 usebuc.f90 uslwcc.f90 usfucl.f90
-  do
-    if [ -f "${SRC}/${f}" -a ! -f JANAF ] ; then
-      cp ${datadir}/data/thch/JANAF JANAF
-    fi
-  done
-  #
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    #
-    ${pkgdatadir}/runcase_syrthes -copy-data -syrthes-env=${DATA_SYR}/$SYRTHES_ENV
-    #
-  fi
-  #
-  if [ ! -z "$USER_INPUT_FILES" ] ; then
-    for f in $USER_INPUT_FILES ; do
-      cp $DATA/$f .
-    done
-  fi
-  #
-fi # EXEC_KERNEL = yes
-
-########################################################################
-# Maximum time for PBS (done here so as to leave time for PBS to
-# realize that things have started).
-#
-if [ "$PBS_JOBID" != "" ] ; then
-  CS_MAXTIME=`qstat -r $PBS_JOBID | grep $PBS_JOBID | sed -e's/ \{1,\}/ /g' | cut -d ' ' -f 9`
-  export CS_MAXTIME
-fi
-#
-########################################################################
-#
-# Summary: start
-#
-CURDATE=`unset LANG ; date`
-#
-echo '========================================================'>>$summary
-echo '   Start time       : ' $CURDATE                         >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Kernel          : ' $prefix                          >>$summary
-echo '    Preprocessor    : ' $ecs_prefix                      >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    HOMARD          : ' $homard_prefix                   >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    CS_MPI_PATH     : ' $CS_MPI_PATH                     >>$summary
-echo '    PATH            : ' $PATH                            >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    User            : ' $USER                            >>$summary
-echo '========================================================'>>$summary
-echo '    Machine         : '                                  >>$summary
-     uname -a                                                  >>$summary
-if [ -z "$NUMBER_OF_PROCESSORS" ] ; then
-  echo '    N Procs         : ' 1                              >>$summary
-else
-  echo '    N Procs         : ' $NUMBER_OF_PROCESSORS          >>$summary
-fi
-if [ -z "$PROCESSOR_LIST" ] ; then
-  echo '    Processors      : ' default                        >>$summary
-else
-  echo '    Processors      : ' $PROCESSOR_LIST                >>$summary
-fi
-echo '========================================================'>>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Case            : ' $CASE                            >>$summary
-echo '      DATA          : ' $DATA                            >>$summary
-echo '      SRC           : ' $SRC                             >>$summary
-echo '      RESU          : ' $RESU                            >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Exec. dir.      : ' $RUN                             >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-if [ "$EXEC_PREPROCESSOR" = "yes" ] ; then
-  echo '    Preprocessor    : ' ${ecs_bindir}/cs_preprocess    >>$summary
-fi
-if [ "$EXEC_PARTITION" = "yes" ] ; then
-  echo '    Partitioner     : ' ${ecs_bindir}/cs_partition     >>$summary
-fi
-if [ "$EXEC_KERNEL" = "yes" ] ; then
-  echo '    Executable      : ' $EXE                           >>$summary
-fi
-echo '  ----------------------------------------------------'  >>$summary
-#
-# Execution
-echo
-echo  "  ********************************************"
-echo  "             Starting calculation"
-echo  "  ********************************************"
-echo
-#
-# Preprocessor start
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ] ; then
-  #
-  ${ecs_bindir}/cs_preprocess --mesh $MESH "--case" $CASE \
-                   $COMMAND_REORIENT $COMMAND_JOIN $COMMAND_PERIO \
-                   > listpre 2>&1
-  if [ $? != 0 ] ; then
-    echo "Error running the preprocessor."
-    echo "Check preprocessor log (listpre) for details."
-    echo
-    PREPROCESS_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PREPROCESSOR_OUTPUT_OUT=$RESU/preprocessor_output.$SUFFIX
-    cp preprocessor_output ${PREPROCESSOR_OUTPUT_OUT}
-  fi
-  #
-fi
-#
-# Partitioner start
-#
-if [ ! -f ${ecs_bindir}/cs_partition ] ; then
-  echo "Warning: ${ecs_bindir}/cs_partition not found."
-  echo
-  echo "The partitioner may not have been installed"
-  echo "  (this is the case if neither METIS nor."
-  echo "  SCOTCH are avaialable)."
-  echo
-  echo "Unoptimized partitioning will be used, so"
-  echo "parallel performance may be degraded."
-  echo
-  EXEC_PARTITION=no
-fi
-#
-if [ "${EXEC_PARTITION}" = "yes" ] ; then
-  #
-  if [ "${EXEC_KERNEL}" = "yes" ] ; then
-    ${ecs_bindir}/cs_partition $nproc_kernel > listpart 2>&1
-  else
-    if [ -z "$PARTITION_LIST" ] ; then
-      echo "Error running the partitioner."
-      echo "PARTITION_LIST is not set."
-      echo "This variable should contain the number of processors"
-      echo "for which we partition (or a list of such numbers)."
-      PARTITION_ERROR=true
-      ERROR=true
-    else
-      ${ecs_bindir}/cs_partition $PARTITION_LIST > listpart 2>&1
-    fi
-  fi
-  if [ $? != 0 -a $PARTITION_ERROR = false ] ; then
-    echo "Error running the partitioner."
-    echo "Check partitioner log (listpart) for details."
-    echo
-    PARTITION_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PARTITION_OUTPUT_OUT=$RESU/PARTITION_OUTPUT.$SUFFIX
-    mkdir $PARTITION_OUTPUT_OUT
-    cp -r domain_number_* ${PARTITION_OUTPUT_OUT}/
-  fi
-#
-fi
-#
-# Run calculation proper.
-#
-if [ "$ERROR" != "true" -a "$EXEC_KERNEL" = "yes" ] ; then
-#
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    # MPI Communication
-    #
-    # Make sure to transmit possible additional arguments assigned by mpirun to
-    # the executable with some MPI-1 implementations (vanilla MPICH 1.2 sets the
-    # parameters needed by MPI_Init through argc/argv): we use $@ to forward
-    # arguments passed to localexec to the true executable files.
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo "MPI_RANK=\`${pkgdatadir}/runcase_mpi_rank \$@\`" >> $localexec
-    echo cd $RUN >> $localexec
-    echo "if [ \$MPI_RANK -eq 0 ] ; then" >> $localexec
-    echo "  $RUN/$EXE_SYR \$@ -app-num 0 -comm-mpi 1 $ECHOCOMMSYR > listsyr 2>&1" >> $localexec
-    echo "else" >> $localexec
-    echo "  $VALGRIND $RUN/$EXE \$@ --mpi 1 $COMMAND_CWF "\
-         "$ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM " >> $localexec
-    echo "fi" >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    #
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  elif [ $SYRTHES_COUPLING = yes  ] ; then
-    # Socket communications
-    #
-    # We provide the executables with a "random" port number.
-    PORT=35623
-    SOCKETNCS="--syr-socket $PORT"
-    SOCKETSYR="-comm-socket $PORT"
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI $COMMAND_CWF "\
-                 " $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-                 " $COMMAND_PARAM $SOCKETNCS " >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true &
-    #
-    ./$EXE_SYR $ECHOCOMMSYR $SOCKETSYR > listsyr 2>&1
-    #
-    $MPIHALT
-    #
-  elif [ $SOLCOM = 0 ] ; then
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI "\
-         " $COMMAND_CWF $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-         " $COMMAND_PARAM "  >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  else # cas SOLCOM = 1
-    #
-    $VALGRIND $RUN/$EXE --solcom \
-          $ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM \
-          || EXECUTION_ERROR=true
-    #
-  fi
-#
-fi
-#
-# Remove the Salome temporary files
-rm -f $SCRIPTS/running*.$DATE
-#
-########################################################################
-#
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    echo "Error running the coupled calculation."
-    echo "Either the Kernel or SYRTHES may have failed."
-    echo
-    echo "Check Kernel log (listing) and SYRTHES log (listsyr) for details,"
-    echo "as well as eventual error* files."
-    echo
-  else
-    echo "Error running the calculation."
-    echo
-    echo "Check Kernel log (listing) and error* files for details"
-    echo
-  fi
-  ERROR=true
-fi
-#
-# Treatment of the ouput files:
-#   Starts with the restart files
-#   (in case of full disk, increases chances of being able to continue).
-#
-if [ $EXEC_KERNEL = yes ] ; then
-
-  RESTART_OUT=$RESU/RESTART.$SUFFIX
-  iok=1
-  mkdir ${RESTART_OUT} || iok=0
-  if [ $iok = 1 ] ; then
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f ${RESTART_OUT}
-      fi
-    done
-  else
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f $RESU/$f.$SUFFIX
-      fi
-    done
-  fi
-
-  resuser=0
-  for f in ${USER_OUTPUT_FILES} ; do
-    if [ -f $f ] ; then
-      resuser=1
-    fi
-  done
-  if [ ${resuser} = 1 ] ; then
-    RES_USER=$RESU/RES_USER.$SUFFIX
-    iok=1
-    mkdir ${RES_USER} || iok=0
-    if [ $iok = 1 ] ; then
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f ${RES_USER}
-        fi
-      done
-    else
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f $RESU/$f.$SUFFIX
-        fi
-      done
-    fi
-  fi
-
-  for f in $PARAM $THERMOCHEMISTRY_DATA $METEO_DATA ; do
-    if [ -f $f ] ; then
-      cp $f $RESU/$f.$SUFFIX
-    fi
-  done
-
-  for f in probes_*.dat ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-  for f in ush* ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-
-fi  # output files
-
-for f in list* error* *.med *.cgns ; do
-  if [ -f $f ] ; then
-    cp $f $RESU/$f.$SUFFIX
-  fi
-done
-
-# Treatment of EnSight and MED files
-#   The $dir (=*.ensight and/or *.med) directories are copied
-#   to $DIR.$SUFFIX
-
-#   We place directories $dir (=*.ensight and/or *.med)
-#   in $DIR.$SUFFIX
-
-cas=`echo $CASE |tr "[:upper:]" "[:lower:]"`
-
-for dir in *.ensight *.med ; do
-  if [ -d $dir ] ; then
-    DIR=`echo $dir |tr "[:lower:]" "[:upper:]"`
-    mkdir $RESU/$DIR.$SUFFIX
-    if [ $? -ne 0 ] ; then
-      echo Creating $RESU/$DIR.$SUFFIX failed
-    else
-      for f in $dir/*  ; do
-        if [ -f $f ] ; then
-          cp -R ${f} $RESU/$DIR.$SUFFIX/.
-        fi
-      done
-    fi
-  fi
-done
-
-if [ $EXEC_KERNEL = yes ] ; then
-
-  rayt_list=`ls bord* 2>/dev/null`
-  if [ ! -z "${rayt_list}" ] ; then
-    for f in $rayt_list ; do
-      if [ ! -d $RESU/CHR.$SUFFIX ] ; then
-        mkdir $RESU/CHR.$SUFFIX
-      fi
-      cp $f $RESU/CHR.$SUFFIX/.
-    done
-  fi
-
-  lagr_list=`ls debug* deplacement* trajectoire* frontiere* 2>/dev/null`
-  if [ ! -z "${lagr_list}" ] ; then
-    mkdir $RESU/LAGR.$SUFFIX
-    for f in $lagr_list ; do
-      cp $f $RESU/LAGR.$SUFFIX
-    done
-  fi
-
-  # Matisse output files
-  if [ -f ${RUN}/resuMatisse ] ; then
-    matisse=`grep -i matisse $DATA/$PARAM`
-    if [ ! -z "$matisse" ] ; then
-  # The date is added to the first line of resuMatisse
-      AFDATE="Date of the case                                       : "$DATE
-      sed  "1i\ ${AFDATE}" ${RUN}/resuMatisse >> ${RUN}/resuMatisse.mod
-      mv ${RUN}/resuMatisse.mod ${RUN}/resuMatisse
-    fi
-    cp ${RUN}/resuMatisse ${RESU}/resuMatisse.$SUFFIX
-  fi
-
-  for dir in src_saturne ; do
-    if [ -d $dir ] ; then
-      mkdir $RESU/SRC.$SUFFIX
-      if [ $? -ne 0 ] ; then
-        echo Failure creating $RESU/SRC.$SUFFIX
-      else
-        for f in $dir/*.[fF]90 $dir/*.[ch] ; do
-          if [ -f ${f} ] ; then
-            cp -R ${f} $RESU/SRC.$SUFFIX/.
-            fbase=`basename ${f}`
-            chmod a-w $RESU/SRC.$SUFFIX/${fbase}
-          fi
-        done
-      fi
-    fi
-  done
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    ${pkgdatadir}/runcase_syrthes -copy-results \
-      -result-dir=${RESU}/RESU_SYR.${SUFFIX}
-  fi
-
-fi  # input data and outputs
-#
-########################################################################
-#
-# Summary: end
-#
-if  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  EXEC_PREPROCESS="failed"
-fi
-echo "    Preprocessing   : " $EXEC_PREPROCESS                 >>$summary
-if  [ "$PARTITION_ERROR" = "true" ] ; then
-  EXEC_PARTITION="failed"
-fi
-echo "    Partitioning    : " $EXEC_PARTITION                  >>$summary
-if  [ "$EXECUTION_ERROR" = "true" ] ; then
-  EXEC_KERNEL="failed"
-fi
-echo "    Calculation     : " $EXEC_KERNEL                     >>$summary
-#
-CURDATE=`unset LANG ; date`
-#
-echo '  ----------------------------------------------------'  >>$summary
-echo '   Finish time      : ' $CURDATE                         >>$summary
-echo '========================================================'>>$summary
-#
-cp $summary  $RESU/$summary.$SUFFIX
-#
-########################################################################
-#
-#
-# Finish
-#
-echo
-echo  "  ********************************************"
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  echo  "         Error in calculation stage."
-elif  [ "$PARTITION_ERROR" = "true" ] ; then
-  echo  "         Error in partitioning stage."
-elif  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  echo  "         Error in preprocessing stage."
-else
-  echo  "           Normal simulation finish"
-fi
-echo  "  ********************************************"
-
-if [ "$ERROR" = "true" ] ; then
-  exit 1
-else
-  exit 0
-fi
-#
-########################################################################
diff --git a/examples/2-full_domain/case3/case3.xml b/examples/2-full_domain/case3/case3.xml
index 21dee12..83fbdcf 100644
--- a/examples/2-full_domain/case3/case3.xml
+++ b/examples/2-full_domain/case3/case3.xml
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE3" study="FULL_DOMAIN" version="1.0">
+<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE3" study="FULL_DOMAIN" version="2.0">
 	<solution_domain>
 		<volumic_conditions>
 			<zone head_losses="off" initialization="on" label="all_cells" mass_source_term="off" momentum_source_term="off" name="1" scalar_source_term="off" thermal_source_term="off">all[]</zone>
@@ -17,18 +17,16 @@
 		</join_meshes>
 		<faces_cutting status="off"/>
 		<reorientation status="off"/>
-		<syrthes_coupling status="off"/>
 		<periodic_boundary/>
 		<standalone/>
 	</solution_domain>
 	<thermophysical_models>
 		<velocity_pressure>
-			<variable label="Pression" name="pressure">
+			<variable label="Pressure" name="pressure">
 				<reference_pressure>101325</reference_pressure>
 				<listing_printing status="off"/>
 			</variable>
-			<variable label="VitesseX" name="velocity_U">
-				<blending_factor>1</blending_factor>
+			<variable label="VelocityX" name="velocity_U">
 				<probes choice="5">
 					<probe_recording name="1"/>
 					<probe_recording name="2"/>
@@ -36,44 +34,51 @@
 					<probe_recording name="7"/>
 					<probe_recording name="8"/>
 				</probes>
+				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseY" name="velocity_V">
+			<variable label="VelocityY" name="velocity_V">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseZ" name="velocity_W">
+			<variable label="VelocityZ" name="velocity_W">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<property label="total_pressure" name="total_pressure"/>
+			<property label="total_pressure" name="total_pressure">
+				<probes choice="0"/>
+			</property>
 			<property label="Yplus" name="yplus" support="boundary"/>
 			<property label="Efforts" name="effort" support="boundary"/>
 			<property label="all_variables" name="all_variables" support="boundary"/>
 		</velocity_pressure>
 		<ale_method status="off"/>
 		<turbulence model="k-epsilon">
-			<variable label="EnerTurb" name="turb_k">
+			<variable label="TurbEnergy" name="turb_k">
 				<listing_printing status="off"/>
 			</variable>
 			<variable label="Dissip" name="turb_eps">
 				<listing_printing status="off"/>
 			</variable>
-			<property label="visc. tu" name="turb_viscosity"/>
+			<property label="Turb_visc" name="turb_viscosity"/>
 			<initialization choice="reference_velocity">
 				<reference_velocity>1</reference_velocity>
 			</initialization>
 		</turbulence>
 		<thermal_scalar model="temperature_celsius">
-			<property label="Flux_thermique_entrant" name="input_thermal_flux" support="boundary"/>
+			<property label="Input_thermal_flux" name="input_thermal_flux" support="boundary"/>
 		</thermal_scalar>
 		<radiative_transfer model="off">
 			<restart status="off"/>
 			<absorption_coefficient type="constant">0</absorption_coefficient>
 		</radiative_transfer>
+		<conjugate_heat_transfer>
+			<external_coupling status="off"/>
+			<external_coupling status="off"/>
+			<external_coupling status="on"/>
+		</conjugate_heat_transfer>
 		<gas_combustion model="off"/>
 		<pulverized_coal model="off"/>
 		<joule_effect model="off"/>
-		<atmospheric_flows model="off">
-			<read_meteo_data status="off"/>
-		</atmospheric_flows>
+		<atmospheric_flows model="off"/>
+		<heads_losses/>
 	</thermophysical_models>
 	<numerical_parameters>
 		<multigrid status="on"/>
@@ -85,22 +90,21 @@
 	</numerical_parameters>
 	<physical_properties>
 		<fluid_properties>
-			<property choice="variable" label="Masse vo" name="density">
-				<listing_printing status="off"/>
-				<postprocessing_recording status="off"/>
+			<property choice="user_law" label="Density" name="density">
 				<initial_value>725.735</initial_value>
+				<formula>rho = TempC*(-4.0668e-3*TempC -5.0754e-2) + 1000.9;</formula>
 			</property>
-			<property choice="constant" label="Visc. la" name="molecular_viscosity">
+			<property choice="constant" label="Molecular_visc" name="molecular_viscosity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
-				<initial_value>8.95e-05</initial_value>
+				<initial_value>8.951e-05</initial_value>
 			</property>
-			<property choice="constant" label="Ch.spec." name="specific_heat">
+			<property choice="constant" label="Sp_heat" name="specific_heat">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>5483</initial_value>
 			</property>
-			<property choice="constant" label="Cond. th" name="thermal_conductivity">
+			<property choice="constant" label="Th_cond" name="thermal_conductivity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>0.02495</initial_value>
@@ -114,14 +118,14 @@
 		<hydrostatic_pressure status="off"/>
 	</physical_properties>
 	<additional_scalars>
-		<scalar label="Temp.C" name="temperature_celsius" type="thermal">
-			<initial_value zone="1">20.0</initial_value>
+		<scalar label="TempC" name="temperature_celsius" type="thermal">
+			<initial_value label="all_cells" zone="1">20.0</initial_value>
 			<min_value>0</min_value>
 			<max_value>400</max_value>
 			<blending_factor>1</blending_factor>
 		</scalar>
 		<scalar label="scalar_2" name="scalar2" type="user">
-			<initial_value zone="1">10.0</initial_value>
+			<initial_value label="all_cells" zone="1">10.0</initial_value>
 			<min_value>0</min_value>
 			<max_value>400</max_value>
 			<property choice="constant" label="Dscal1" name="diffusion_coefficient_2">
@@ -133,13 +137,6 @@
 	<boundary_conditions>
 		<boundary label="inlet" name="1" nature="inlet">1</boundary>
 		<boundary label="outlet" name="2" nature="outlet">34</boundary>
-		<boundary label="symmetry" name="3" nature="symmetry">8 or 9 or 28 or 29 or 38 or 39</boundary>
-		<boundary label="Wall_1" name="4" nature="wall">24 and 0.1<=X and 0.5>=X</boundary>
-		<boundary label="Wall_2" name="5" nature="wall">2 or 3</boundary>
-		<boundary label="Wall_3" name="6" nature="wall">4 or 7 or 21 or 22 or 23</boundary>
-		<boundary label="Wall_4" name="7" nature="wall">6 and Y>1</boundary>
-		<boundary label="Wall_5" name="8" nature="wall">6 and Y<=1</boundary>
-		<boundary label="Wall_6" name="9" nature="wall">31 or 33</boundary>
 		<inlet label="inlet">
 			<velocity_pressure choice="norm" direction="coordinates">
 				<norm>1</norm>
@@ -150,7 +147,7 @@
 			<turbulence choice="hydraulic_diameter">
 				<hydraulic_diameter>0.5</hydraulic_diameter>
 			</turbulence>
-			<scalar choice="dirichlet" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="dirichlet" label="TempC" name="temperature_celsius" type="thermal">
 				<dirichlet>300</dirichlet>
 			</scalar>
 			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
@@ -158,70 +155,81 @@
 			</scalar>
 		</inlet>
 		<outlet label="outlet">
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
 				<neumann>0</neumann>
 			</scalar>
 		</outlet>
+		<boundary label="symmetry" name="3" nature="symmetry">8 or 9 or 28 or 29 or 38 or 39</boundary>
 		<symmetry label="symmetry"/>
-		<wall label="Wall_1">
+		<boundary label="wall_2" name="5" nature="wall">2 or 3</boundary>
+		<boundary label="wall_3" name="6" nature="wall">4 or 7 or 21 or 22 or 23</boundary>
+		<boundary label="wall_4" name="7" nature="wall">6 and Y>1</boundary>
+		<boundary label="wall_5" name="8" nature="wall">6 and Y<=1</boundary>
+		<boundary label="wall_6" name="9" nature="wall">31 or 33</boundary>
+		<wall label="wall_2">
 			<velocity_pressure choice="off">
 				<dirichlet name="velocity_U">0</dirichlet>
 				<dirichlet name="velocity_V">0</dirichlet>
 				<dirichlet name="velocity_W">0</dirichlet>
 			</velocity_pressure>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>0</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>5</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_3">
+		<wall label="wall_4">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>0</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>25</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_2">
+		<wall label="wall_3">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>5</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>0</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_4">
+		<boundary label="wall_1" name="4" nature="wall">24 and 0.1<=X and 0.5>=X</boundary>
+		<wall label="wall_6">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>25</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>40</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_5">
-			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+		<wall label="wall_5">
+			<velocity_pressure choice="off">
+				<dirichlet name="velocity_U">0</dirichlet>
+				<dirichlet name="velocity_V">0</dirichlet>
+				<dirichlet name="velocity_W">0</dirichlet>
+			</velocity_pressure>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>320</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>320</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_6">
+		<wall label="wall_1">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>40</neumann>
+				<neumann>0</neumann>
 			</scalar>
 		</wall>
 		<variable/>
@@ -229,6 +237,7 @@
 	<analysis_control>
 		<output>
 			<postprocessing_mesh_options choice="0"/>
+			<syrthes_boundary status="off"/>
 			<postprocessing_format choice="EnSight"/>
 			<postprocessing_options choice="binary"/>
 			<domain_boundary status="on"/>
@@ -276,22 +285,17 @@
 				<probe_y>0.75</probe_y>
 				<probe_z>0</probe_z>
 			</probe>
-			<probe name="9" status="on">
-				<probe_x>-0.5</probe_x>
-				<probe_y>2.25</probe_y>
-				<probe_z>0</probe_z>
-			</probe>
 		</output>
 		<time_parameters>
-			<property label="Nb Courant" name="courant_number">
+			<time_step_ref>0.05</time_step_ref>
+			<iterations>300</iterations>
+			<time_passing>0</time_passing>
+			<property label="CFL_number" name="courant_number">
 				<postprocessing_recording status="off"/>
 			</property>
-			<property label="Nb Fourier" name="fourier_number">
+			<property label="Fourier_number" name="fourier_number">
 				<postprocessing_recording status="off"/>
 			</property>
-			<time_step_ref>0.05</time_step_ref>
-			<iterations>700</iterations>
-			<time_passing>0</time_passing>
 			<zero_time_step status="off"/>
 		</time_parameters>
 		<steady_management status="off"/>
@@ -299,6 +303,12 @@
 		<profiles/>
 	</analysis_control>
 	<calcul_management>
+		<start_restart>
+			<restart status="off"/>
+			<frozen_field status="off"/>
+			<restart_rescue>0</restart_rescue>
+			<restart_with_auxiliary status="on"/>
+		</start_restart>
 		<integer_user_array>
 			<ncelet>0</ncelet>
 			<nfac>0</nfac>
@@ -311,12 +321,18 @@
 			<nfabor>0</nfabor>
 			<dimless>0</dimless>
 		</real_user_array>
-		<start_restart>
-			<restart status="off"/>
-			<frozen_field status="off"/>
-			<restart_rescue>0</restart_rescue>
-			<restart_with_auxiliary status="on"/>
-		</start_restart>
+		<integer_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</integer_work_array>
+		<real_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</real_work_array>
 	</calcul_management>
 	<lagrangian model="off"/>
 </Code_Saturne_GUI>
diff --git a/examples/2-full_domain/case3/runcase b/examples/2-full_domain/case3/runcase
deleted file mode 100755
index a6234a0..0000000
--- a/examples/2-full_domain/case3/runcase
+++ /dev/null
@@ -1,1125 +0,0 @@
-#!/bin/sh
-# bin/runcase.  Generated from runcase.in by configure.
-#============================================================================
-#
-#     This file is part of the Code_Saturne Kernel, element of the
-#     Code_Saturne CFD tool.
-#
-#     Copyright (C) 1998-2009 EDF S.A., France
-#
-#     contact: saturne-support at edf.fr
-#
-#     The Code_Saturne Kernel is free software; you can redistribute it
-#     and/or modify it under the terms of the GNU General Public License
-#     as published by the Free Software Foundation; either version 2 of
-#     the License, or (at your option) any later version.
-#
-#     The Code_Saturne Kernel 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 General Public License for more details.
-#
-#     You should have received a copy of the GNU General Public License
-#     along with the Code_Saturne Kernel; if not, write to the
-#     Free Software Foundation, Inc.,
-#     51 Franklin St, Fifth Floor,
-#     Boston, MA  02110-1301  USA
-#
-#============================================================================
-#
-########################################################################
-#
-#                  BATCH FILE FOR THE CCRT (Platine under LSF)
-#                  ===========================================
-#
-#BSUB -n 2
-#BSUB -W 00:30
-#BSUB -o full_domaincaseo.%J 
-#BSUB -e full_domaincasee.%J 
-#BSUB -J full_domaincase
-#
-#  -n : number of processors
-#  -W : walltime as hh:mm
-#  -o : output file name
-#  -e : error file name
-#  -J : job name
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE FOR THE Chatou CLUSTER (PBS)
-#                  =======================================
-#
-#PBS -l nodes=4:ppn=2
-#PBS -l walltime=1:00:00
-#PBS -l mem=320mb
-#
-#PBS -j eo
-#PBS -N full_domaincase3
-#
-#  nodes    : number of nodes
-#  ppn      : number of process per node
-#  walltime : wall clock time (hh:mm:ss)
-#  mem      : memory
-#
-#WARNING: when coupling with SYRTHES, 1 processor will be reserved for each
-#         instance of SYRTHES. The Kernel will be executed on the remaining
-#         processors, so make sure to reserve a sufficiently high number
-#         of processors.
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (University of Manchester Cluster)
-#                  =============================================
-#
-# set the name of the job
-##$ -N full_domaincase3
-#
-# request between 2 and 4 slots
-##$ -pe mpich 2-4
-#
-# Execute the job from the current working directory
-# Job output will appear in this directory
-##$ -cwd
-#   can use -o dirname to redirect stdout
-#   can use -e dirname to redirect stderr
-
-#  Export these environment variables
-##$ -v MPI_HOME
-
-#set -x
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (AIX, Loadlever)
-#                  ===========================
-#
-#@ shell = /bin/sh
-#
-#@ job_name = full_domaincase3
-#
-#@ job_type = parallel
-#@ cpus = 128
-#@ node_usage = not_shared
-#
-#@ network.MPI = csss,shared,US
-#@ bulkxfer = yes
-#
-#@ wall_clock_limit = 00:20:00
-#@ account_no = z001
-#
-#@ output = $(job_name).$(schedd_host).$(jobid).out
-#@ error  = $(job_name).$(schedd_host).$(jobid).err
-#@ notification = never
-#
-#@ queue
-# suggested environment settings:
-#  export MP_EAGER_LIMIT=65536
-#  export MP_SHARED_MEMORY=yes
-#  export MEMORY_AFFINITY=MCM
-#  export MP_TASK_AFFINITY=MCM
-#
-########################################################################
-#
-# BEGINNING OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-# runcase.help gives more details about the different variables.
-#
-#                    -------------------------------
-#
-SOLCOM=0
-#
-# On some systems, some external libraries may require TERM to be defined.
-export TERM=xterm
-#
-STUDY=FULL_DOMAIN
-CASE=CASE3
-PARAM=case3.xml
-MESH="downcomer.des fdc.des pic.des"
-COMMAND_REORIENT=
-COMMAND_JOIN="--join --color 5 24 32 --fraction 0.1 --plane 0.8"
-COMMAND_CWF=
-COMMAND_PERIO=
-THERMOCHEMISTRY_DATA=
-METEO_DATA=
-#
-# Choose the total number of processors used (if empty, automatic detection
-# through the batch system if possible, set to 1 otherwise).
-# When coupling with SYRTHES with COUPLING_MODE=MPI, the 1st processor is
-# used by SYRTHES, so the effective number of processors assigned to the
-# Kernel is reduced by 1.
-# The processors list is only usable when not running on a batch system
-# (as such a system usually already defines a similar list)
-NUMBER_OF_PROCESSORS=
-PROCESSOR_LIST=
-#
-PARTITION_LIST=
-#
-USER_INPUT_FILES=""
-USER_OUTPUT_FILES=""
-#
-# Working directory (leave empty for automatic default directory)
-CS_TMP_PREFIX=
-#CS_TMP_PREFIX=/local00/users/`whoami`
-#
-CS_LIB_ADD=
-VALGRIND=
-#
-ARG_CS_VERIF=""
-ARG_CS_OUTPUT=""
-#
-# Adaptation using HOMARD
-ADAPTATION=
-#
-summary=summary
-CASEDIR=/home/saturne/TEST_CASE/FULL_DOMAIN/CASE3
-DATA=$CASEDIR/DATA
-RESU=$CASEDIR/RESU
-SRC=$CASEDIR/SRC
-SCRIPTS=$CASEDIR/SCRIPTS
-RESTART_IN=$DATA/RESTART
-PREPROCESSOR_OUTPUT_IN=$DATA/preprocessor_output
-PARTITION_OUTPUT_IN=$DATA/PARTITION_OUTPUT
-MESHDIR=$CASEDIR/../MESH
-#
-# The following variables are only used in case of coupling with SYRTHES.
-#  DATA_SYR: directory where to find SYRTHES_ENV
-#  SRC_SYR:  directory where to find possible user source files
-DATA_SYR=$CASEDIR/DATA_SYR
-SRC_SYR=$CASEDIR/SRC_SYR
-SYRTHES_ENV=syrthes.env
-#
-# The possible coupling mode with SYRTHES may be chosen here.
-#
-#  COUPLING_MODE=MPI        : should work on most machines.
-#  COUPLING_MODE=sockets    : should be activated on clusters when the MPI rank
-#                             of a process is not determinable or if MPI can
-#                             not be used.
-COUPLING_MODE=MPI
-ECHO_SYR_COMM=""
-#
-#  Indicate which steps should be executed; if both the Preprocessor and the
-#  Kernel are executed, the "preprocessor_output" and eventual "domain_number_*"
-#  files are not saved. If only the preprocessor and / or partitioner are
-#  executed, the corresponding files will be saved in a RESU/PREPROCESSOR_OUTPUT
-#  and RESU/PARTITION directory. If the Preprocessor is not executed,
-#  "preprocessor_output" will be read from $PREPROCESSOR_OUTPUT_IN. If the
-#  Partitioner is not executed, "domain_number_*" will be read from
-#  $PARTITION_OUTPUT_IN if available (otherwise, unoptimized default
-#  partitioning will be used).
-#
-#  EXEC_PREPROCESS : should the Preprocessor be run ? (yes/no)
-#  EXEC_PARTITION  : should the Partitioner be run ? (yes/no)
-#  EXEC_KERNEL     : should the Kernel be run ? (yes/no)
-#
-EXEC_PREPROCESS=yes
-EXEC_PARTITION=yes
-EXEC_KERNEL=yes
-#
-#
-#
-########################################################################
-#
-# END OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-########################################################################
-#
-# Kernel installation parameters
-#
-prefix=/home/saturne/Code_Saturne/2.0-beta2/arch/Linux_x86_64
-#
-exec_prefix=${prefix}
-bindir=${exec_prefix}/bin
-datarootdir=${prefix}/share
-datadir=${datarootdir}
-pkgdatadir=${datadir}/ncs
-#
-# Preprocessor installation parameters
-#
-ecs_prefix=
-#
-ecs_exec_prefix=${ecs_prefix}
-ecs_bindir=${ecs_exec_prefix}/bin
-#
-# HOMARD installation parameters (to be completed if needed)
-#
-homard_prefix=
-#
-########################################################################
-#  Mesh Adaptation
-#
-if [ ! -z  "${ADAPTATION}" ] ; then
-  if [ "${ADAPTATION}" = "-help" ] ; then
-    ${homard_prefix}/saturne_homard ${ADAPTATION}
-    exit 0
-  else
-    HOMARD_options="  -v"
-    ${homard_prefix}/saturne_homard -Saturne_Script $0 -Donnees_Calcul $CASEDIR \
-                    -Pilotage_Adaptation $ADAPTATION $HOMARD_options || exit 1
-  fi
-fi
-#
-#########################################################################
-#
-N_SYRTHES_COUPLINGS=0
-if [ -f "${SRC}/ussyrc.f90" ] ; then
-  N_SYRTHES_COUPLINGS=`grep -e ^' ' ${SRC}/ussyrc.f90 | grep -i -c defsyr`
-fi
-#
-if [ $N_SYRTHES_COUPLINGS = 0 ] ; then
-  SYRTHES_COUPLING=no
-else
-  SYRTHES_COUPLING=yes
-  export SYRTHES
-  if [ $N_SYRTHES_COUPLINGS -gt 1 ] ; then
-   echo "This script can not handle multiple couplings with SYRTHES"
-   echo "Number of SYRTHES couplings requested: $N_SYRTHES_COUPLINGS"
-  fi
-fi
-#
-if [ $SYRTHES_COUPLING = yes ] ; then
-  if [ $SOLCOM -eq 1 ] ; then
-   echo "SYRTHES coupling is not compatible with SOLCOM-type meshes"
-   exit 1
-  fi
-else
-  COUPLING_MODE=
-fi
-#
-########################################################################
-#
-# Parameters for execution
-#
-# General variables
-THISSCRIPT=$0
-USER=`whoami`
-DATE=`date '+%m%d%H%M'`
-SUFFIX=$DATE
-EXE=cs_solver
-EXE_SYR=syrthes
-#
-# Copy runcase before changing to the working directory
-# (as after that, the relative path will not be up to date).
-#
-cp $0 $RESU/runcase.$SUFFIX
-#
-# Execution directory (reachable by all the processors)
-#
-if [ ! -z "$CS_TMP_PREFIX" ] ; then
-  RUN=${CS_TMP_PREFIX}/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-else
-#  Default if not specified by the user
-#
-#  On the CCRT, there is no TMPDIR. We work by default in SCRATCHDIR
-  if [ "$SCRATCHDIR" != "" ] ; then
-    RUN=$SCRATCHDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-  elif [ "$TMPDIR" != "" -a "$TMPDIR" != "/tmp" ] ; then
-    RUN=$TMPDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-  else
-    RUN=$HOME/tmp_Saturne/$STUDY.$CASE.$DATE
-  fi
-fi
-#
-# Create directory if necessary
-if [ "$RUN" != "$TMPDIR" ] ; then
-  if [ ! -d $RUN ] ; then
-    mkdir -p $RUN || exit 1
-  else
-    echo "RUN=$RUN already exists."
-    echo "The simulation will not be run."
-    exit 1
-  fi
-fi
-#
-# Create a temporary file for Salome (equivalent to "ficstp")
-if [ "$ARG_CS_OUTPUT" = "--log 0" ] ; then
-  echo $RUN > $SCRIPTS/runningstd.$DATE
-else
-  echo $RUN > $SCRIPTS/runningext.$DATE
-fi
-#
-cd $RUN
-#
-########################################################################
-#
-# Set up MPI environment
-#
-# Use makefile query to obtain the path to MPI binaries if those are
-# not on the default path. This is a peculiar use of make, but allows
-# us to avoid defining the MPI configuration in multiple files.
-
-CS_MPI_PATH=/home/saturne/opt/openmpi-1.3.1/arch/Linux_x86_64/bin
-
-# NUMBER_OF_PROCESSORS is determined here if not already set;
-# MPIHOSTS, MPIRUN, MPIBOOT, MPIHALT, and NUMBER_OF_NODES are
-# defined by the sourced script, and PATH may be updated.
-#
-. ${pkgdatadir}/runcase_mpi_env
-#
-# Check for the number of requested processors
-nproc_kernel="${NUMBER_OF_PROCESSORS}"
-echo
-echo
-if [ $SYRTHES_COUPLING = yes ] ; then
-  echo "Coupling of Code_Saturne and SYRTHES activated."
-  #  1 processor is reserved for SYRTHES if coupled through MPI.
-  if [ "$COUPLING_MODE" = "MPI" ] ; then
-    (( nproc_kernel = nproc_kernel - N_SYRTHES_COUPLINGS ))
-    if [ $nproc_kernel -lt 1 ] ; then
-      echo
-      echo
-      echo " Warning, if COUPLING_MODE = MPI, SYRTHES reserves 1 processor"
-      echo " (which need not be a physical processor)."
-      echo " Here, NUMBER_OF_PROCESSORS=${NUMBER_OF_PROCESSORS}, while it must"
-      echo " be strictly greater than 1."
-      echo " Increase the number of requested processors."
-      echo
-      exit 1
-    fi
-  fi
-fi
-if [ $nproc_kernel -gt 1 ] ; then
-  echo "Parallel Code_Saturne with partitioning in $nproc_kernel sub-domains"
-  if [ $SOLCOM = 1 ] ; then
-    echo
-    echo
-    echo " Parallel run impossible with SOLCOM = $SOLCOM "
-    echo " Use SOLCOM = 0 "
-    echo
-    exit 1
-  fi
-else
-  echo "Single processor Code_Saturne simulation"
-fi
-if [ ! -z "$MPIHOSTS" ] ; then
-  echo "Total number of processors: $NUMBER_OF_PROCESSORS"
-fi
-#
-# In parallel mode, the corresponding argument must be set
-if [ $nproc_kernel -gt 1 ] ; then
-  ARG_CS_MPI=" --mpi"
-else
-  ARG_CS_MPI=""
-fi
-#
-#
-########################################################################
-#
-# Communications
-#
-# To help debug coupling problems, make communication more verbose
-if [ ! -z "$ECHO_SYR_COMM" ] ; then
-  ECHOCOMMSYR="-echo-comm $ECHO_SYR_COMM"
-else
-  ECHOCOMMSYR=""
-fi
-########################################################################
-# Greeting message
-#
-echo ' '
-echo '                      Code_Saturne is running '
-echo '                      *********************** '
-echo ' '
-echo ' Working directory (to be periodically cleaned) : '
-echo '    ' $RUN
-#
-########################################################################
-#
-# Compilation and link
-#
-# Note: we also check the for the presence of certain user subroutines here.
-#
-echo
-echo ' Kernel version:          ' $prefix
-echo ' Preprocessor version:    ' $ecs_prefix
-
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  cur_dir=`pwd`
-
-  source_cas=$SRC
-
-  #
-  # Copy of the parameter file
-  if [ ! -z "$PARAM" ] ; then
-    var=$DATA/$PARAM
-    if [ -f $var ] ; then
-      COMMAND_PARAM="--param $PARAM"
-      cp $var .
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The parameters file ' $var
-      echo ' can not be accessed.'
-      exit 1
-    fi
-  fi
-
-  src_files=`ls ${source_cas}/*.[fF]90 ${source_cas}/*.[ch] 2>/dev/null`
-
-  if [ ! -z "${src_files}" ] ; then
-
-    echo
-    echo  "  ***************************************************************"
-    echo  "   Compilation of user subroutines and linking of Code_Saturne"
-    echo  "  ***************************************************************"
-
-    if [ -f compil.log ] ; then
-      rm -f compil.log
-    fi
-
-    src_dir="src_saturne"
-
-    # Copy of the user source files
-    # (no links: the directory is copied later)
-    mkdir ${src_dir}
-    for f in ${src_files} ; do
-      if [ -f $f ] ; then
-        cp ${f} ${src_dir}/
-      fi
-    done
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --source=$src_dir --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    # Compilation
-    if [ ! -z "${CS_LIB_ADD}" ] ; then
-      OPTLIBS="--opt-libs=${CS_LIB_ADD}"
-    fi
-    ${bindir}/cs compile \
-      --source=$src_dir ${OPTLIBS} 2>>$cur_dir/compil.log 1>&2
-    if [ $? -ne 0 ]
-    then
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-      echo "COMPILE OR LINK ERROR"
-      rm -f *.o
-      exit 1
-    else
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-    fi
-
-  else
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    ln -s ${bindir}/$EXE .
-
-  fi
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-
-    ${pkgdatadir}/runcase_syrthes -compile \
-      -cs-bindir=${bindir} -src-syr=${SRC_SYR} \
-      -src-copy=${RESU}/SRC_SYR.${SUFFIX} -log=${RESU}/compil_syrthes.log.${SUFFIX}
-
-  fi
-
-fi # EXEC_KERNEL = yes
-
-#
-########################################################################
-#
-# Data setup
-#
-echo
-echo  "  ********************************************"
-echo  "             Preparing calculation            "
-echo  "  ********************************************"
-echo
-#
-ERROR=false
-PREPROCESS_ERROR=false
-PARTITION_ERROR=false
-EXECUTION_ERROR=false
-#
-if [ $SOLCOM = 1 ]
-then
-  EXEC_PREPROCESS=no
-  EXEC_PARTITION=no
-  ln -s $MESHDIR/$MESH geomet || exit 1
-fi
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ]
-then
-  for var in $MESH ; do
-    ln -s $MESHDIR/$var $var || exit 1
-    # Special case for meshes in EnSight format: link to .geo file necessary
-    # (retrieve name through .case file)
-    var2=`basename $var .case`
-    if [ $var2 != $var ] ; then
-      ficgeo_ensight=`awk '/^model:/ {print $2}' $var`
-      ln -s $MESHDIR/$ficgeo_ensight $ficgeo_ensight || FIN
-    fi
-  done
-else
-  if [ -f ${PREPROCESSOR_OUTPUT_IN} ] ; then
-    ln -s ${PREPROCESSOR_OUTPUT_IN} preprocessor_output || exit 1
-  else
-    echo "Error: no preprocessor output file is available;"
-    echo "       (${PREPROCESSOR_OUTPUT_IN} does not exist."
-    echo "       or is not a standard file."
-    exit 1
-  fi
-fi
-#
-if [ $nproc_kernel -eq 1 -a "${EXEC_KERNEL}" = "yes" ] ; then
-  EXEC_PARTITION=no
-elif [ "${EXEC_PARTITION}" = "no" -a "${PARTITION_OUTPUT_IN}" != "" ]
-then
-  if [ -f ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} ] ; then
-    ln -s ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} .
-  else
-    echo "Warning: no partitioning file is available;"
-    echo "         (no ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel})."
-    echo
-    echo "         Unoptimized partitioning will be used."
-    echo "         Parallel performance may be degraded."
-  fi
-fi
-#
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  for var in ${RESTART_IN}/* ; do
-    if [ -f $var ] ; then
-      varb=`basename $var`
-      if   [ $varb = suiava ] ; then
-        vara=suiamo
-      elif [ $varb = suiavx ] ; then
-        vara=suiamx
-      elif [ $varb = vorava ] ; then
-        vara=voramo
-      elif [ $varb = t1dava ] ; then
-        vara=t1damo
-      elif [ $varb = rayava ] ; then
-        vara=rayamo
-      elif [ $varb = lagava ] ; then
-        vara=lagamo
-      elif [ $varb = lasava ] ; then
-        vara=lasamo
-      else
-        vara=$varb
-      fi
-      ln -s $var $vara
-    fi
-  done
-  #
-  if [ "$THERMOCHEMISTRY_DATA" != "" ] ; then
-    var=$DATA/$THERMOCHEMISTRY_DATA
-    if [ -f $var ] ; then
-      cp $var dp_tch
-      # Copy so as to have correct name upon backup
-      if [ "$THERMOCHEMISTRY_DATA" != "dp_tch" ] ; then
-        cp dp_tch $THERMOCHEMISTRY_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The thermochemistry file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  if [ "$METEO_DATA" != "" ] ; then
-    var=$DATA/$METEO_DATA
-    if [ -f $var ] ; then
-      cp $var meteo
-      # Copy so as to have correct name upon backup
-      if [ "$METEO_DATA" != "meteo" ] ; then
-        cp meteo $METEO_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The meteo profile file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  for f in uscpcl.f90 usd3pc.f90 usebuc.f90 uslwcc.f90 usfucl.f90
-  do
-    if [ -f "${SRC}/${f}" -a ! -f JANAF ] ; then
-      cp ${datadir}/data/thch/JANAF JANAF
-    fi
-  done
-  #
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    #
-    ${pkgdatadir}/runcase_syrthes -copy-data -syrthes-env=${DATA_SYR}/$SYRTHES_ENV
-    #
-  fi
-  #
-  if [ ! -z "$USER_INPUT_FILES" ] ; then
-    for f in $USER_INPUT_FILES ; do
-      cp $DATA/$f .
-    done
-  fi
-  #
-fi # EXEC_KERNEL = yes
-
-########################################################################
-# Maximum time for PBS (done here so as to leave time for PBS to
-# realize that things have started).
-#
-if [ "$PBS_JOBID" != "" ] ; then
-  CS_MAXTIME=`qstat -r $PBS_JOBID | grep $PBS_JOBID | sed -e's/ \{1,\}/ /g' | cut -d ' ' -f 9`
-  export CS_MAXTIME
-fi
-#
-########################################################################
-#
-# Summary: start
-#
-CURDATE=`unset LANG ; date`
-#
-echo '========================================================'>>$summary
-echo '   Start time       : ' $CURDATE                         >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Kernel          : ' $prefix                          >>$summary
-echo '    Preprocessor    : ' $ecs_prefix                      >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    HOMARD          : ' $homard_prefix                   >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    CS_MPI_PATH     : ' $CS_MPI_PATH                     >>$summary
-echo '    PATH            : ' $PATH                            >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    User            : ' $USER                            >>$summary
-echo '========================================================'>>$summary
-echo '    Machine         : '                                  >>$summary
-     uname -a                                                  >>$summary
-if [ -z "$NUMBER_OF_PROCESSORS" ] ; then
-  echo '    N Procs         : ' 1                              >>$summary
-else
-  echo '    N Procs         : ' $NUMBER_OF_PROCESSORS          >>$summary
-fi
-if [ -z "$PROCESSOR_LIST" ] ; then
-  echo '    Processors      : ' default                        >>$summary
-else
-  echo '    Processors      : ' $PROCESSOR_LIST                >>$summary
-fi
-echo '========================================================'>>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Case            : ' $CASE                            >>$summary
-echo '      DATA          : ' $DATA                            >>$summary
-echo '      SRC           : ' $SRC                             >>$summary
-echo '      RESU          : ' $RESU                            >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Exec. dir.      : ' $RUN                             >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-if [ "$EXEC_PREPROCESSOR" = "yes" ] ; then
-  echo '    Preprocessor    : ' ${ecs_bindir}/cs_preprocess    >>$summary
-fi
-if [ "$EXEC_PARTITION" = "yes" ] ; then
-  echo '    Partitioner     : ' ${ecs_bindir}/cs_partition     >>$summary
-fi
-if [ "$EXEC_KERNEL" = "yes" ] ; then
-  echo '    Executable      : ' $EXE                           >>$summary
-fi
-echo '  ----------------------------------------------------'  >>$summary
-#
-# Execution
-echo
-echo  "  ********************************************"
-echo  "             Starting calculation"
-echo  "  ********************************************"
-echo
-#
-# Preprocessor start
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ] ; then
-  #
-  ${ecs_bindir}/cs_preprocess --mesh $MESH "--case" $CASE \
-                   $COMMAND_REORIENT $COMMAND_JOIN $COMMAND_PERIO \
-                   > listpre 2>&1
-  if [ $? != 0 ] ; then
-    echo "Error running the preprocessor."
-    echo "Check preprocessor log (listpre) for details."
-    echo
-    PREPROCESS_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PREPROCESSOR_OUTPUT_OUT=$RESU/preprocessor_output.$SUFFIX
-    cp preprocessor_output ${PREPROCESSOR_OUTPUT_OUT}
-  fi
-  #
-fi
-#
-# Partitioner start
-#
-if [ ! -f ${ecs_bindir}/cs_partition ] ; then
-  echo "Warning: ${ecs_bindir}/cs_partition not found."
-  echo
-  echo "The partitioner may not have been installed"
-  echo "  (this is the case if neither METIS nor."
-  echo "  SCOTCH are avaialable)."
-  echo
-  echo "Unoptimized partitioning will be used, so"
-  echo "parallel performance may be degraded."
-  echo
-  EXEC_PARTITION=no
-fi
-#
-if [ "${EXEC_PARTITION}" = "yes" ] ; then
-  #
-  if [ "${EXEC_KERNEL}" = "yes" ] ; then
-    ${ecs_bindir}/cs_partition $nproc_kernel > listpart 2>&1
-  else
-    if [ -z "$PARTITION_LIST" ] ; then
-      echo "Error running the partitioner."
-      echo "PARTITION_LIST is not set."
-      echo "This variable should contain the number of processors"
-      echo "for which we partition (or a list of such numbers)."
-      PARTITION_ERROR=true
-      ERROR=true
-    else
-      ${ecs_bindir}/cs_partition $PARTITION_LIST > listpart 2>&1
-    fi
-  fi
-  if [ $? != 0 -a $PARTITION_ERROR = false ] ; then
-    echo "Error running the partitioner."
-    echo "Check partitioner log (listpart) for details."
-    echo
-    PARTITION_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PARTITION_OUTPUT_OUT=$RESU/PARTITION_OUTPUT.$SUFFIX
-    mkdir $PARTITION_OUTPUT_OUT
-    cp -r domain_number_* ${PARTITION_OUTPUT_OUT}/
-  fi
-#
-fi
-#
-# Run calculation proper.
-#
-if [ "$ERROR" != "true" -a "$EXEC_KERNEL" = "yes" ] ; then
-#
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    # MPI Communication
-    #
-    # Make sure to transmit possible additional arguments assigned by mpirun to
-    # the executable with some MPI-1 implementations (vanilla MPICH 1.2 sets the
-    # parameters needed by MPI_Init through argc/argv): we use $@ to forward
-    # arguments passed to localexec to the true executable files.
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo "MPI_RANK=\`${pkgdatadir}/runcase_mpi_rank \$@\`" >> $localexec
-    echo cd $RUN >> $localexec
-    echo "if [ \$MPI_RANK -eq 0 ] ; then" >> $localexec
-    echo "  $RUN/$EXE_SYR \$@ -app-num 0 -comm-mpi 1 $ECHOCOMMSYR > listsyr 2>&1" >> $localexec
-    echo "else" >> $localexec
-    echo "  $VALGRIND $RUN/$EXE \$@ --mpi 1 $COMMAND_CWF "\
-         "$ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM " >> $localexec
-    echo "fi" >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    #
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  elif [ $SYRTHES_COUPLING = yes  ] ; then
-    # Socket communications
-    #
-    # We provide the executables with a "random" port number.
-    PORT=35623
-    SOCKETNCS="--syr-socket $PORT"
-    SOCKETSYR="-comm-socket $PORT"
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI $COMMAND_CWF "\
-                 " $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-                 " $COMMAND_PARAM $SOCKETNCS " >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true &
-    #
-    ./$EXE_SYR $ECHOCOMMSYR $SOCKETSYR > listsyr 2>&1
-    #
-    $MPIHALT
-    #
-  elif [ $SOLCOM = 0 ] ; then
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI "\
-         " $COMMAND_CWF $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-         " $COMMAND_PARAM "  >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  else # cas SOLCOM = 1
-    #
-    $VALGRIND $RUN/$EXE --solcom \
-          $ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM \
-          || EXECUTION_ERROR=true
-    #
-  fi
-#
-fi
-#
-# Remove the Salome temporary files
-rm -f $SCRIPTS/running*.$DATE
-#
-########################################################################
-#
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    echo "Error running the coupled calculation."
-    echo "Either the Kernel or SYRTHES may have failed."
-    echo
-    echo "Check Kernel log (listing) and SYRTHES log (listsyr) for details,"
-    echo "as well as eventual error* files."
-    echo
-  else
-    echo "Error running the calculation."
-    echo
-    echo "Check Kernel log (listing) and error* files for details"
-    echo
-  fi
-  ERROR=true
-fi
-#
-# Treatment of the ouput files:
-#   Starts with the restart files
-#   (in case of full disk, increases chances of being able to continue).
-#
-if [ $EXEC_KERNEL = yes ] ; then
-
-  RESTART_OUT=$RESU/RESTART.$SUFFIX
-  iok=1
-  mkdir ${RESTART_OUT} || iok=0
-  if [ $iok = 1 ] ; then
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f ${RESTART_OUT}
-      fi
-    done
-  else
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f $RESU/$f.$SUFFIX
-      fi
-    done
-  fi
-
-  resuser=0
-  for f in ${USER_OUTPUT_FILES} ; do
-    if [ -f $f ] ; then
-      resuser=1
-    fi
-  done
-  if [ ${resuser} = 1 ] ; then
-    RES_USER=$RESU/RES_USER.$SUFFIX
-    iok=1
-    mkdir ${RES_USER} || iok=0
-    if [ $iok = 1 ] ; then
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f ${RES_USER}
-        fi
-      done
-    else
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f $RESU/$f.$SUFFIX
-        fi
-      done
-    fi
-  fi
-
-  for f in $PARAM $THERMOCHEMISTRY_DATA $METEO_DATA ; do
-    if [ -f $f ] ; then
-      cp $f $RESU/$f.$SUFFIX
-    fi
-  done
-
-  for f in probes_*.dat ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-  for f in ush* ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-
-fi  # output files
-
-for f in list* error* *.med *.cgns ; do
-  if [ -f $f ] ; then
-    cp $f $RESU/$f.$SUFFIX
-  fi
-done
-
-# Treatment of EnSight and MED files
-#   The $dir (=*.ensight and/or *.med) directories are copied
-#   to $DIR.$SUFFIX
-
-#   We place directories $dir (=*.ensight and/or *.med)
-#   in $DIR.$SUFFIX
-
-cas=`echo $CASE |tr "[:upper:]" "[:lower:]"`
-
-for dir in *.ensight *.med ; do
-  if [ -d $dir ] ; then
-    DIR=`echo $dir |tr "[:lower:]" "[:upper:]"`
-    mkdir $RESU/$DIR.$SUFFIX
-    if [ $? -ne 0 ] ; then
-      echo Creating $RESU/$DIR.$SUFFIX failed
-    else
-      for f in $dir/*  ; do
-        if [ -f $f ] ; then
-          cp -R ${f} $RESU/$DIR.$SUFFIX/.
-        fi
-      done
-    fi
-  fi
-done
-
-if [ $EXEC_KERNEL = yes ] ; then
-
-  rayt_list=`ls bord* 2>/dev/null`
-  if [ ! -z "${rayt_list}" ] ; then
-    for f in $rayt_list ; do
-      if [ ! -d $RESU/CHR.$SUFFIX ] ; then
-        mkdir $RESU/CHR.$SUFFIX
-      fi
-      cp $f $RESU/CHR.$SUFFIX/.
-    done
-  fi
-
-  lagr_list=`ls debug* deplacement* trajectoire* frontiere* 2>/dev/null`
-  if [ ! -z "${lagr_list}" ] ; then
-    mkdir $RESU/LAGR.$SUFFIX
-    for f in $lagr_list ; do
-      cp $f $RESU/LAGR.$SUFFIX
-    done
-  fi
-
-  # Matisse output files
-  if [ -f ${RUN}/resuMatisse ] ; then
-    matisse=`grep -i matisse $DATA/$PARAM`
-    if [ ! -z "$matisse" ] ; then
-  # The date is added to the first line of resuMatisse
-      AFDATE="Date of the case                                       : "$DATE
-      sed  "1i\ ${AFDATE}" ${RUN}/resuMatisse >> ${RUN}/resuMatisse.mod
-      mv ${RUN}/resuMatisse.mod ${RUN}/resuMatisse
-    fi
-    cp ${RUN}/resuMatisse ${RESU}/resuMatisse.$SUFFIX
-  fi
-
-  for dir in src_saturne ; do
-    if [ -d $dir ] ; then
-      mkdir $RESU/SRC.$SUFFIX
-      if [ $? -ne 0 ] ; then
-        echo Failure creating $RESU/SRC.$SUFFIX
-      else
-        for f in $dir/*.[fF]90 $dir/*.[ch] ; do
-          if [ -f ${f} ] ; then
-            cp -R ${f} $RESU/SRC.$SUFFIX/.
-            fbase=`basename ${f}`
-            chmod a-w $RESU/SRC.$SUFFIX/${fbase}
-          fi
-        done
-      fi
-    fi
-  done
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    ${pkgdatadir}/runcase_syrthes -copy-results \
-      -result-dir=${RESU}/RESU_SYR.${SUFFIX}
-  fi
-
-fi  # input data and outputs
-#
-########################################################################
-#
-# Summary: end
-#
-if  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  EXEC_PREPROCESS="failed"
-fi
-echo "    Preprocessing   : " $EXEC_PREPROCESS                 >>$summary
-if  [ "$PARTITION_ERROR" = "true" ] ; then
-  EXEC_PARTITION="failed"
-fi
-echo "    Partitioning    : " $EXEC_PARTITION                  >>$summary
-if  [ "$EXECUTION_ERROR" = "true" ] ; then
-  EXEC_KERNEL="failed"
-fi
-echo "    Calculation     : " $EXEC_KERNEL                     >>$summary
-#
-CURDATE=`unset LANG ; date`
-#
-echo '  ----------------------------------------------------'  >>$summary
-echo '   Finish time      : ' $CURDATE                         >>$summary
-echo '========================================================'>>$summary
-#
-cp $summary  $RESU/$summary.$SUFFIX
-#
-########################################################################
-#
-#
-# Finish
-#
-echo
-echo  "  ********************************************"
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  echo  "         Error in calculation stage."
-elif  [ "$PARTITION_ERROR" = "true" ] ; then
-  echo  "         Error in partitioning stage."
-elif  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  echo  "         Error in preprocessing stage."
-else
-  echo  "           Normal simulation finish"
-fi
-echo  "  ********************************************"
-
-if [ "$ERROR" = "true" ] ; then
-  exit 1
-else
-  exit 0
-fi
-#
-########################################################################
diff --git a/examples/2-full_domain/case3/usclim.f90 b/examples/2-full_domain/case3/usclim.f90
index aefadd2..075297f 100644
--- a/examples/2-full_domain/case3/usclim.f90
+++ b/examples/2-full_domain/case3/usclim.f90
@@ -1,6 +1,6 @@
 !-------------------------------------------------------------------------------
 
-!                      Code_Saturne version 2.0.0-beta2
+!                      Code_Saturne version 2.0.0-rc1
 !                      --------------------------
 
 !     This file is part of the Code_Saturne Kernel, element of the
@@ -52,37 +52,42 @@ subroutine usclim &
 
 !    User subroutine.
 
-!    Fill boundary conditions arrays (icodcl, rcodcl)
-!    for unknown variables.
+!    Fill boundary conditions arrays (icodcl, rcodcl) for unknown variables.
 
 
 ! Introduction
 ! ============
 
-! Here we define boundary conditions on a per-face basis.
+! Here one defines boundary conditions on a per-face basis.
 
 ! Boundary faces may be identified using the 'getfbr' subroutine.
 
-!  getfbr(string, nelts, eltlst) :
-!  - string is a user-supplied character string containing
-!    selection criteria;
-!  - nelts is set by the subroutine. It is an integer value
-!    corresponding to the number of boundary faces verifying the
-!    selection criteria;
-!  - lstelt is set by the subroutine. It is an integer array of
-!    size nelts containing the list of boundary faces verifying
-!    the selection criteria.
+!  getfbr(string, nelts, eltlst):
+!  - string is a user-supplied character string containing selection criteria;
+!  - nelts is set by the subroutine. It is an integer value corresponding to
+!    the number of boundary faces verifying the selection criteria;
+!  - lstelt is set by the subroutine. It is an integer array of size nelts
+!    containing the list of boundary faces verifying the selection criteria.
 
 !  string may contain:
-!  - references to colors (ex.: 1, 8, 26, ...
+!  - references to colors (ex.: 1, 8, 26, ...)
 !  - references to groups (ex.: inlet, group1, ...)
 !  - geometric criteria (ex. x < 0.1, y >= 0.25, ...)
-!  These criteria may be combined using logical operators
-!  ('and', 'or') and parentheses.
-!  Example: '1 and (group2 or group3) and y < 1' will select boundary
-!  faces of color 1, belonging to groups 'group2' or 'group3' and
-!  with face center coordinate y less than 1.
+!  These criteria may be combined using logical operators ('and', 'or') and
+!  parentheses.
+!  Example: '1 and (group2 or group3) and y < 1' will select boundary faces
+!  of color 1, belonging to groups 'group2' or 'group3' and with face center
+!  coordinate y less than 1.
 
+!  Operators priority, from highest to lowest:
+!    '( )' > 'not' > 'and' > 'or' > 'xor'
+
+! Similarly, interior faces and cells can be identified using the 'getfac'
+! and 'getcel' subroutines (respectively). Their syntax are identical to
+! 'getfbr' syntax.
+
+! For a more thorough description of the criteria syntax, it can be referred
+! to the user guide.
 
 
 ! Boundary condition types
@@ -94,12 +99,11 @@ subroutine usclim &
 !    For "standard" boundary conditions:
 !    -----------------------------------
 
-!     (inlet, free outlet, wall, symmetry), we define a code
-!     in the 'itypfb' array (of dimensions number of boundary faces,
-!     number of phases). This code will then be used by a non-user
-!     subroutine to assign the following conditions (scalars in
-!     particular will receive the conditions of the phase to which
-!     they are assigned). Thus:
+!     (inlet, free outlet, wall, symmetry), one defines a code in the 'itypfb'
+!     array (of dimensions number of boundary faces, number of phases).
+!     This code will then be used by a non-user subroutine to assign the
+!     following conditions (scalars in particular will receive the conditions
+!     of the phase to which they are assigned). Thus:
 
 !     Code      |  Boundary type
 !     --------------------------
@@ -109,22 +113,20 @@ subroutine usclim &
 !      iparoi   |   Wall (smooth)
 !      iparug   |   Rough wall
 
-!     Integers ientre, isolib, isymet, iparoi, iparug
-!     are defined elsewhere (param.h). Their value is greater than
-!     or equal to 1 and less than or equal to ntypmx
-!     (value fixed in paramx.h)
+!     These integers are defined elsewhere (in paramx.h header).
+!     Their value is greater than or equal to 1 and less than or  equal to
+!     ntypmx (value fixed in paramx.h)
 
 
 !     In addition, some values must be defined:
 
 
-!     - Inlet (more precisely, inlet/outlet with prescribed flow, as
-!              the flow may be prescribed as an outflow):
+!     - Inlet (more precisely, inlet/outlet with prescribed flow, as the flow
+!              may be prescribed as an outflow):
 
-!       -> Dirichlet conditions on variables
-!         other than pressure are mandatory if the flow is incoming,
-!         optional if the flow is outgoing (the code assigns 0 flux
-!         if no Dirichlet is specified); thus,
+!       -> Dirichlet conditions on variables other than pressure are mandatory
+!         if the flow is incoming, optional if the flow is outgoing (the code
+!         assigns zero flux if no Dirichlet is specified); thus,
 !         at face 'ifac', for the variable 'ivar': rcodcl(ifac, ivar, 1)
 
 
@@ -134,17 +136,15 @@ subroutine usclim &
 !         at face ifac, rcodcl(ifac, iu, 1)
 !                       rcodcl(ifac, iv, 1)
 !                       rcodcl(ifac, iw, 1)
-!       -> Specific code and prescribed temperature value
-!         at wall, if applicable:
+!       -> Specific code and prescribed temperature value at wall if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 5
 !                       rcodcl(ifac, ivar, 1) = prescribed temperature
-!       -> Specific code and prescribed flux value
-!         at wall, if applicable:
+!       -> Specific code and prescribed flux value at wall if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 3
 !                       rcodcl(ifac, ivar, 3) = prescribed flux
-!                                        =
-!        Note that the default condition for scalars
-!         (other than k and epsilon) is homogeneous Neumann.
+
+!        Note that the default condition for scalars (other than k and epsilon)
+!        is homogeneous Neumann.
 
 
 !     - Rough wall: (= impermeable solid, with rough friction)
@@ -154,62 +154,60 @@ subroutine usclim &
 !                       rcodcl(ifac, iv, 1)
 !                       rcodcl(ifac, iw, 1)
 !       -> Value of the dynamic roughness height to specify in
-!                       rcodcl(ifac, iu, 3) (value for iv et iw not used)
-!       -> Specific code and prescribed temperature value
-!         at rough wall, if applicable:
+!                       rcodcl(ifac, iu, 3)
+!       -> Value of the scalar roughness height (if required) to specify in
+!                       rcodcl(ifac, iv, 3) (values for iw are not used)
+!       -> Specific code and prescribed temperature value at wall if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 6
 !                       rcodcl(ifac, ivar, 1) = prescribed temperature
-!                       rcodcl(ifac, ivar, 3) = dynamic roughness height
-!       -> Specific code and prescribed flux value
-!         at rough wall, if applicable:
+!       -> Specific code and prescribed flux value at rough wall, if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 3
 !                       rcodcl(ifac, ivar, 3) = prescribed flux
-!                                        =
-!        Note that the default condition for scalars
-!         (other than k and epsilon) is homogeneous Neumann.
 
-!     - Symmetry (= impermeable frictionless wall):
+!        Note that the default condition for scalars (other than k and epsilon)
+!        is homogeneous Neumann.
+
+!     - Symmetry (= slip wall):
 
 !       -> Nothing to specify
 
 
 !     - Free outlet (more precisely free inlet/outlet with prescribed pressure)
 
-!       -> Nothing to prescribe for pressure and velocity
-!          For scalars and turbulent values, a Dirichlet value may optionally
-!            be specified. The behavior is as follows:
+!       -> Nothing to prescribe for pressure and velocity. For scalars and
+!          turbulent values, a Dirichlet value may optionally be specified.
+!          The behavior is as follows:
 !              * pressure is always handled as a Dirichlet condition
 !              * if the mass flow is inflowing:
-!                  we retain the velocity at infinity
+!                  one retains the velocity at infinity
 !                  Dirichlet condition for scalars and turbulent values
-!                    (or zero flux if the user has not specified a
+!                   (or zero flux if the user has not specified a
 !                    Dirichlet value)
 !                if the mass flow is outflowing:
-!                  we prescribe zero flux on the velocity, the scalars,
+!                  one prescribes zero flux on the velocity, the scalars,
 !                  and turbulent values
 
-!       Note that the pressure will be reset to P0
-!           on the first free outlet face found
+!       Note that the pressure will be reset to p0 on the first free outlet
+!       face found
 
 
 !    For "non-standard" conditions:
 !    ------------------------------
 
-!     Other than (inlet, free outlet, wall, symmetry), we define
+!     Other than (inlet, free outlet, wall, symmetry), one defines
 !      - on one hand, for each face:
-!        -> an admissible 'itypfb' value
-!           (i.e. greater than or equal to 1 and less than or equal to
-!            ntypmx; see its value in paramx.h).
+!        -> an admissible 'itypfb' value (i.e. greater than or equal to 1 and
+!           less than or equal to ntypmx; see its value in paramx.h).
 !           The values predefined in paramx.h:
-!           'ientre', 'isolib', 'isymet', 'iparoi', 'iparug' are in
-!           this range, and it is preferable not to assign one of these
-!           integers to 'itypfb' randomly or in an inconsiderate manner.
-!           To avoid this, we may use 'iindef' if we wish to avoid
-!           checking values in paramx.h. 'iindef' is an admissible
-!           value to which no predefined boundary condition is attached.
-!           Note that the 'itypfb' array is reinitialized at each time
-!           step to the non-admissible value of 0. If we forget to
-!           modify 'typfb' for a given face, the code will stop.
+!           'ientre', 'isolib', 'isymet', 'iparoi', 'iparug' are in this range,
+!           and it is preferable not to assign one of these integers to 'itypfb'
+!           randomly or in an inconsiderate manner. To avoid this, one may use
+!           'iindef' if one wish to avoid checking values in paramx.h. 'iindef'
+!           is an admissible value to which no predefined boundary condition
+!           is attached.
+!           Note that the 'itypfb' array is reinitialized at each time step to
+!           the non-admissible value of 0. If one forgets to modify 'typfb' for
+!           a given face, the code will stop.
 
 !      - and on the other hand, for each face and each variable:
 !        -> a code             icodcl(ifac, ivar)
@@ -219,15 +217,15 @@ subroutine usclim &
 !     The value of 'icodcl' is taken from the following:
 !       1: Dirichlet      (usable for any variable)
 !       3: Neumann        (usable for any variable)
-!       4: Symmetry       (usable only for the velocity and
-!                          components of the Rij tensor)
+!       4: Symmetry       (usable only for the velocity and components of
+!                          the Rij tensor)
 !       5: Smooth wall    (usable for any variable except for pressure)
 !       6: Rough wall     (usable for any variable except for pressure)
 !       9: Free outlet    (usable only for velocity)
-!     The values of the 3 'rcodcl' components are
+!     The values of the 3 'rcodcl' components are:
 !      rcodcl(ifac, ivar, 1):
 !         Dirichlet for the variable          if icodcl(ifac, ivar) =  1
-!         wall value (sliding velocity, temp) if icodcl(ifac, ivar) =  5
+!         Wall value (sliding velocity, temp) if icodcl(ifac, ivar) =  5
 !         The dimension of rcodcl(ifac, ivar, 1) is that of the
 !           resolved variable: ex U (velocity in m/s),
 !                                 T (temperature in degrees)
@@ -251,120 +249,107 @@ subroutine usclim &
 !
 !      rcodcl(ifac, ivar, 3) if icodcl(ifac, ivar) <> 6:
 !        Flux density (< 0 if gain, n outwards-facing normal)
-!                         if icodcl(ifac, ivar)= 3
+!                            if icodcl(ifac, ivar)= 3
 !         For velocities U,                in kg/(m s2) = J:
 !           rcodcl(ifac, ivar, 3) =         -(viscl+visct) * (grad U).n
-!         For pressure P,                  en kg/(m2 s):
+!         For pressure P,                  in kg/(m2 s):
 !           rcodcl(ifac, ivar, 3) =                    -dt * (grad P).n
 !         For temperatures T,              in Watt/m2:
 !           rcodcl(ifac, ivar, 3) = -Cp*(viscls+visct/sigmas) * (grad T).n
 !         For enthalpies H,                in Watt/m2:
 !           rcodcl(ifac, ivar, 3) = -(viscls+visct/sigmas) * (grad H).n
-!         For other scalars F in :
+!         For other scalars F              in:
 !           rcodcl(ifac, ivar, 3) = -(viscls+visct/sigmas) * (grad F).n
 
 !      rcodcl(ifac, ivar, 3) if icodcl(ifac, ivar) = 6:
 !        Roughness for the rough wall law
 !         For velocities U, dynamic roughness
-!           rcodcl(ifac, ivar, 3) = rugd
+!           rcodcl(ifac, iu, 3) = roughd
 !         For other scalars, thermal roughness
-!           rcodcl(ifac, ivar, 3) = rugt
+!           rcodcl(ifac, iv, 3) = rought
 
 
-!      Note that if the user assigns a value to itypfb equal to
-!       ientre, isolib, isymet, iparoi, or iparug
-!       and does not modify icodcl (zero value by default),
-!       itypfb will define the boundary condition type.
+!      Note that if the user assigns a value to itypfb equal to ientre, isolib,
+!       isymet, iparoi, or iparug and does not modify icodcl (zero value by
+!       default), itypfb will define the boundary condition type.
 
-!      To the contrary, if the user prescribes
-!        icodcl(ifac, ivar) (nonzero),
-!        the values assigned to rcodcl will be used for the considered
-!        face and variable (if rcodcl values are not set, the default
-!        values will be used for the face and variable, so:
+!      To the contrary, if the user prescribes icodcl(ifac, ivar) (nonzero),
+!        the values assigned to rcodcl will be used for the considered face
+!        and variable (if rcodcl values are not set, the default values will
+!        be used for the face and variable, so:
 !                                 rcodcl(ifac, ivar, 1) = 0.d0
 !                                 rcodcl(ifac, ivar, 2) = rinfin
 !                                 rcodcl(ifac, ivar, 3) = 0.d0)
-!        Especially, we may have for example:
-!        -> set itypfb(ifac, iphas) = iparoi
-!        which prescribes default wall conditions for all variables at
-!        face ifac,
-!        -> and define IN ADDITION for variable ivar on this face
-!        specific conditions by specifying
-!        icodcl(ifac, ivar) and the 3 rcodcl values.
-
-
-!      The user may also assign to itypfb a value not equal to
-!       ientre, isolib, isymet, iparoi, iparug, iindef
-!       but greater than or equal to 1 and less than or equal to
-!       ntypmx (see values in param.h) to distinguish
-!       groups or colors in other subroutines which are specific
-!       to the case and in which itypfb is accessible.
-!       In this case though it will be necessary to
-!       prescribe boundary conditions by assigning values to
-!       icodcl and to the 3 rcodcl fields (as the value of itypfb
-!       will not be predefined in the code).
+!        Especially, one may have for example:
+!        -> set itypfb(ifac, iphas) = iparoi which prescribes default wall
+!        conditions for all variables at face ifac,
+!        -> and define IN ADDITION for variable ivar on this face specific
+!        conditions by specifying icodcl(ifac, ivar) and the 3 rcodcl values.
+
+
+!      The user may also assign to itypfb a value not equal to ientre, isolib,
+!       isymet, iparoi, iparug, iindef but greater than or equal to 1 and less
+!       than or equal to ntypmx (see values in param.h) to distinguish groups
+!       or colors in other subroutines which are specific to the case and in
+!       which itypfb is accessible.  In this case though it will be necessary
+!       to prescribe boundary conditions by assigning values to icodcl and to
+!       the 3 rcodcl fields (as the value of itypfb will not be predefined in
+!       the code).
 
 
 ! Consistency rules
 ! =================
 
-!       A few consistency rules between 'icodcl' codes for
-!         variables with non-standard boundary conditions:
+!       A few consistency rules between 'icodcl' codes for variables with
+!       non-standard boundary conditions:
 
 !           Codes for velocity components must be identical
 !           Codes for Rij components must be identical
 !           If code (velocity or Rij) = 4
-!             we must have code (velocity and Rij) = 4
+!             one must have code (velocity and Rij) = 4
 !           If code (velocity or turbulence) = 5
-!             we must have code (velocity and turbulence) = 5
+!             one must have code (velocity and turbulence) = 5
 !           If code (velocity or turbulence) = 6
-!             we must have code (velocity and turbulence) = 6
+!             one must have code (velocity and turbulence) = 6
 !           If scalar code (except pressure or fluctuations) = 5
-!             we must have velocity code = 5
+!             one must have velocity code = 5
 !           If scalar code (except pressure or fluctuations) = 6
-!             we must have velocity code = 6
+!             one must have velocity code = 6
 
 
 ! Remarks
 ! =======
 
-!       Caution: to prescribe a flux (nonzero) to Rij,
-!                the viscosity to take into account is viscl
-!                even if visct exists (visct=rho cmu k2/epsilon)
+!       Caution: to prescribe a flux (nonzero) to Rij, the viscosity to take
+!                into account is viscl even if visct exists
+!                (visct=rho cmu k2/epsilon)
 
-!       We have the ordering array for boundary faces from the
-!           previous time step (except for the fist time step,
-!           where 'itrifb' has not been set yet).
-!       The array of boundary face types 'itypfb' has been
-!           reset before entering the subroutine.
+!       One have the ordering array for boundary faces from the previous time
+!         step (except for the fist one, where 'itrifb' has not been set yet).
+!       The array of boundary face types 'itypfb' has been reset before
+!         entering the subroutine.
 
 
-!       Note how to access some variables:
+!       Note how to access some variables (for phase    'iphas'
+!                                              variable 'ivar'
+!                                              scalar   'iscal'):
 
-! Cell values
-!               Let         iel = ifabor(ifac)
+! Cell values  (let iel = ifabor(ifac))
 
-! * Density                         phase iphas, cell iel:
-!                  propce(iel, ipproc(irom(iphas)))
-! * Dynamic molecular viscosity     phase iphas, cell iel:
-!                  propce(iel, ipproc(iviscl(iphas)))
-! * Turbulent viscosity   dynamique phase iphas, cell iel:
-!                  propce(iel, ipproc(ivisct(iphas)))
-! * Specific heat                   phase iphas, cell iel:
-!                  propce(iel, ipproc(icp(iphasl))
-! * Diffusivity: lambda          scalaire iscal, cell iel:
-!                  propce(iel, ipproc(ivisls(iscal)))
+! * Density:                                 propce(iel, ipproc(irom(iphas)))
+! * Dynamic molecular viscosity:             propce(iel, ipproc(iviscl(iphas)))
+! * Turbulent viscosity:                     propce(iel, ipproc(ivisct(iphas)))
+! * Specific heat:                           propce(iel, ipproc(icp(iphas))
+! * Diffusivity(lambda):                     propce(iel, ipproc(ivisls(iscal)))
 
 ! Boundary face values
 
-! * Density                        phase iphas, boundary face ifac :
-!                  propfb(ifac, ipprob(irom(iphas)))
-! * Mass flow relative to variable ivar, boundary face ifac:
-!      (i.e. the mass flow used for convecting ivar)
-!                  propfb(ifac, pprob(ifluma(ivar )))
-! * For other values                  at boundary face ifac:
-!      take as an approximation the value in the adjacent cell iel
-!      i.e. as above with iel = ifabor(ifac).
+! * Density:                                 propfb(ifac, ipprob(irom(iphas)))
+! * Mass flux (for convecting 'ivar'):       propfb(ifac, ipprob(ifluma(ivar)))
+
+! * For other values: take as an approximation the value in the adjacent cell
+!                     i.e. as above with iel = ifabor(ifac).
+
 
 !-------------------------------------------------------------------------------
 ! Arguments
@@ -395,12 +380,12 @@ subroutine usclim &
 ! ifmcel(ncelet)   ! ia ! <-- ! cell family numbers                            !
 ! iprfml           ! ia ! <-- ! property numbers per family                    !
 !  (nfml, nprfml)  !    !     !                                                !
-! maxelt           !  e ! <-- ! max number of cells and faces (int/boundary)   !
+! maxelt           ! i  ! <-- ! max number of cells and faces (int/boundary)   !
 ! lstelt(maxelt)   ! ia ! --- ! work array                                     !
 ! ipnfac(nfac+1)   ! ia ! <-- ! interior faces -> vertices index (optional)    !
 ! nodfac(lndfac)   ! ia ! <-- ! interior faces -> vertices list (optional)     !
 ! ipnfbr(nfabor+1) ! ia ! <-- ! boundary faces -> vertices index (optional)    !
-! nodfac(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
+! nodfbr(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
 ! icodcl           ! ia ! --> ! boundary condition code                        !
 !  (nfabor, nvar)  !    !     ! = 1  -> Dirichlet                              !
 !                  !    !     ! = 2  -> flux density                           !
@@ -409,19 +394,19 @@ subroutine usclim &
 !                  !    !     ! = 6  -> roughness and u.n=0 (velocity)         !
 !                  !    !     ! = 9  -> free inlet/outlet (velocity)           !
 !                  !    !     !         inflowing possibly blocked             !
-! itrifb(nfabor    ! ia ! <-- ! indirection for boundary faces ordering)       !
+! itrifb           ! ia ! <-- ! indirection for boundary faces ordering        !
 !  (nfabor, nphas) !    !     !                                                !
 ! itypfb           ! ia ! --> ! boundary face types                            !
 !  (nfabor, nphas) !    !     !                                                !
-! idevel(nideve)   ! ia ! <-- ! integer work array for temporary developpement !
-! ituser(nituse    ! ia ! <-- ! user-reserved integer work array               !
+! idevel(nideve)   ! ia ! <-> ! integer work array for temporary development   !
+! ituser(nituse)   ! ia ! <-> ! user-reserved integer work array               !
 ! ia(*)            ! ia ! --- ! main integer work array                        !
 ! xyzcen           ! ra ! <-- ! cell centers                                   !
 !  (ndim, ncelet)  !    !     !                                                !
 ! surfac           ! ra ! <-- ! interior faces surface vectors                 !
 !  (ndim, nfac)    !    !     !                                                !
 ! surfbo           ! ra ! <-- ! boundary faces surface vectors                 !
-!  (ndim, nfavor)  !    !     !                                                !
+!  (ndim, nfabor)  !    !     !                                                !
 ! cdgfac           ! ra ! <-- ! interior faces centers of gravity              !
 !  (ndim, nfac)    !    !     !                                                !
 ! cdgfbo           ! ra ! <-- ! boundary faces centers of gravity              !
@@ -431,14 +416,14 @@ subroutine usclim &
 ! volume(ncelet)   ! ra ! <-- ! cell volumes                                   !
 ! dt(ncelet)       ! ra ! <-- ! time step (per cell)                           !
 ! rtp, rtpa        ! ra ! <-- ! calculated variables at cell centers           !
-!  (ncelet, *)     !    !     !  (at current and preceding time steps)         !
+!  (ncelet, *)     !    !     !  (at current and previous time steps)          !
 ! propce(ncelet, *)! ra ! <-- ! physical properties at cell centers            !
 ! propfa(nfac, *)  ! ra ! <-- ! physical properties at interior face centers   !
 ! propfb(nfabor, *)! ra ! <-- ! physical properties at boundary face centers   !
 ! coefa, coefb     ! ra ! <-- ! boundary conditions                            !
 !  (nfabor, *)     !    !     !                                                !
 ! rcodcl           ! ra ! --> ! boundary condition values                      !
-!                  !    !     ! rcodcl(1) = Dirichlet value                    !
+!  (nfabor,nvar,3) !    !     ! rcodcl(1) = Dirichlet value                    !
 !                  !    !     ! rcodcl(2) = exterior exchange coefficient      !
 !                  !    !     !  (infinite if no exchange)                     !
 !                  !    !     ! rcodcl(3) = flux density value                 !
@@ -449,11 +434,10 @@ subroutine usclim &
 !                  !    !     ! for scalars    cp*(viscls+visct/sigmas)*gradt  !
 ! w1,2,3,4,5,6     ! ra ! --- ! work arrays                                    !
 !  (ncelet)        !    !     !  (computation of pressure gradient)            !
-! coefu            ! ra ! --- ! tab de trav                                    !
+! coefu            ! ra ! --- ! work array                                     !
 !  (nfabor, 3)     !    !     !  (computation of pressure gradient)            !
-! rdevel(nrdeve)   ! ra ! <-> ! tab reel complementaire developemt             !
-! rdevel(nideve)   ! ra ! <-- ! real work array for temporary developpement    !
-! rtuser(nituse    ! ra ! <-- ! user-reserved real work array                  !
+! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
+! rtuser(nrtuse)   ! ra ! <-> ! user-reserved real work array                  !
 ! ra(*)            ! ra ! --- ! main real work array                           !
 !__________________!____!_____!________________________________________________!
 
@@ -515,8 +499,8 @@ double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
 
 ! Local variables
 
-integer          idebia, idebra
-integer          ifac, ielt, ii, ivar, iphas
+integer          idebia, idebra, ielt
+integer          ifac, iel, ii, ivar, iphas
 integer          ilelt, nlelt
 double precision uref2, d2s3
 double precision rhomoy, dh, ustar2
@@ -538,26 +522,20 @@ d2s3 = 2.d0/3.d0
 !===============================================================================
 ! 2.  Assign boundary conditions to boundary faces here
 
-!     We may use selection criteria to filter boundary case subsets
+!     One may use selection criteria to filter boundary case subsets
 !       Loop on faces from a subset
 !         Set the boundary condition for each face
 !===============================================================================
 
-! --- Most types and values have been set using the GUI.
-
-! --- Set inlet values
-
-! Inlet type has already been assigned to boundary faces of color 1
-! through the GUI with a default velocity, but a time-varying value
-! is prescribed here and overrides the one given through the GUI.
-
+! --- For boundary faces of color 2 and x <= 0.01,
+!     assign an inlet for all phases
 call getfbr('1', nlelt, lstelt)
 !==========
 
-if (ttcabs .lt. 3.8d0) then
+if (ttcabs.lt.3.8d0) then
   do ielt = 1, nlelt
     ifac = lstelt(ielt)
-    rcodcl(ifac,isca(1),1) = 20.d0+100.d0*ttcabs
+    rcodcl(ifac,isca(1),1) = 20.d0 + 100.d0*ttcabs
   enddo
 else
   do ielt = 1, nlelt
diff --git a/examples/2-full_domain/case3/usphyv.f90 b/examples/2-full_domain/case3/usphyv.f90
deleted file mode 100644
index c0ee651..0000000
--- a/examples/2-full_domain/case3/usphyv.f90
+++ /dev/null
@@ -1,313 +0,0 @@
-!-------------------------------------------------------------------------------
-
-!                      Code_Saturne version 2.0.0-beta2
-!                      --------------------------
-
-!     This file is part of the Code_Saturne Kernel, element of the
-!     Code_Saturne CFD tool.
-
-!     Copyright (C) 1998-2009 EDF S.A., France
-
-!     contact: saturne-support at edf.fr
-
-!     The Code_Saturne Kernel is free software; you can redistribute it
-!     and/or modify it under the terms of the GNU General Public License
-!     as published by the Free Software Foundation; either version 2 of
-!     the License, or (at your option) any later version.
-
-!     The Code_Saturne Kernel 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 General Public License for more details.
-
-!     You should have received a copy of the GNU General Public License
-!     along with the Code_Saturne Kernel; if not, write to the
-!     Free Software Foundation, Inc.,
-!     51 Franklin St, Fifth Floor,
-!     Boston, MA  02110-1301  USA
-
-!-------------------------------------------------------------------------------
-
-subroutine usphyv &
-!================
-
- ( idbia0 , idbra0 ,                                              &
-   ndim   , ncelet , ncel   , nfac   , nfabor , nfml   , nprfml , &
-   nnod   , lndfac , lndfbr , ncelbr ,                            &
-   nvar   , nscal  , nphas  ,                                     &
-   nideve , nrdeve , nituse , nrtuse , nphmx  ,                   &
-   ifacel , ifabor , ifmfbr , ifmcel , iprfml ,                   &
-   ipnfac , nodfac , ipnfbr , nodfbr , ibrom  ,                   &
-   idevel , ituser , ia     ,                                     &
-   xyzcen , surfac , surfbo , cdgfac , cdgfbo , xyznod , volume , &
-   dt     , rtp    , rtpa   ,                                     &
-   propce , propfa , propfb ,                                     &
-   coefa  , coefb  ,                                              &
-   w1     , w2     , w3     , w4     ,                            &
-   w5     , w6     , w7     , w8     ,                            &
-   rdevel , rtuser , ra     )
-
-!===============================================================================
-! FONCTION :
-! --------
-
-! ROUTINE UTILISATEUR : REMPLISSAGE DES VARIABLES PHYSIQUES
-
-
-
-! ATTENTION :
-! =========
-
-
-! Il est INTERDIT de modifier la viscosite turbulente VISCT ici
-!        ========
-!  (une routine specifique est dediee a cela : usvist)
-
-
-!  Il FAUT AVOIR PRECISE ICP(IPHAS) = 1
-!     ==================
-!    dans usini1 si on souhaite imposer une chaleur specifique
-!    CP variable pour la phase IPHAS (sinon: ecrasement memoire).
-
-
-!  Il FAUT AVOIR PRECISE IVISLS(Numero de scalaire) = 1
-!     ==================
-!     dans usini1 si on souhaite une diffusivite VISCLS variable
-!     pour le scalaire considere (sinon: ecrasement memoire).
-
-
-
-
-! Remarques :
-! ---------
-
-! Cette routine est appelee au debut de chaque pas de temps
-
-!    Ainsi, AU PREMIER PAS DE TEMPS (calcul non suite), les seules
-!    grandeurs initialisees avant appel sont celles donnees
-!      - dans usini1 :
-!             . la masse volumique (initialisee a RO0(IPHAS))
-!             . la viscosite       (initialisee a VISCL0(IPHAS))
-!      - dans usiniv :
-!             . les variables de calcul  (initialisees a 0 par defaut
-!             ou a la valeur donnee dans usiniv)
-
-! On peut donner ici les lois de variation aux cellules
-!     - de la masse volumique                      ROM    kg/m3
-!         (et eventuellememt aux faces de bord     ROMB   kg/m3)
-!     - de la viscosite moleculaire                VISCL  kg/(m s)
-!     - de la chaleur specifique associee          CP     J/(kg degres)
-!     - des "diffusivites" associees aux scalaires VISCLS kg/(m s)
-
-
-! On dispose des types de faces de bord au pas de temps
-!   precedent (sauf au premier pas de temps, ou les tableaux
-!   ITYPFB et ITRIFB n'ont pas ete renseignes)
-
-
-! Il est conseille de ne garder dans ce sous programme que
-!    le strict necessaire.
-
-
-
-! Arguments
-!__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
-!__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! ncelbr           ! e  ! <-- ! nombre d'elements ayant au moins une           !
-!                  !    !     ! face de bord                                   !
-! nvar             ! e  ! <-- ! nombre total de variables                      !
-! nscal            ! e  ! <-- ! nombre total de scalaires                      !
-! nphas            ! e  ! <-- ! nombre de phases                               !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! nphmx            ! e  ! <-- ! nphsmx                                         !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! nfml  ,nprfml    !    !     !                                                !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfac)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (nfac+1)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfbr)       !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (nfabor+1)     !    !     !  (optionnel)                                   !
-! ibrom            ! te ! <-- ! indicateur de remplissage de romb              !
-!   (nphmx   )     !    !     !                                                !
-! idevel(nideve    ! te ! <-- ! tab entier complementaire developemt           !
-! ituser(nituse    ! te ! <-- ! tab entier complementaire utilisateur          !
-! ia(*)            ! tr ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet          !    !     !                                                !
-! dt(ncelet)       ! tr ! <-- ! pas de temps                                   !
-! rtp, rtpa        ! tr ! <-- ! variables de calcul au centre des              !
-! (ncelet,*)       !    !     !    cellules (instant courant ou prec)          !
-! propce           ! tr ! <-- ! proprietes physiques au centre des             !
-! (ncelet,*)       !    !     !    cellules                                    !
-! propfa           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfac,*)        !    !     !    faces internes                              !
-! propfb           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! coefa, coefb     ! tr ! <-- ! conditions aux limites aux                     !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! w1...8(ncelet    ! tr ! --- ! tableau de travail                             !
-! rdevel(nrdeve    ! tr ! <-- ! tab reel complementaire developemt             !
-! rtuser(nrtuse    ! tr ! <-- ! tab reel complementaire utilisateur            !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
-!__________________!____!_____!________________________________________________!
-
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
-!===============================================================================
-
-implicit none
-
-!===============================================================================
-!     DONNEES EN COMMON
-!===============================================================================
-
-include "paramx.h"
-include "pointe.h"
-include "numvar.h"
-include "optcal.h"
-include "cstphy.h"
-include "entsor.h"
-include "parall.h"
-include "period.h"
-
-!===============================================================================
-
-! Arguments
-
-integer          idbia0 , idbra0
-integer          ndim   , ncelet , ncel   , nfac   , nfabor
-integer          nfml   , nprfml
-integer          nnod   , lndfac , lndfbr , ncelbr
-integer          nvar   , nscal  , nphas
-integer          nideve , nrdeve , nituse , nrtuse , nphmx
-
-integer          ifacel(2,nfac) , ifabor(nfabor)
-integer          ifmfbr(nfabor) , ifmcel(ncelet)
-integer          iprfml(nfml,nprfml)
-integer          ipnfac(nfac+1), nodfac(lndfac)
-integer          ipnfbr(nfabor+1), nodfbr(lndfbr), ibrom(nphmx)
-integer          idevel(nideve), ituser(nituse), ia(*)
-
-double precision xyzcen(ndim,ncelet)
-double precision surfac(ndim,nfac), surfbo(ndim,nfabor)
-double precision cdgfac(ndim,nfac), cdgfbo(ndim,nfabor)
-double precision xyznod(ndim,nnod), volume(ncelet)
-double precision dt(ncelet), rtp(ncelet,*), rtpa(ncelet,*)
-double precision propce(ncelet,*)
-double precision propfa(nfac,*), propfb(nfabor,*)
-double precision coefa(nfabor,*), coefb(nfabor,*)
-double precision w1(ncelet),w2(ncelet),w3(ncelet),w4(ncelet)
-double precision w5(ncelet),w6(ncelet),w7(ncelet),w8(ncelet)
-double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
-
-! VARIABLES LOCALES
-
-integer          idebia, idebra
-integer          ivart, iclvar, iel, iphas
-integer          ipcrom, ipbrom, ipcvis, ipccp
-integer          ipcvsl, ith, iscal, ii
-integer          iutile
-double precision vara, varb, varc, varam, varbm, varcm, vardm
-double precision                   varal, varbl, varcl, vardl
-double precision                   varac, varbc
-double precision xrtp
-
-!===============================================================================
-
-!===============================================================================
-! 0. Initializations
-!===============================================================================
-
-! --- Memory initialization
-
-idebia = idbia0
-idebra = idbra0
-
-
-!===============================================================================
-
-! Variable density, as a function of temperature
-! ================
-
-! We use the same density law for all phases.
-!    Values of this property are assigned to cell centers.
-!    (and optionally to boundary faces).
-
-!===============================================================================
-
-do iphas = 1, nphas ! Loop on phases
-
-  ! The position of the density of phase iphas in propce
-  ! (physical properties at element centers) given by ipcrom.
-
-  ipcrom = ipproc(irom(iphas))
-
-  ! Coefficients chosen and prescribed by the user.
-
-  vara  = -4.0668d-3
-  varb  = -5.0754d-2
-  varc  =  1000.9d0
-
-  ! Density at cell centers
-  ! -----------------------
-  !   Law:              rho        =   t  * (  a *  t +  b ) +   c
-  !   Code:    propce(iel, ipcrom) = xrtp * (vara*xrtp+varb) + varc
-
-  do iel = 1, ncel
-    xrtp = rtp(iel,isca(1))
-    propce(iel,ipcrom) = xrtp * (vara*xrtp+varb) + varc
-  enddo
-
-enddo ! End of loop on phases
-
-!===============================================================================
-
-!----
-! Formats
-!----
-
-!----
-! Fin
-!----
-
-return
-end
diff --git a/examples/2-full_domain/case4/case4.xml b/examples/2-full_domain/case4/case4.xml
index 21dee12..79d2799 100644
--- a/examples/2-full_domain/case4/case4.xml
+++ b/examples/2-full_domain/case4/case4.xml
@@ -1,7 +1,8 @@
-<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE3" study="FULL_DOMAIN" version="1.0">
+<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE4" study="FULL_DOMAIN" version="2.0">
 	<solution_domain>
 		<volumic_conditions>
 			<zone head_losses="off" initialization="on" label="all_cells" mass_source_term="off" momentum_source_term="off" name="1" scalar_source_term="off" thermal_source_term="off">all[]</zone>
+			<zone head_losses="on" initialization="off" label="Obstacle" mass_source_term="off" momentum_source_term="off" name="2" scalar_source_term="off" thermal_source_term="off">X >= 0.2 and X <= 0.4 and Y >= -0.75 and Y <= -0.25</zone>
 		</volumic_conditions>
 		<meshes_list>
 			<mesh format="des" name="downcomer.des"/>
@@ -17,17 +18,16 @@
 		</join_meshes>
 		<faces_cutting status="off"/>
 		<reorientation status="off"/>
-		<syrthes_coupling status="off"/>
 		<periodic_boundary/>
 		<standalone/>
 	</solution_domain>
 	<thermophysical_models>
 		<velocity_pressure>
-			<variable label="Pression" name="pressure">
+			<variable label="Pressure" name="pressure">
 				<reference_pressure>101325</reference_pressure>
 				<listing_printing status="off"/>
 			</variable>
-			<variable label="VitesseX" name="velocity_U">
+			<variable label="VelocityX" name="velocity_U">
 				<blending_factor>1</blending_factor>
 				<probes choice="5">
 					<probe_recording name="1"/>
@@ -37,43 +37,65 @@
 					<probe_recording name="8"/>
 				</probes>
 			</variable>
-			<variable label="VitesseY" name="velocity_V">
+			<variable label="VelocityY" name="velocity_V">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseZ" name="velocity_W">
+			<variable label="VelocityZ" name="velocity_W">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<property label="total_pressure" name="total_pressure"/>
+			<property label="total_pressure" name="total_pressure">
+				<probes choice="0"/>
+			</property>
 			<property label="Yplus" name="yplus" support="boundary"/>
 			<property label="Efforts" name="effort" support="boundary"/>
 			<property label="all_variables" name="all_variables" support="boundary"/>
 		</velocity_pressure>
 		<ale_method status="off"/>
 		<turbulence model="k-epsilon">
-			<variable label="EnerTurb" name="turb_k">
+			<variable label="TurbEnergy" name="turb_k">
 				<listing_printing status="off"/>
 			</variable>
 			<variable label="Dissip" name="turb_eps">
 				<listing_printing status="off"/>
 			</variable>
-			<property label="visc. tu" name="turb_viscosity"/>
+			<property label="TurbVisc" name="turb_viscosity"/>
 			<initialization choice="reference_velocity">
 				<reference_velocity>1</reference_velocity>
 			</initialization>
 		</turbulence>
 		<thermal_scalar model="temperature_celsius">
-			<property label="Flux_thermique_entrant" name="input_thermal_flux" support="boundary"/>
+			<property label="Input_thermal_flux" name="input_thermal_flux" support="boundary"/>
 		</thermal_scalar>
 		<radiative_transfer model="off">
 			<restart status="off"/>
 			<absorption_coefficient type="constant">0</absorption_coefficient>
 		</radiative_transfer>
+		<conjugate_heat_transfer>
+			<external_coupling status="off"/>
+			<external_coupling status="off"/>
+			<external_coupling status="on"/>
+		</conjugate_heat_transfer>
 		<gas_combustion model="off"/>
 		<pulverized_coal model="off"/>
 		<joule_effect model="off"/>
-		<atmospheric_flows model="off">
-			<read_meteo_data status="off"/>
-		</atmospheric_flows>
+		<atmospheric_flows model="off"/>
+		<heads_losses>
+			<head_loss label="Obstacle" name="2">
+				<kxx>20000</kxx>
+				<kyy>20000</kyy>
+				<kzz>20000</kzz>
+				<a11>1</a11>
+				<a12>0</a12>
+				<a13>0</a13>
+				<a21>0</a21>
+				<a22>1</a22>
+				<a23>0</a23>
+				<a31>0</a31>
+				<a32>0</a32>
+				<a33>1</a33>
+				<choice>off</choice>
+			</head_loss>
+		</heads_losses>
 	</thermophysical_models>
 	<numerical_parameters>
 		<multigrid status="on"/>
@@ -85,22 +107,21 @@
 	</numerical_parameters>
 	<physical_properties>
 		<fluid_properties>
-			<property choice="variable" label="Masse vo" name="density">
-				<listing_printing status="off"/>
-				<postprocessing_recording status="off"/>
+			<property choice="user_law" label="Density" name="density">
 				<initial_value>725.735</initial_value>
+				<formula>rho = TempC*(-4.0668e-3*TempC -5.0754e-2) + 1000.9;</formula>
 			</property>
-			<property choice="constant" label="Visc. la" name="molecular_viscosity">
+			<property choice="constant" label="Molecular_visc" name="molecular_viscosity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
-				<initial_value>8.95e-05</initial_value>
+				<initial_value>8.951e-05</initial_value>
 			</property>
-			<property choice="constant" label="Ch.spec." name="specific_heat">
+			<property choice="constant" label="Sp_heat" name="specific_heat">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>5483</initial_value>
 			</property>
-			<property choice="constant" label="Cond. th" name="thermal_conductivity">
+			<property choice="constant" label="Th_cond" name="thermal_conductivity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>0.02495</initial_value>
@@ -114,14 +135,14 @@
 		<hydrostatic_pressure status="off"/>
 	</physical_properties>
 	<additional_scalars>
-		<scalar label="Temp.C" name="temperature_celsius" type="thermal">
-			<initial_value zone="1">20.0</initial_value>
+		<scalar label="TempC" name="temperature_celsius" type="thermal">
+			<initial_value label="all_cells" zone="1">20.0</initial_value>
 			<min_value>0</min_value>
 			<max_value>400</max_value>
 			<blending_factor>1</blending_factor>
 		</scalar>
 		<scalar label="scalar_2" name="scalar2" type="user">
-			<initial_value zone="1">10.0</initial_value>
+			<initial_value label="all_cells" zone="1">10.0</initial_value>
 			<min_value>0</min_value>
 			<max_value>400</max_value>
 			<property choice="constant" label="Dscal1" name="diffusion_coefficient_2">
@@ -133,13 +154,6 @@
 	<boundary_conditions>
 		<boundary label="inlet" name="1" nature="inlet">1</boundary>
 		<boundary label="outlet" name="2" nature="outlet">34</boundary>
-		<boundary label="symmetry" name="3" nature="symmetry">8 or 9 or 28 or 29 or 38 or 39</boundary>
-		<boundary label="Wall_1" name="4" nature="wall">24 and 0.1<=X and 0.5>=X</boundary>
-		<boundary label="Wall_2" name="5" nature="wall">2 or 3</boundary>
-		<boundary label="Wall_3" name="6" nature="wall">4 or 7 or 21 or 22 or 23</boundary>
-		<boundary label="Wall_4" name="7" nature="wall">6 and Y>1</boundary>
-		<boundary label="Wall_5" name="8" nature="wall">6 and Y<=1</boundary>
-		<boundary label="Wall_6" name="9" nature="wall">31 or 33</boundary>
 		<inlet label="inlet">
 			<velocity_pressure choice="norm" direction="coordinates">
 				<norm>1</norm>
@@ -150,7 +164,7 @@
 			<turbulence choice="hydraulic_diameter">
 				<hydraulic_diameter>0.5</hydraulic_diameter>
 			</turbulence>
-			<scalar choice="dirichlet" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="dirichlet" label="TempC" name="temperature_celsius" type="thermal">
 				<dirichlet>300</dirichlet>
 			</scalar>
 			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
@@ -158,70 +172,77 @@
 			</scalar>
 		</inlet>
 		<outlet label="outlet">
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
 				<neumann>0</neumann>
 			</scalar>
 		</outlet>
+		<boundary label="symmetry" name="3" nature="symmetry">8 or 9 or 28 or 29 or 38 or 39</boundary>
 		<symmetry label="symmetry"/>
-		<wall label="Wall_1">
-			<velocity_pressure choice="off">
-				<dirichlet name="velocity_U">0</dirichlet>
-				<dirichlet name="velocity_V">0</dirichlet>
-				<dirichlet name="velocity_W">0</dirichlet>
-			</velocity_pressure>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+		<boundary label="wall_2" name="5" nature="wall">2 or 3</boundary>
+		<boundary label="wall_3" name="6" nature="wall">4 or 7 or 21 or 22 or 23</boundary>
+		<boundary label="wall_4" name="7" nature="wall">6 and Y>1</boundary>
+		<boundary label="wall_5" name="8" nature="wall">6 and Y<=1</boundary>
+		<boundary label="wall_6" name="9" nature="wall">31 or 33</boundary>
+		<wall label="wall_2">
+			<velocity_pressure choice="off"/>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>0</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>5</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_3">
+		<wall label="wall_4">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>0</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>25</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_2">
+		<wall label="wall_3">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>5</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>0</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_4">
+		<boundary label="wall_1" name="4" nature="wall">24 and 0.1<=X and 0.5>=X</boundary>
+		<wall label="wall_6">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>25</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>40</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_5">
-			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+		<wall label="wall_5">
+			<velocity_pressure choice="off">
+				<dirichlet name="velocity_U">0</dirichlet>
+				<dirichlet name="velocity_V">0</dirichlet>
+				<dirichlet name="velocity_W">0</dirichlet>
+			</velocity_pressure>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
-			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>320</neumann>
+			<scalar choice="dirichlet" label="scalar_2" name="scalar2" type="user">
+				<dirichlet>320</dirichlet>
 			</scalar>
 		</wall>
-		<wall label="Wall_6">
+		<wall label="wall_1">
 			<velocity_pressure choice="off"/>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 			<scalar choice="neumann" label="scalar_2" name="scalar2" type="user">
-				<neumann>40</neumann>
+				<neumann>0</neumann>
 			</scalar>
 		</wall>
 		<variable/>
@@ -229,6 +250,7 @@
 	<analysis_control>
 		<output>
 			<postprocessing_mesh_options choice="0"/>
+			<syrthes_boundary status="off"/>
 			<postprocessing_format choice="EnSight"/>
 			<postprocessing_options choice="binary"/>
 			<domain_boundary status="on"/>
@@ -283,15 +305,16 @@
 			</probe>
 		</output>
 		<time_parameters>
-			<property label="Nb Courant" name="courant_number">
+			<time_step_ref>0.05</time_step_ref>
+			<iterations>300</iterations>
+			<time_passing>0</time_passing>
+			<property label="NbCourant" name="courant_number">
 				<postprocessing_recording status="off"/>
 			</property>
-			<property label="Nb Fourier" name="fourier_number">
+			<property label="NbFourier" name="fourier_number">
 				<postprocessing_recording status="off"/>
 			</property>
-			<time_step_ref>0.05</time_step_ref>
-			<iterations>700</iterations>
-			<time_passing>0</time_passing>
+			<thermal_time_step status="off"/>
 			<zero_time_step status="off"/>
 		</time_parameters>
 		<steady_management status="off"/>
@@ -299,6 +322,22 @@
 		<profiles/>
 	</analysis_control>
 	<calcul_management>
+		<start_restart>
+			<restart status="off"/>
+			<frozen_field status="off"/>
+		</start_restart>
+		<integer_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</integer_work_array>
+		<real_work_array>
+			<ncelet>0</ncelet>
+			<nfac>0</nfac>
+			<nfabor>0</nfabor>
+			<dimless>0</dimless>
+		</real_work_array>
 		<integer_user_array>
 			<ncelet>0</ncelet>
 			<nfac>0</nfac>
@@ -311,12 +350,6 @@
 			<nfabor>0</nfabor>
 			<dimless>0</dimless>
 		</real_user_array>
-		<start_restart>
-			<restart status="off"/>
-			<frozen_field status="off"/>
-			<restart_rescue>0</restart_rescue>
-			<restart_with_auxiliary status="on"/>
-		</start_restart>
 	</calcul_management>
 	<lagrangian model="off"/>
 </Code_Saturne_GUI>
diff --git a/examples/2-full_domain/case4/runcase b/examples/2-full_domain/case4/runcase
deleted file mode 100755
index 394ff8e..0000000
--- a/examples/2-full_domain/case4/runcase
+++ /dev/null
@@ -1,1125 +0,0 @@
-#!/bin/sh
-# bin/runcase.  Generated from runcase.in by configure.
-#============================================================================
-#
-#     This file is part of the Code_Saturne Kernel, element of the
-#     Code_Saturne CFD tool.
-#
-#     Copyright (C) 1998-2009 EDF S.A., France
-#
-#     contact: saturne-support at edf.fr
-#
-#     The Code_Saturne Kernel is free software; you can redistribute it
-#     and/or modify it under the terms of the GNU General Public License
-#     as published by the Free Software Foundation; either version 2 of
-#     the License, or (at your option) any later version.
-#
-#     The Code_Saturne Kernel 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 General Public License for more details.
-#
-#     You should have received a copy of the GNU General Public License
-#     along with the Code_Saturne Kernel; if not, write to the
-#     Free Software Foundation, Inc.,
-#     51 Franklin St, Fifth Floor,
-#     Boston, MA  02110-1301  USA
-#
-#============================================================================
-#
-########################################################################
-#
-#                  BATCH FILE FOR THE CCRT (Platine under LSF)
-#                  ===========================================
-#
-#BSUB -n 2
-#BSUB -W 00:30
-#BSUB -o full_domaincaseo.%J 
-#BSUB -e full_domaincasee.%J 
-#BSUB -J full_domaincase
-#
-#  -n : number of processors
-#  -W : walltime as hh:mm
-#  -o : output file name
-#  -e : error file name
-#  -J : job name
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE FOR THE Chatou CLUSTER (PBS)
-#                  =======================================
-#
-#PBS -l nodes=4:ppn=2
-#PBS -l walltime=1:00:00
-#PBS -l mem=320mb
-#
-#PBS -j eo
-#PBS -N full_domaincase4
-#
-#  nodes    : number of nodes
-#  ppn      : number of process per node
-#  walltime : wall clock time (hh:mm:ss)
-#  mem      : memory
-#
-#WARNING: when coupling with SYRTHES, 1 processor will be reserved for each
-#         instance of SYRTHES. The Kernel will be executed on the remaining
-#         processors, so make sure to reserve a sufficiently high number
-#         of processors.
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (University of Manchester Cluster)
-#                  =============================================
-#
-# set the name of the job
-##$ -N full_domaincase4
-#
-# request between 2 and 4 slots
-##$ -pe mpich 2-4
-#
-# Execute the job from the current working directory
-# Job output will appear in this directory
-##$ -cwd
-#   can use -o dirname to redirect stdout
-#   can use -e dirname to redirect stderr
-
-#  Export these environment variables
-##$ -v MPI_HOME
-
-#set -x
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (AIX, Loadlever)
-#                  ===========================
-#
-#@ shell = /bin/sh
-#
-#@ job_name = full_domaincase4
-#
-#@ job_type = parallel
-#@ cpus = 128
-#@ node_usage = not_shared
-#
-#@ network.MPI = csss,shared,US
-#@ bulkxfer = yes
-#
-#@ wall_clock_limit = 00:20:00
-#@ account_no = z001
-#
-#@ output = $(job_name).$(schedd_host).$(jobid).out
-#@ error  = $(job_name).$(schedd_host).$(jobid).err
-#@ notification = never
-#
-#@ queue
-# suggested environment settings:
-#  export MP_EAGER_LIMIT=65536
-#  export MP_SHARED_MEMORY=yes
-#  export MEMORY_AFFINITY=MCM
-#  export MP_TASK_AFFINITY=MCM
-#
-########################################################################
-#
-# BEGINNING OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-# runcase.help gives more details about the different variables.
-#
-#                    -------------------------------
-#
-SOLCOM=0
-#
-# On some systems, some external libraries may require TERM to be defined.
-export TERM=xterm
-#
-STUDY=FULL_DOMAIN
-CASE=CASE4
-PARAM=case4.xml
-MESH="downcomer.des fdc.des pic.des"
-COMMAND_REORIENT=
-COMMAND_JOIN="--join --color 5 24 32 --fraction 0.1 --plane 0.8"
-COMMAND_CWF=
-COMMAND_PERIO=
-THERMOCHEMISTRY_DATA=
-METEO_DATA=
-#
-# Choose the total number of processors used (if empty, automatic detection
-# through the batch system if possible, set to 1 otherwise).
-# When coupling with SYRTHES with COUPLING_MODE=MPI, the 1st processor is
-# used by SYRTHES, so the effective number of processors assigned to the
-# Kernel is reduced by 1.
-# The processors list is only usable when not running on a batch system
-# (as such a system usually already defines a similar list)
-NUMBER_OF_PROCESSORS=
-PROCESSOR_LIST=
-#
-PARTITION_LIST=
-#
-USER_INPUT_FILES=""
-USER_OUTPUT_FILES=""
-#
-# Working directory (leave empty for automatic default directory)
-CS_TMP_PREFIX=
-#CS_TMP_PREFIX=/local00/users/`whoami`
-#
-CS_LIB_ADD=
-VALGRIND=
-#
-ARG_CS_VERIF=""
-ARG_CS_OUTPUT=""
-#
-# Adaptation using HOMARD
-ADAPTATION=
-#
-summary=summary
-CASEDIR=/home/saturne/TEST_CASE/FULL_DOMAIN/CASE4
-DATA=$CASEDIR/DATA
-RESU=$CASEDIR/RESU
-SRC=$CASEDIR/SRC
-SCRIPTS=$CASEDIR/SCRIPTS
-RESTART_IN=$DATA/RESTART
-PREPROCESSOR_OUTPUT_IN=$DATA/preprocessor_output
-PARTITION_OUTPUT_IN=$DATA/PARTITION_OUTPUT
-MESHDIR=$CASEDIR/../MESH
-#
-# The following variables are only used in case of coupling with SYRTHES.
-#  DATA_SYR: directory where to find SYRTHES_ENV
-#  SRC_SYR:  directory where to find possible user source files
-DATA_SYR=$CASEDIR/DATA_SYR
-SRC_SYR=$CASEDIR/SRC_SYR
-SYRTHES_ENV=syrthes.env
-#
-# The possible coupling mode with SYRTHES may be chosen here.
-#
-#  COUPLING_MODE=MPI        : should work on most machines.
-#  COUPLING_MODE=sockets    : should be activated on clusters when the MPI rank
-#                             of a process is not determinable or if MPI can
-#                             not be used.
-COUPLING_MODE=MPI
-ECHO_SYR_COMM=""
-#
-#  Indicate which steps should be executed; if both the Preprocessor and the
-#  Kernel are executed, the "preprocessor_output" and eventual "domain_number_*"
-#  files are not saved. If only the preprocessor and / or partitioner are
-#  executed, the corresponding files will be saved in a RESU/PREPROCESSOR_OUTPUT
-#  and RESU/PARTITION directory. If the Preprocessor is not executed,
-#  "preprocessor_output" will be read from $PREPROCESSOR_OUTPUT_IN. If the
-#  Partitioner is not executed, "domain_number_*" will be read from
-#  $PARTITION_OUTPUT_IN if available (otherwise, unoptimized default
-#  partitioning will be used).
-#
-#  EXEC_PREPROCESS : should the Preprocessor be run ? (yes/no)
-#  EXEC_PARTITION  : should the Partitioner be run ? (yes/no)
-#  EXEC_KERNEL     : should the Kernel be run ? (yes/no)
-#
-EXEC_PREPROCESS=yes
-EXEC_PARTITION=yes
-EXEC_KERNEL=yes
-#
-#
-#
-########################################################################
-#
-# END OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-########################################################################
-#
-# Kernel installation parameters
-#
-prefix=/home/saturne/Code_Saturne/2.0-beta2/arch/Linux_x86_64
-#
-exec_prefix=${prefix}
-bindir=${exec_prefix}/bin
-datarootdir=${prefix}/share
-datadir=${datarootdir}
-pkgdatadir=${datadir}/ncs
-#
-# Preprocessor installation parameters
-#
-ecs_prefix=
-#
-ecs_exec_prefix=${ecs_prefix}
-ecs_bindir=${ecs_exec_prefix}/bin
-#
-# HOMARD installation parameters (to be completed if needed)
-#
-homard_prefix=
-#
-########################################################################
-#  Mesh Adaptation
-#
-if [ ! -z  "${ADAPTATION}" ] ; then
-  if [ "${ADAPTATION}" = "-help" ] ; then
-    ${homard_prefix}/saturne_homard ${ADAPTATION}
-    exit 0
-  else
-    HOMARD_options="  -v"
-    ${homard_prefix}/saturne_homard -Saturne_Script $0 -Donnees_Calcul $CASEDIR \
-                    -Pilotage_Adaptation $ADAPTATION $HOMARD_options || exit 1
-  fi
-fi
-#
-#########################################################################
-#
-N_SYRTHES_COUPLINGS=0
-if [ -f "${SRC}/ussyrc.f90" ] ; then
-  N_SYRTHES_COUPLINGS=`grep -e ^' ' ${SRC}/ussyrc.f90 | grep -i -c defsyr`
-fi
-#
-if [ $N_SYRTHES_COUPLINGS = 0 ] ; then
-  SYRTHES_COUPLING=no
-else
-  SYRTHES_COUPLING=yes
-  export SYRTHES
-  if [ $N_SYRTHES_COUPLINGS -gt 1 ] ; then
-   echo "This script can not handle multiple couplings with SYRTHES"
-   echo "Number of SYRTHES couplings requested: $N_SYRTHES_COUPLINGS"
-  fi
-fi
-#
-if [ $SYRTHES_COUPLING = yes ] ; then
-  if [ $SOLCOM -eq 1 ] ; then
-   echo "SYRTHES coupling is not compatible with SOLCOM-type meshes"
-   exit 1
-  fi
-else
-  COUPLING_MODE=
-fi
-#
-########################################################################
-#
-# Parameters for execution
-#
-# General variables
-THISSCRIPT=$0
-USER=`whoami`
-DATE=`date '+%m%d%H%M'`
-SUFFIX=$DATE
-EXE=cs_solver
-EXE_SYR=syrthes
-#
-# Copy runcase before changing to the working directory
-# (as after that, the relative path will not be up to date).
-#
-cp $0 $RESU/runcase.$SUFFIX
-#
-# Execution directory (reachable by all the processors)
-#
-if [ ! -z "$CS_TMP_PREFIX" ] ; then
-  RUN=${CS_TMP_PREFIX}/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-else
-#  Default if not specified by the user
-#
-#  On the CCRT, there is no TMPDIR. We work by default in SCRATCHDIR
-  if [ "$SCRATCHDIR" != "" ] ; then
-    RUN=$SCRATCHDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-  elif [ "$TMPDIR" != "" -a "$TMPDIR" != "/tmp" ] ; then
-    RUN=$TMPDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-  else
-    RUN=$HOME/tmp_Saturne/$STUDY.$CASE.$DATE
-  fi
-fi
-#
-# Create directory if necessary
-if [ "$RUN" != "$TMPDIR" ] ; then
-  if [ ! -d $RUN ] ; then
-    mkdir -p $RUN || exit 1
-  else
-    echo "RUN=$RUN already exists."
-    echo "The simulation will not be run."
-    exit 1
-  fi
-fi
-#
-# Create a temporary file for Salome (equivalent to "ficstp")
-if [ "$ARG_CS_OUTPUT" = "--log 0" ] ; then
-  echo $RUN > $SCRIPTS/runningstd.$DATE
-else
-  echo $RUN > $SCRIPTS/runningext.$DATE
-fi
-#
-cd $RUN
-#
-########################################################################
-#
-# Set up MPI environment
-#
-# Use makefile query to obtain the path to MPI binaries if those are
-# not on the default path. This is a peculiar use of make, but allows
-# us to avoid defining the MPI configuration in multiple files.
-
-CS_MPI_PATH=/home/saturne/opt/openmpi-1.3.1/arch/Linux_x86_64/bin
-
-# NUMBER_OF_PROCESSORS is determined here if not already set;
-# MPIHOSTS, MPIRUN, MPIBOOT, MPIHALT, and NUMBER_OF_NODES are
-# defined by the sourced script, and PATH may be updated.
-#
-. ${pkgdatadir}/runcase_mpi_env
-#
-# Check for the number of requested processors
-nproc_kernel="${NUMBER_OF_PROCESSORS}"
-echo
-echo
-if [ $SYRTHES_COUPLING = yes ] ; then
-  echo "Coupling of Code_Saturne and SYRTHES activated."
-  #  1 processor is reserved for SYRTHES if coupled through MPI.
-  if [ "$COUPLING_MODE" = "MPI" ] ; then
-    (( nproc_kernel = nproc_kernel - N_SYRTHES_COUPLINGS ))
-    if [ $nproc_kernel -lt 1 ] ; then
-      echo
-      echo
-      echo " Warning, if COUPLING_MODE = MPI, SYRTHES reserves 1 processor"
-      echo " (which need not be a physical processor)."
-      echo " Here, NUMBER_OF_PROCESSORS=${NUMBER_OF_PROCESSORS}, while it must"
-      echo " be strictly greater than 1."
-      echo " Increase the number of requested processors."
-      echo
-      exit 1
-    fi
-  fi
-fi
-if [ $nproc_kernel -gt 1 ] ; then
-  echo "Parallel Code_Saturne with partitioning in $nproc_kernel sub-domains"
-  if [ $SOLCOM = 1 ] ; then
-    echo
-    echo
-    echo " Parallel run impossible with SOLCOM = $SOLCOM "
-    echo " Use SOLCOM = 0 "
-    echo
-    exit 1
-  fi
-else
-  echo "Single processor Code_Saturne simulation"
-fi
-if [ ! -z "$MPIHOSTS" ] ; then
-  echo "Total number of processors: $NUMBER_OF_PROCESSORS"
-fi
-#
-# In parallel mode, the corresponding argument must be set
-if [ $nproc_kernel -gt 1 ] ; then
-  ARG_CS_MPI=" --mpi"
-else
-  ARG_CS_MPI=""
-fi
-#
-#
-########################################################################
-#
-# Communications
-#
-# To help debug coupling problems, make communication more verbose
-if [ ! -z "$ECHO_SYR_COMM" ] ; then
-  ECHOCOMMSYR="-echo-comm $ECHO_SYR_COMM"
-else
-  ECHOCOMMSYR=""
-fi
-########################################################################
-# Greeting message
-#
-echo ' '
-echo '                      Code_Saturne is running '
-echo '                      *********************** '
-echo ' '
-echo ' Working directory (to be periodically cleaned) : '
-echo '    ' $RUN
-#
-########################################################################
-#
-# Compilation and link
-#
-# Note: we also check the for the presence of certain user subroutines here.
-#
-echo
-echo ' Kernel version:          ' $prefix
-echo ' Preprocessor version:    ' $ecs_prefix
-
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  cur_dir=`pwd`
-
-  source_cas=$SRC
-
-  #
-  # Copy of the parameter file
-  if [ ! -z "$PARAM" ] ; then
-    var=$DATA/$PARAM
-    if [ -f $var ] ; then
-      COMMAND_PARAM="--param $PARAM"
-      cp $var .
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The parameters file ' $var
-      echo ' can not be accessed.'
-      exit 1
-    fi
-  fi
-
-  src_files=`ls ${source_cas}/*.[fF]90 ${source_cas}/*.[ch] 2>/dev/null`
-
-  if [ ! -z "${src_files}" ] ; then
-
-    echo
-    echo  "  ***************************************************************"
-    echo  "   Compilation of user subroutines and linking of Code_Saturne"
-    echo  "  ***************************************************************"
-
-    if [ -f compil.log ] ; then
-      rm -f compil.log
-    fi
-
-    src_dir="src_saturne"
-
-    # Copy of the user source files
-    # (no links: the directory is copied later)
-    mkdir ${src_dir}
-    for f in ${src_files} ; do
-      if [ -f $f ] ; then
-        cp ${f} ${src_dir}/
-      fi
-    done
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --source=$src_dir --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    # Compilation
-    if [ ! -z "${CS_LIB_ADD}" ] ; then
-      OPTLIBS="--opt-libs=${CS_LIB_ADD}"
-    fi
-    ${bindir}/cs compile \
-      --source=$src_dir ${OPTLIBS} 2>>$cur_dir/compil.log 1>&2
-    if [ $? -ne 0 ]
-    then
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-      echo "COMPILE OR LINK ERROR"
-      rm -f *.o
-      exit 1
-    else
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-    fi
-
-  else
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    ln -s ${bindir}/$EXE .
-
-  fi
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-
-    ${pkgdatadir}/runcase_syrthes -compile \
-      -cs-bindir=${bindir} -src-syr=${SRC_SYR} \
-      -src-copy=${RESU}/SRC_SYR.${SUFFIX} -log=${RESU}/compil_syrthes.log.${SUFFIX}
-
-  fi
-
-fi # EXEC_KERNEL = yes
-
-#
-########################################################################
-#
-# Data setup
-#
-echo
-echo  "  ********************************************"
-echo  "             Preparing calculation            "
-echo  "  ********************************************"
-echo
-#
-ERROR=false
-PREPROCESS_ERROR=false
-PARTITION_ERROR=false
-EXECUTION_ERROR=false
-#
-if [ $SOLCOM = 1 ]
-then
-  EXEC_PREPROCESS=no
-  EXEC_PARTITION=no
-  ln -s $MESHDIR/$MESH geomet || exit 1
-fi
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ]
-then
-  for var in $MESH ; do
-    ln -s $MESHDIR/$var $var || exit 1
-    # Special case for meshes in EnSight format: link to .geo file necessary
-    # (retrieve name through .case file)
-    var2=`basename $var .case`
-    if [ $var2 != $var ] ; then
-      ficgeo_ensight=`awk '/^model:/ {print $2}' $var`
-      ln -s $MESHDIR/$ficgeo_ensight $ficgeo_ensight || FIN
-    fi
-  done
-else
-  if [ -f ${PREPROCESSOR_OUTPUT_IN} ] ; then
-    ln -s ${PREPROCESSOR_OUTPUT_IN} preprocessor_output || exit 1
-  else
-    echo "Error: no preprocessor output file is available;"
-    echo "       (${PREPROCESSOR_OUTPUT_IN} does not exist."
-    echo "       or is not a standard file."
-    exit 1
-  fi
-fi
-#
-if [ $nproc_kernel -eq 1 -a "${EXEC_KERNEL}" = "yes" ] ; then
-  EXEC_PARTITION=no
-elif [ "${EXEC_PARTITION}" = "no" -a "${PARTITION_OUTPUT_IN}" != "" ]
-then
-  if [ -f ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} ] ; then
-    ln -s ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} .
-  else
-    echo "Warning: no partitioning file is available;"
-    echo "         (no ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel})."
-    echo
-    echo "         Unoptimized partitioning will be used."
-    echo "         Parallel performance may be degraded."
-  fi
-fi
-#
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  for var in ${RESTART_IN}/* ; do
-    if [ -f $var ] ; then
-      varb=`basename $var`
-      if   [ $varb = suiava ] ; then
-        vara=suiamo
-      elif [ $varb = suiavx ] ; then
-        vara=suiamx
-      elif [ $varb = vorava ] ; then
-        vara=voramo
-      elif [ $varb = t1dava ] ; then
-        vara=t1damo
-      elif [ $varb = rayava ] ; then
-        vara=rayamo
-      elif [ $varb = lagava ] ; then
-        vara=lagamo
-      elif [ $varb = lasava ] ; then
-        vara=lasamo
-      else
-        vara=$varb
-      fi
-      ln -s $var $vara
-    fi
-  done
-  #
-  if [ "$THERMOCHEMISTRY_DATA" != "" ] ; then
-    var=$DATA/$THERMOCHEMISTRY_DATA
-    if [ -f $var ] ; then
-      cp $var dp_tch
-      # Copy so as to have correct name upon backup
-      if [ "$THERMOCHEMISTRY_DATA" != "dp_tch" ] ; then
-        cp dp_tch $THERMOCHEMISTRY_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The thermochemistry file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  if [ "$METEO_DATA" != "" ] ; then
-    var=$DATA/$METEO_DATA
-    if [ -f $var ] ; then
-      cp $var meteo
-      # Copy so as to have correct name upon backup
-      if [ "$METEO_DATA" != "meteo" ] ; then
-        cp meteo $METEO_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The meteo profile file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  for f in uscpcl.f90 usd3pc.f90 usebuc.f90 uslwcc.f90 usfucl.f90
-  do
-    if [ -f "${SRC}/${f}" -a ! -f JANAF ] ; then
-      cp ${datadir}/data/thch/JANAF JANAF
-    fi
-  done
-  #
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    #
-    ${pkgdatadir}/runcase_syrthes -copy-data -syrthes-env=${DATA_SYR}/$SYRTHES_ENV
-    #
-  fi
-  #
-  if [ ! -z "$USER_INPUT_FILES" ] ; then
-    for f in $USER_INPUT_FILES ; do
-      cp $DATA/$f .
-    done
-  fi
-  #
-fi # EXEC_KERNEL = yes
-
-########################################################################
-# Maximum time for PBS (done here so as to leave time for PBS to
-# realize that things have started).
-#
-if [ "$PBS_JOBID" != "" ] ; then
-  CS_MAXTIME=`qstat -r $PBS_JOBID | grep $PBS_JOBID | sed -e's/ \{1,\}/ /g' | cut -d ' ' -f 9`
-  export CS_MAXTIME
-fi
-#
-########################################################################
-#
-# Summary: start
-#
-CURDATE=`unset LANG ; date`
-#
-echo '========================================================'>>$summary
-echo '   Start time       : ' $CURDATE                         >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Kernel          : ' $prefix                          >>$summary
-echo '    Preprocessor    : ' $ecs_prefix                      >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    HOMARD          : ' $homard_prefix                   >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    CS_MPI_PATH     : ' $CS_MPI_PATH                     >>$summary
-echo '    PATH            : ' $PATH                            >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    User            : ' $USER                            >>$summary
-echo '========================================================'>>$summary
-echo '    Machine         : '                                  >>$summary
-     uname -a                                                  >>$summary
-if [ -z "$NUMBER_OF_PROCESSORS" ] ; then
-  echo '    N Procs         : ' 1                              >>$summary
-else
-  echo '    N Procs         : ' $NUMBER_OF_PROCESSORS          >>$summary
-fi
-if [ -z "$PROCESSOR_LIST" ] ; then
-  echo '    Processors      : ' default                        >>$summary
-else
-  echo '    Processors      : ' $PROCESSOR_LIST                >>$summary
-fi
-echo '========================================================'>>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Case            : ' $CASE                            >>$summary
-echo '      DATA          : ' $DATA                            >>$summary
-echo '      SRC           : ' $SRC                             >>$summary
-echo '      RESU          : ' $RESU                            >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Exec. dir.      : ' $RUN                             >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-if [ "$EXEC_PREPROCESSOR" = "yes" ] ; then
-  echo '    Preprocessor    : ' ${ecs_bindir}/cs_preprocess    >>$summary
-fi
-if [ "$EXEC_PARTITION" = "yes" ] ; then
-  echo '    Partitioner     : ' ${ecs_bindir}/cs_partition     >>$summary
-fi
-if [ "$EXEC_KERNEL" = "yes" ] ; then
-  echo '    Executable      : ' $EXE                           >>$summary
-fi
-echo '  ----------------------------------------------------'  >>$summary
-#
-# Execution
-echo
-echo  "  ********************************************"
-echo  "             Starting calculation"
-echo  "  ********************************************"
-echo
-#
-# Preprocessor start
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ] ; then
-  #
-  ${ecs_bindir}/cs_preprocess --mesh $MESH "--case" $CASE \
-                   $COMMAND_REORIENT $COMMAND_JOIN $COMMAND_PERIO \
-                   > listpre 2>&1
-  if [ $? != 0 ] ; then
-    echo "Error running the preprocessor."
-    echo "Check preprocessor log (listpre) for details."
-    echo
-    PREPROCESS_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PREPROCESSOR_OUTPUT_OUT=$RESU/preprocessor_output.$SUFFIX
-    cp preprocessor_output ${PREPROCESSOR_OUTPUT_OUT}
-  fi
-  #
-fi
-#
-# Partitioner start
-#
-if [ ! -f ${ecs_bindir}/cs_partition ] ; then
-  echo "Warning: ${ecs_bindir}/cs_partition not found."
-  echo
-  echo "The partitioner may not have been installed"
-  echo "  (this is the case if neither METIS nor."
-  echo "  SCOTCH are avaialable)."
-  echo
-  echo "Unoptimized partitioning will be used, so"
-  echo "parallel performance may be degraded."
-  echo
-  EXEC_PARTITION=no
-fi
-#
-if [ "${EXEC_PARTITION}" = "yes" ] ; then
-  #
-  if [ "${EXEC_KERNEL}" = "yes" ] ; then
-    ${ecs_bindir}/cs_partition $nproc_kernel > listpart 2>&1
-  else
-    if [ -z "$PARTITION_LIST" ] ; then
-      echo "Error running the partitioner."
-      echo "PARTITION_LIST is not set."
-      echo "This variable should contain the number of processors"
-      echo "for which we partition (or a list of such numbers)."
-      PARTITION_ERROR=true
-      ERROR=true
-    else
-      ${ecs_bindir}/cs_partition $PARTITION_LIST > listpart 2>&1
-    fi
-  fi
-  if [ $? != 0 -a $PARTITION_ERROR = false ] ; then
-    echo "Error running the partitioner."
-    echo "Check partitioner log (listpart) for details."
-    echo
-    PARTITION_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PARTITION_OUTPUT_OUT=$RESU/PARTITION_OUTPUT.$SUFFIX
-    mkdir $PARTITION_OUTPUT_OUT
-    cp -r domain_number_* ${PARTITION_OUTPUT_OUT}/
-  fi
-#
-fi
-#
-# Run calculation proper.
-#
-if [ "$ERROR" != "true" -a "$EXEC_KERNEL" = "yes" ] ; then
-#
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    # MPI Communication
-    #
-    # Make sure to transmit possible additional arguments assigned by mpirun to
-    # the executable with some MPI-1 implementations (vanilla MPICH 1.2 sets the
-    # parameters needed by MPI_Init through argc/argv): we use $@ to forward
-    # arguments passed to localexec to the true executable files.
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo "MPI_RANK=\`${pkgdatadir}/runcase_mpi_rank \$@\`" >> $localexec
-    echo cd $RUN >> $localexec
-    echo "if [ \$MPI_RANK -eq 0 ] ; then" >> $localexec
-    echo "  $RUN/$EXE_SYR \$@ -app-num 0 -comm-mpi 1 $ECHOCOMMSYR > listsyr 2>&1" >> $localexec
-    echo "else" >> $localexec
-    echo "  $VALGRIND $RUN/$EXE \$@ --mpi 1 $COMMAND_CWF "\
-         "$ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM " >> $localexec
-    echo "fi" >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    #
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  elif [ $SYRTHES_COUPLING = yes  ] ; then
-    # Socket communications
-    #
-    # We provide the executables with a "random" port number.
-    PORT=35623
-    SOCKETNCS="--syr-socket $PORT"
-    SOCKETSYR="-comm-socket $PORT"
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI $COMMAND_CWF "\
-                 " $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-                 " $COMMAND_PARAM $SOCKETNCS " >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true &
-    #
-    ./$EXE_SYR $ECHOCOMMSYR $SOCKETSYR > listsyr 2>&1
-    #
-    $MPIHALT
-    #
-  elif [ $SOLCOM = 0 ] ; then
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI "\
-         " $COMMAND_CWF $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-         " $COMMAND_PARAM "  >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  else # cas SOLCOM = 1
-    #
-    $VALGRIND $RUN/$EXE --solcom \
-          $ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM \
-          || EXECUTION_ERROR=true
-    #
-  fi
-#
-fi
-#
-# Remove the Salome temporary files
-rm -f $SCRIPTS/running*.$DATE
-#
-########################################################################
-#
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    echo "Error running the coupled calculation."
-    echo "Either the Kernel or SYRTHES may have failed."
-    echo
-    echo "Check Kernel log (listing) and SYRTHES log (listsyr) for details,"
-    echo "as well as eventual error* files."
-    echo
-  else
-    echo "Error running the calculation."
-    echo
-    echo "Check Kernel log (listing) and error* files for details"
-    echo
-  fi
-  ERROR=true
-fi
-#
-# Treatment of the ouput files:
-#   Starts with the restart files
-#   (in case of full disk, increases chances of being able to continue).
-#
-if [ $EXEC_KERNEL = yes ] ; then
-
-  RESTART_OUT=$RESU/RESTART.$SUFFIX
-  iok=1
-  mkdir ${RESTART_OUT} || iok=0
-  if [ $iok = 1 ] ; then
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f ${RESTART_OUT}
-      fi
-    done
-  else
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f $RESU/$f.$SUFFIX
-      fi
-    done
-  fi
-
-  resuser=0
-  for f in ${USER_OUTPUT_FILES} ; do
-    if [ -f $f ] ; then
-      resuser=1
-    fi
-  done
-  if [ ${resuser} = 1 ] ; then
-    RES_USER=$RESU/RES_USER.$SUFFIX
-    iok=1
-    mkdir ${RES_USER} || iok=0
-    if [ $iok = 1 ] ; then
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f ${RES_USER}
-        fi
-      done
-    else
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f $RESU/$f.$SUFFIX
-        fi
-      done
-    fi
-  fi
-
-  for f in $PARAM $THERMOCHEMISTRY_DATA $METEO_DATA ; do
-    if [ -f $f ] ; then
-      cp $f $RESU/$f.$SUFFIX
-    fi
-  done
-
-  for f in probes_*.dat ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-  for f in ush* ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-
-fi  # output files
-
-for f in list* error* *.med *.cgns ; do
-  if [ -f $f ] ; then
-    cp $f $RESU/$f.$SUFFIX
-  fi
-done
-
-# Treatment of EnSight and MED files
-#   The $dir (=*.ensight and/or *.med) directories are copied
-#   to $DIR.$SUFFIX
-
-#   We place directories $dir (=*.ensight and/or *.med)
-#   in $DIR.$SUFFIX
-
-cas=`echo $CASE |tr "[:upper:]" "[:lower:]"`
-
-for dir in *.ensight *.med ; do
-  if [ -d $dir ] ; then
-    DIR=`echo $dir |tr "[:lower:]" "[:upper:]"`
-    mkdir $RESU/$DIR.$SUFFIX
-    if [ $? -ne 0 ] ; then
-      echo Creating $RESU/$DIR.$SUFFIX failed
-    else
-      for f in $dir/*  ; do
-        if [ -f $f ] ; then
-          cp -R ${f} $RESU/$DIR.$SUFFIX/.
-        fi
-      done
-    fi
-  fi
-done
-
-if [ $EXEC_KERNEL = yes ] ; then
-
-  rayt_list=`ls bord* 2>/dev/null`
-  if [ ! -z "${rayt_list}" ] ; then
-    for f in $rayt_list ; do
-      if [ ! -d $RESU/CHR.$SUFFIX ] ; then
-        mkdir $RESU/CHR.$SUFFIX
-      fi
-      cp $f $RESU/CHR.$SUFFIX/.
-    done
-  fi
-
-  lagr_list=`ls debug* deplacement* trajectoire* frontiere* 2>/dev/null`
-  if [ ! -z "${lagr_list}" ] ; then
-    mkdir $RESU/LAGR.$SUFFIX
-    for f in $lagr_list ; do
-      cp $f $RESU/LAGR.$SUFFIX
-    done
-  fi
-
-  # Matisse output files
-  if [ -f ${RUN}/resuMatisse ] ; then
-    matisse=`grep -i matisse $DATA/$PARAM`
-    if [ ! -z "$matisse" ] ; then
-  # The date is added to the first line of resuMatisse
-      AFDATE="Date of the case                                       : "$DATE
-      sed  "1i\ ${AFDATE}" ${RUN}/resuMatisse >> ${RUN}/resuMatisse.mod
-      mv ${RUN}/resuMatisse.mod ${RUN}/resuMatisse
-    fi
-    cp ${RUN}/resuMatisse ${RESU}/resuMatisse.$SUFFIX
-  fi
-
-  for dir in src_saturne ; do
-    if [ -d $dir ] ; then
-      mkdir $RESU/SRC.$SUFFIX
-      if [ $? -ne 0 ] ; then
-        echo Failure creating $RESU/SRC.$SUFFIX
-      else
-        for f in $dir/*.[fF]90 $dir/*.[ch] ; do
-          if [ -f ${f} ] ; then
-            cp -R ${f} $RESU/SRC.$SUFFIX/.
-            fbase=`basename ${f}`
-            chmod a-w $RESU/SRC.$SUFFIX/${fbase}
-          fi
-        done
-      fi
-    fi
-  done
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    ${pkgdatadir}/runcase_syrthes -copy-results \
-      -result-dir=${RESU}/RESU_SYR.${SUFFIX}
-  fi
-
-fi  # input data and outputs
-#
-########################################################################
-#
-# Summary: end
-#
-if  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  EXEC_PREPROCESS="failed"
-fi
-echo "    Preprocessing   : " $EXEC_PREPROCESS                 >>$summary
-if  [ "$PARTITION_ERROR" = "true" ] ; then
-  EXEC_PARTITION="failed"
-fi
-echo "    Partitioning    : " $EXEC_PARTITION                  >>$summary
-if  [ "$EXECUTION_ERROR" = "true" ] ; then
-  EXEC_KERNEL="failed"
-fi
-echo "    Calculation     : " $EXEC_KERNEL                     >>$summary
-#
-CURDATE=`unset LANG ; date`
-#
-echo '  ----------------------------------------------------'  >>$summary
-echo '   Finish time      : ' $CURDATE                         >>$summary
-echo '========================================================'>>$summary
-#
-cp $summary  $RESU/$summary.$SUFFIX
-#
-########################################################################
-#
-#
-# Finish
-#
-echo
-echo  "  ********************************************"
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  echo  "         Error in calculation stage."
-elif  [ "$PARTITION_ERROR" = "true" ] ; then
-  echo  "         Error in partitioning stage."
-elif  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  echo  "         Error in preprocessing stage."
-else
-  echo  "           Normal simulation finish"
-fi
-echo  "  ********************************************"
-
-if [ "$ERROR" = "true" ] ; then
-  exit 1
-else
-  exit 0
-fi
-#
-########################################################################
diff --git a/examples/2-full_domain/case4/usclim.f90 b/examples/2-full_domain/case4/usclim.f90
index aefadd2..075297f 100644
--- a/examples/2-full_domain/case4/usclim.f90
+++ b/examples/2-full_domain/case4/usclim.f90
@@ -1,6 +1,6 @@
 !-------------------------------------------------------------------------------
 
-!                      Code_Saturne version 2.0.0-beta2
+!                      Code_Saturne version 2.0.0-rc1
 !                      --------------------------
 
 !     This file is part of the Code_Saturne Kernel, element of the
@@ -52,37 +52,42 @@ subroutine usclim &
 
 !    User subroutine.
 
-!    Fill boundary conditions arrays (icodcl, rcodcl)
-!    for unknown variables.
+!    Fill boundary conditions arrays (icodcl, rcodcl) for unknown variables.
 
 
 ! Introduction
 ! ============
 
-! Here we define boundary conditions on a per-face basis.
+! Here one defines boundary conditions on a per-face basis.
 
 ! Boundary faces may be identified using the 'getfbr' subroutine.
 
-!  getfbr(string, nelts, eltlst) :
-!  - string is a user-supplied character string containing
-!    selection criteria;
-!  - nelts is set by the subroutine. It is an integer value
-!    corresponding to the number of boundary faces verifying the
-!    selection criteria;
-!  - lstelt is set by the subroutine. It is an integer array of
-!    size nelts containing the list of boundary faces verifying
-!    the selection criteria.
+!  getfbr(string, nelts, eltlst):
+!  - string is a user-supplied character string containing selection criteria;
+!  - nelts is set by the subroutine. It is an integer value corresponding to
+!    the number of boundary faces verifying the selection criteria;
+!  - lstelt is set by the subroutine. It is an integer array of size nelts
+!    containing the list of boundary faces verifying the selection criteria.
 
 !  string may contain:
-!  - references to colors (ex.: 1, 8, 26, ...
+!  - references to colors (ex.: 1, 8, 26, ...)
 !  - references to groups (ex.: inlet, group1, ...)
 !  - geometric criteria (ex. x < 0.1, y >= 0.25, ...)
-!  These criteria may be combined using logical operators
-!  ('and', 'or') and parentheses.
-!  Example: '1 and (group2 or group3) and y < 1' will select boundary
-!  faces of color 1, belonging to groups 'group2' or 'group3' and
-!  with face center coordinate y less than 1.
+!  These criteria may be combined using logical operators ('and', 'or') and
+!  parentheses.
+!  Example: '1 and (group2 or group3) and y < 1' will select boundary faces
+!  of color 1, belonging to groups 'group2' or 'group3' and with face center
+!  coordinate y less than 1.
 
+!  Operators priority, from highest to lowest:
+!    '( )' > 'not' > 'and' > 'or' > 'xor'
+
+! Similarly, interior faces and cells can be identified using the 'getfac'
+! and 'getcel' subroutines (respectively). Their syntax are identical to
+! 'getfbr' syntax.
+
+! For a more thorough description of the criteria syntax, it can be referred
+! to the user guide.
 
 
 ! Boundary condition types
@@ -94,12 +99,11 @@ subroutine usclim &
 !    For "standard" boundary conditions:
 !    -----------------------------------
 
-!     (inlet, free outlet, wall, symmetry), we define a code
-!     in the 'itypfb' array (of dimensions number of boundary faces,
-!     number of phases). This code will then be used by a non-user
-!     subroutine to assign the following conditions (scalars in
-!     particular will receive the conditions of the phase to which
-!     they are assigned). Thus:
+!     (inlet, free outlet, wall, symmetry), one defines a code in the 'itypfb'
+!     array (of dimensions number of boundary faces, number of phases).
+!     This code will then be used by a non-user subroutine to assign the
+!     following conditions (scalars in particular will receive the conditions
+!     of the phase to which they are assigned). Thus:
 
 !     Code      |  Boundary type
 !     --------------------------
@@ -109,22 +113,20 @@ subroutine usclim &
 !      iparoi   |   Wall (smooth)
 !      iparug   |   Rough wall
 
-!     Integers ientre, isolib, isymet, iparoi, iparug
-!     are defined elsewhere (param.h). Their value is greater than
-!     or equal to 1 and less than or equal to ntypmx
-!     (value fixed in paramx.h)
+!     These integers are defined elsewhere (in paramx.h header).
+!     Their value is greater than or equal to 1 and less than or  equal to
+!     ntypmx (value fixed in paramx.h)
 
 
 !     In addition, some values must be defined:
 
 
-!     - Inlet (more precisely, inlet/outlet with prescribed flow, as
-!              the flow may be prescribed as an outflow):
+!     - Inlet (more precisely, inlet/outlet with prescribed flow, as the flow
+!              may be prescribed as an outflow):
 
-!       -> Dirichlet conditions on variables
-!         other than pressure are mandatory if the flow is incoming,
-!         optional if the flow is outgoing (the code assigns 0 flux
-!         if no Dirichlet is specified); thus,
+!       -> Dirichlet conditions on variables other than pressure are mandatory
+!         if the flow is incoming, optional if the flow is outgoing (the code
+!         assigns zero flux if no Dirichlet is specified); thus,
 !         at face 'ifac', for the variable 'ivar': rcodcl(ifac, ivar, 1)
 
 
@@ -134,17 +136,15 @@ subroutine usclim &
 !         at face ifac, rcodcl(ifac, iu, 1)
 !                       rcodcl(ifac, iv, 1)
 !                       rcodcl(ifac, iw, 1)
-!       -> Specific code and prescribed temperature value
-!         at wall, if applicable:
+!       -> Specific code and prescribed temperature value at wall if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 5
 !                       rcodcl(ifac, ivar, 1) = prescribed temperature
-!       -> Specific code and prescribed flux value
-!         at wall, if applicable:
+!       -> Specific code and prescribed flux value at wall if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 3
 !                       rcodcl(ifac, ivar, 3) = prescribed flux
-!                                        =
-!        Note that the default condition for scalars
-!         (other than k and epsilon) is homogeneous Neumann.
+
+!        Note that the default condition for scalars (other than k and epsilon)
+!        is homogeneous Neumann.
 
 
 !     - Rough wall: (= impermeable solid, with rough friction)
@@ -154,62 +154,60 @@ subroutine usclim &
 !                       rcodcl(ifac, iv, 1)
 !                       rcodcl(ifac, iw, 1)
 !       -> Value of the dynamic roughness height to specify in
-!                       rcodcl(ifac, iu, 3) (value for iv et iw not used)
-!       -> Specific code and prescribed temperature value
-!         at rough wall, if applicable:
+!                       rcodcl(ifac, iu, 3)
+!       -> Value of the scalar roughness height (if required) to specify in
+!                       rcodcl(ifac, iv, 3) (values for iw are not used)
+!       -> Specific code and prescribed temperature value at wall if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 6
 !                       rcodcl(ifac, ivar, 1) = prescribed temperature
-!                       rcodcl(ifac, ivar, 3) = dynamic roughness height
-!       -> Specific code and prescribed flux value
-!         at rough wall, if applicable:
+!       -> Specific code and prescribed flux value at rough wall, if applicable:
 !         at face ifac, icodcl(ifac, ivar)    = 3
 !                       rcodcl(ifac, ivar, 3) = prescribed flux
-!                                        =
-!        Note that the default condition for scalars
-!         (other than k and epsilon) is homogeneous Neumann.
 
-!     - Symmetry (= impermeable frictionless wall):
+!        Note that the default condition for scalars (other than k and epsilon)
+!        is homogeneous Neumann.
+
+!     - Symmetry (= slip wall):
 
 !       -> Nothing to specify
 
 
 !     - Free outlet (more precisely free inlet/outlet with prescribed pressure)
 
-!       -> Nothing to prescribe for pressure and velocity
-!          For scalars and turbulent values, a Dirichlet value may optionally
-!            be specified. The behavior is as follows:
+!       -> Nothing to prescribe for pressure and velocity. For scalars and
+!          turbulent values, a Dirichlet value may optionally be specified.
+!          The behavior is as follows:
 !              * pressure is always handled as a Dirichlet condition
 !              * if the mass flow is inflowing:
-!                  we retain the velocity at infinity
+!                  one retains the velocity at infinity
 !                  Dirichlet condition for scalars and turbulent values
-!                    (or zero flux if the user has not specified a
+!                   (or zero flux if the user has not specified a
 !                    Dirichlet value)
 !                if the mass flow is outflowing:
-!                  we prescribe zero flux on the velocity, the scalars,
+!                  one prescribes zero flux on the velocity, the scalars,
 !                  and turbulent values
 
-!       Note that the pressure will be reset to P0
-!           on the first free outlet face found
+!       Note that the pressure will be reset to p0 on the first free outlet
+!       face found
 
 
 !    For "non-standard" conditions:
 !    ------------------------------
 
-!     Other than (inlet, free outlet, wall, symmetry), we define
+!     Other than (inlet, free outlet, wall, symmetry), one defines
 !      - on one hand, for each face:
-!        -> an admissible 'itypfb' value
-!           (i.e. greater than or equal to 1 and less than or equal to
-!            ntypmx; see its value in paramx.h).
+!        -> an admissible 'itypfb' value (i.e. greater than or equal to 1 and
+!           less than or equal to ntypmx; see its value in paramx.h).
 !           The values predefined in paramx.h:
-!           'ientre', 'isolib', 'isymet', 'iparoi', 'iparug' are in
-!           this range, and it is preferable not to assign one of these
-!           integers to 'itypfb' randomly or in an inconsiderate manner.
-!           To avoid this, we may use 'iindef' if we wish to avoid
-!           checking values in paramx.h. 'iindef' is an admissible
-!           value to which no predefined boundary condition is attached.
-!           Note that the 'itypfb' array is reinitialized at each time
-!           step to the non-admissible value of 0. If we forget to
-!           modify 'typfb' for a given face, the code will stop.
+!           'ientre', 'isolib', 'isymet', 'iparoi', 'iparug' are in this range,
+!           and it is preferable not to assign one of these integers to 'itypfb'
+!           randomly or in an inconsiderate manner. To avoid this, one may use
+!           'iindef' if one wish to avoid checking values in paramx.h. 'iindef'
+!           is an admissible value to which no predefined boundary condition
+!           is attached.
+!           Note that the 'itypfb' array is reinitialized at each time step to
+!           the non-admissible value of 0. If one forgets to modify 'typfb' for
+!           a given face, the code will stop.
 
 !      - and on the other hand, for each face and each variable:
 !        -> a code             icodcl(ifac, ivar)
@@ -219,15 +217,15 @@ subroutine usclim &
 !     The value of 'icodcl' is taken from the following:
 !       1: Dirichlet      (usable for any variable)
 !       3: Neumann        (usable for any variable)
-!       4: Symmetry       (usable only for the velocity and
-!                          components of the Rij tensor)
+!       4: Symmetry       (usable only for the velocity and components of
+!                          the Rij tensor)
 !       5: Smooth wall    (usable for any variable except for pressure)
 !       6: Rough wall     (usable for any variable except for pressure)
 !       9: Free outlet    (usable only for velocity)
-!     The values of the 3 'rcodcl' components are
+!     The values of the 3 'rcodcl' components are:
 !      rcodcl(ifac, ivar, 1):
 !         Dirichlet for the variable          if icodcl(ifac, ivar) =  1
-!         wall value (sliding velocity, temp) if icodcl(ifac, ivar) =  5
+!         Wall value (sliding velocity, temp) if icodcl(ifac, ivar) =  5
 !         The dimension of rcodcl(ifac, ivar, 1) is that of the
 !           resolved variable: ex U (velocity in m/s),
 !                                 T (temperature in degrees)
@@ -251,120 +249,107 @@ subroutine usclim &
 !
 !      rcodcl(ifac, ivar, 3) if icodcl(ifac, ivar) <> 6:
 !        Flux density (< 0 if gain, n outwards-facing normal)
-!                         if icodcl(ifac, ivar)= 3
+!                            if icodcl(ifac, ivar)= 3
 !         For velocities U,                in kg/(m s2) = J:
 !           rcodcl(ifac, ivar, 3) =         -(viscl+visct) * (grad U).n
-!         For pressure P,                  en kg/(m2 s):
+!         For pressure P,                  in kg/(m2 s):
 !           rcodcl(ifac, ivar, 3) =                    -dt * (grad P).n
 !         For temperatures T,              in Watt/m2:
 !           rcodcl(ifac, ivar, 3) = -Cp*(viscls+visct/sigmas) * (grad T).n
 !         For enthalpies H,                in Watt/m2:
 !           rcodcl(ifac, ivar, 3) = -(viscls+visct/sigmas) * (grad H).n
-!         For other scalars F in :
+!         For other scalars F              in:
 !           rcodcl(ifac, ivar, 3) = -(viscls+visct/sigmas) * (grad F).n
 
 !      rcodcl(ifac, ivar, 3) if icodcl(ifac, ivar) = 6:
 !        Roughness for the rough wall law
 !         For velocities U, dynamic roughness
-!           rcodcl(ifac, ivar, 3) = rugd
+!           rcodcl(ifac, iu, 3) = roughd
 !         For other scalars, thermal roughness
-!           rcodcl(ifac, ivar, 3) = rugt
+!           rcodcl(ifac, iv, 3) = rought
 
 
-!      Note that if the user assigns a value to itypfb equal to
-!       ientre, isolib, isymet, iparoi, or iparug
-!       and does not modify icodcl (zero value by default),
-!       itypfb will define the boundary condition type.
+!      Note that if the user assigns a value to itypfb equal to ientre, isolib,
+!       isymet, iparoi, or iparug and does not modify icodcl (zero value by
+!       default), itypfb will define the boundary condition type.
 
-!      To the contrary, if the user prescribes
-!        icodcl(ifac, ivar) (nonzero),
-!        the values assigned to rcodcl will be used for the considered
-!        face and variable (if rcodcl values are not set, the default
-!        values will be used for the face and variable, so:
+!      To the contrary, if the user prescribes icodcl(ifac, ivar) (nonzero),
+!        the values assigned to rcodcl will be used for the considered face
+!        and variable (if rcodcl values are not set, the default values will
+!        be used for the face and variable, so:
 !                                 rcodcl(ifac, ivar, 1) = 0.d0
 !                                 rcodcl(ifac, ivar, 2) = rinfin
 !                                 rcodcl(ifac, ivar, 3) = 0.d0)
-!        Especially, we may have for example:
-!        -> set itypfb(ifac, iphas) = iparoi
-!        which prescribes default wall conditions for all variables at
-!        face ifac,
-!        -> and define IN ADDITION for variable ivar on this face
-!        specific conditions by specifying
-!        icodcl(ifac, ivar) and the 3 rcodcl values.
-
-
-!      The user may also assign to itypfb a value not equal to
-!       ientre, isolib, isymet, iparoi, iparug, iindef
-!       but greater than or equal to 1 and less than or equal to
-!       ntypmx (see values in param.h) to distinguish
-!       groups or colors in other subroutines which are specific
-!       to the case and in which itypfb is accessible.
-!       In this case though it will be necessary to
-!       prescribe boundary conditions by assigning values to
-!       icodcl and to the 3 rcodcl fields (as the value of itypfb
-!       will not be predefined in the code).
+!        Especially, one may have for example:
+!        -> set itypfb(ifac, iphas) = iparoi which prescribes default wall
+!        conditions for all variables at face ifac,
+!        -> and define IN ADDITION for variable ivar on this face specific
+!        conditions by specifying icodcl(ifac, ivar) and the 3 rcodcl values.
+
+
+!      The user may also assign to itypfb a value not equal to ientre, isolib,
+!       isymet, iparoi, iparug, iindef but greater than or equal to 1 and less
+!       than or equal to ntypmx (see values in param.h) to distinguish groups
+!       or colors in other subroutines which are specific to the case and in
+!       which itypfb is accessible.  In this case though it will be necessary
+!       to prescribe boundary conditions by assigning values to icodcl and to
+!       the 3 rcodcl fields (as the value of itypfb will not be predefined in
+!       the code).
 
 
 ! Consistency rules
 ! =================
 
-!       A few consistency rules between 'icodcl' codes for
-!         variables with non-standard boundary conditions:
+!       A few consistency rules between 'icodcl' codes for variables with
+!       non-standard boundary conditions:
 
 !           Codes for velocity components must be identical
 !           Codes for Rij components must be identical
 !           If code (velocity or Rij) = 4
-!             we must have code (velocity and Rij) = 4
+!             one must have code (velocity and Rij) = 4
 !           If code (velocity or turbulence) = 5
-!             we must have code (velocity and turbulence) = 5
+!             one must have code (velocity and turbulence) = 5
 !           If code (velocity or turbulence) = 6
-!             we must have code (velocity and turbulence) = 6
+!             one must have code (velocity and turbulence) = 6
 !           If scalar code (except pressure or fluctuations) = 5
-!             we must have velocity code = 5
+!             one must have velocity code = 5
 !           If scalar code (except pressure or fluctuations) = 6
-!             we must have velocity code = 6
+!             one must have velocity code = 6
 
 
 ! Remarks
 ! =======
 
-!       Caution: to prescribe a flux (nonzero) to Rij,
-!                the viscosity to take into account is viscl
-!                even if visct exists (visct=rho cmu k2/epsilon)
+!       Caution: to prescribe a flux (nonzero) to Rij, the viscosity to take
+!                into account is viscl even if visct exists
+!                (visct=rho cmu k2/epsilon)
 
-!       We have the ordering array for boundary faces from the
-!           previous time step (except for the fist time step,
-!           where 'itrifb' has not been set yet).
-!       The array of boundary face types 'itypfb' has been
-!           reset before entering the subroutine.
+!       One have the ordering array for boundary faces from the previous time
+!         step (except for the fist one, where 'itrifb' has not been set yet).
+!       The array of boundary face types 'itypfb' has been reset before
+!         entering the subroutine.
 
 
-!       Note how to access some variables:
+!       Note how to access some variables (for phase    'iphas'
+!                                              variable 'ivar'
+!                                              scalar   'iscal'):
 
-! Cell values
-!               Let         iel = ifabor(ifac)
+! Cell values  (let iel = ifabor(ifac))
 
-! * Density                         phase iphas, cell iel:
-!                  propce(iel, ipproc(irom(iphas)))
-! * Dynamic molecular viscosity     phase iphas, cell iel:
-!                  propce(iel, ipproc(iviscl(iphas)))
-! * Turbulent viscosity   dynamique phase iphas, cell iel:
-!                  propce(iel, ipproc(ivisct(iphas)))
-! * Specific heat                   phase iphas, cell iel:
-!                  propce(iel, ipproc(icp(iphasl))
-! * Diffusivity: lambda          scalaire iscal, cell iel:
-!                  propce(iel, ipproc(ivisls(iscal)))
+! * Density:                                 propce(iel, ipproc(irom(iphas)))
+! * Dynamic molecular viscosity:             propce(iel, ipproc(iviscl(iphas)))
+! * Turbulent viscosity:                     propce(iel, ipproc(ivisct(iphas)))
+! * Specific heat:                           propce(iel, ipproc(icp(iphas))
+! * Diffusivity(lambda):                     propce(iel, ipproc(ivisls(iscal)))
 
 ! Boundary face values
 
-! * Density                        phase iphas, boundary face ifac :
-!                  propfb(ifac, ipprob(irom(iphas)))
-! * Mass flow relative to variable ivar, boundary face ifac:
-!      (i.e. the mass flow used for convecting ivar)
-!                  propfb(ifac, pprob(ifluma(ivar )))
-! * For other values                  at boundary face ifac:
-!      take as an approximation the value in the adjacent cell iel
-!      i.e. as above with iel = ifabor(ifac).
+! * Density:                                 propfb(ifac, ipprob(irom(iphas)))
+! * Mass flux (for convecting 'ivar'):       propfb(ifac, ipprob(ifluma(ivar)))
+
+! * For other values: take as an approximation the value in the adjacent cell
+!                     i.e. as above with iel = ifabor(ifac).
+
 
 !-------------------------------------------------------------------------------
 ! Arguments
@@ -395,12 +380,12 @@ subroutine usclim &
 ! ifmcel(ncelet)   ! ia ! <-- ! cell family numbers                            !
 ! iprfml           ! ia ! <-- ! property numbers per family                    !
 !  (nfml, nprfml)  !    !     !                                                !
-! maxelt           !  e ! <-- ! max number of cells and faces (int/boundary)   !
+! maxelt           ! i  ! <-- ! max number of cells and faces (int/boundary)   !
 ! lstelt(maxelt)   ! ia ! --- ! work array                                     !
 ! ipnfac(nfac+1)   ! ia ! <-- ! interior faces -> vertices index (optional)    !
 ! nodfac(lndfac)   ! ia ! <-- ! interior faces -> vertices list (optional)     !
 ! ipnfbr(nfabor+1) ! ia ! <-- ! boundary faces -> vertices index (optional)    !
-! nodfac(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
+! nodfbr(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
 ! icodcl           ! ia ! --> ! boundary condition code                        !
 !  (nfabor, nvar)  !    !     ! = 1  -> Dirichlet                              !
 !                  !    !     ! = 2  -> flux density                           !
@@ -409,19 +394,19 @@ subroutine usclim &
 !                  !    !     ! = 6  -> roughness and u.n=0 (velocity)         !
 !                  !    !     ! = 9  -> free inlet/outlet (velocity)           !
 !                  !    !     !         inflowing possibly blocked             !
-! itrifb(nfabor    ! ia ! <-- ! indirection for boundary faces ordering)       !
+! itrifb           ! ia ! <-- ! indirection for boundary faces ordering        !
 !  (nfabor, nphas) !    !     !                                                !
 ! itypfb           ! ia ! --> ! boundary face types                            !
 !  (nfabor, nphas) !    !     !                                                !
-! idevel(nideve)   ! ia ! <-- ! integer work array for temporary developpement !
-! ituser(nituse    ! ia ! <-- ! user-reserved integer work array               !
+! idevel(nideve)   ! ia ! <-> ! integer work array for temporary development   !
+! ituser(nituse)   ! ia ! <-> ! user-reserved integer work array               !
 ! ia(*)            ! ia ! --- ! main integer work array                        !
 ! xyzcen           ! ra ! <-- ! cell centers                                   !
 !  (ndim, ncelet)  !    !     !                                                !
 ! surfac           ! ra ! <-- ! interior faces surface vectors                 !
 !  (ndim, nfac)    !    !     !                                                !
 ! surfbo           ! ra ! <-- ! boundary faces surface vectors                 !
-!  (ndim, nfavor)  !    !     !                                                !
+!  (ndim, nfabor)  !    !     !                                                !
 ! cdgfac           ! ra ! <-- ! interior faces centers of gravity              !
 !  (ndim, nfac)    !    !     !                                                !
 ! cdgfbo           ! ra ! <-- ! boundary faces centers of gravity              !
@@ -431,14 +416,14 @@ subroutine usclim &
 ! volume(ncelet)   ! ra ! <-- ! cell volumes                                   !
 ! dt(ncelet)       ! ra ! <-- ! time step (per cell)                           !
 ! rtp, rtpa        ! ra ! <-- ! calculated variables at cell centers           !
-!  (ncelet, *)     !    !     !  (at current and preceding time steps)         !
+!  (ncelet, *)     !    !     !  (at current and previous time steps)          !
 ! propce(ncelet, *)! ra ! <-- ! physical properties at cell centers            !
 ! propfa(nfac, *)  ! ra ! <-- ! physical properties at interior face centers   !
 ! propfb(nfabor, *)! ra ! <-- ! physical properties at boundary face centers   !
 ! coefa, coefb     ! ra ! <-- ! boundary conditions                            !
 !  (nfabor, *)     !    !     !                                                !
 ! rcodcl           ! ra ! --> ! boundary condition values                      !
-!                  !    !     ! rcodcl(1) = Dirichlet value                    !
+!  (nfabor,nvar,3) !    !     ! rcodcl(1) = Dirichlet value                    !
 !                  !    !     ! rcodcl(2) = exterior exchange coefficient      !
 !                  !    !     !  (infinite if no exchange)                     !
 !                  !    !     ! rcodcl(3) = flux density value                 !
@@ -449,11 +434,10 @@ subroutine usclim &
 !                  !    !     ! for scalars    cp*(viscls+visct/sigmas)*gradt  !
 ! w1,2,3,4,5,6     ! ra ! --- ! work arrays                                    !
 !  (ncelet)        !    !     !  (computation of pressure gradient)            !
-! coefu            ! ra ! --- ! tab de trav                                    !
+! coefu            ! ra ! --- ! work array                                     !
 !  (nfabor, 3)     !    !     !  (computation of pressure gradient)            !
-! rdevel(nrdeve)   ! ra ! <-> ! tab reel complementaire developemt             !
-! rdevel(nideve)   ! ra ! <-- ! real work array for temporary developpement    !
-! rtuser(nituse    ! ra ! <-- ! user-reserved real work array                  !
+! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
+! rtuser(nrtuse)   ! ra ! <-> ! user-reserved real work array                  !
 ! ra(*)            ! ra ! --- ! main real work array                           !
 !__________________!____!_____!________________________________________________!
 
@@ -515,8 +499,8 @@ double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
 
 ! Local variables
 
-integer          idebia, idebra
-integer          ifac, ielt, ii, ivar, iphas
+integer          idebia, idebra, ielt
+integer          ifac, iel, ii, ivar, iphas
 integer          ilelt, nlelt
 double precision uref2, d2s3
 double precision rhomoy, dh, ustar2
@@ -538,26 +522,20 @@ d2s3 = 2.d0/3.d0
 !===============================================================================
 ! 2.  Assign boundary conditions to boundary faces here
 
-!     We may use selection criteria to filter boundary case subsets
+!     One may use selection criteria to filter boundary case subsets
 !       Loop on faces from a subset
 !         Set the boundary condition for each face
 !===============================================================================
 
-! --- Most types and values have been set using the GUI.
-
-! --- Set inlet values
-
-! Inlet type has already been assigned to boundary faces of color 1
-! through the GUI with a default velocity, but a time-varying value
-! is prescribed here and overrides the one given through the GUI.
-
+! --- For boundary faces of color 2 and x <= 0.01,
+!     assign an inlet for all phases
 call getfbr('1', nlelt, lstelt)
 !==========
 
-if (ttcabs .lt. 3.8d0) then
+if (ttcabs.lt.3.8d0) then
   do ielt = 1, nlelt
     ifac = lstelt(ielt)
-    rcodcl(ifac,isca(1),1) = 20.d0+100.d0*ttcabs
+    rcodcl(ifac,isca(1),1) = 20.d0 + 100.d0*ttcabs
   enddo
 else
   do ielt = 1, nlelt
diff --git a/examples/2-full_domain/case4/uskpdc.f90 b/examples/2-full_domain/case4/uskpdc.f90
deleted file mode 100644
index fc4a4c4..0000000
--- a/examples/2-full_domain/case4/uskpdc.f90
+++ /dev/null
@@ -1,409 +0,0 @@
-!-------------------------------------------------------------------------------
-
-!                      Code_Saturne version 2.0.0-beta2
-!                      --------------------------
-
-!     This file is part of the Code_Saturne Kernel, element of the
-!     Code_Saturne CFD tool.
-
-!     Copyright (C) 1998-2008 EDF S.A., France
-
-!     contact: saturne-support at edf.fr
-
-!     The Code_Saturne Kernel is free software; you can redistribute it
-!     and/or modify it under the terms of the GNU General Public License
-!     as published by the Free Software Foundation; either version 2 of
-!     the License, or (at your option) any later version.
-
-!     The Code_Saturne Kernel 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 General Public License for more details.
-
-!     You should have received a copy of the GNU General Public License
-!     along with the Code_Saturne Kernel; if not, write to the
-!     Free Software Foundation, Inc.,
-!     51 Franklin St, Fifth Floor,
-!     Boston, MA  02110-1301  USA
-
-!-------------------------------------------------------------------------------
-
-subroutine uskpdc &
-!================
-
- ( idbia0 , idbra0 ,                                              &
-   ndim   , ncelet , ncel   , nfac   , nfabor , nfml   , nprfml , &
-   nnod   , lndfac , lndfbr , ncelbr ,                            &
-   nvar   , nscal  , nphas  ,                                     &
-   nideve , nrdeve , nituse , nrtuse ,                            &
-   ncepdp , iphas  , iappel ,                                     &
-   ifacel , ifabor , ifmfbr , ifmcel , iprfml , maxelt , lstelt , &
-   ipnfac , nodfac , ipnfbr , nodfbr , icepdc ,                   &
-   idevel , ituser , ia     ,                                     &
-   xyzcen , surfac , surfbo , cdgfac , cdgfbo , xyznod , volume , &
-   dt     , rtpa   , rtp    , propce , propfa , propfb ,          &
-   coefa  , coefb  , ckupdc ,                                     &
-   rdevel , rtuser , ra     )
-
-!===============================================================================
-! FONCTION :
-! ----------
-
-!                    PERTES DE CHARGE (PDC)
-!                       POUR LA PHASE IPHAS
-
-! IAPPEL = 1 :
-!             CALCUL DU NOMBRE DE CELLULES OU L'ON IMPOSE UNE PDC
-! IAPPEL = 2 :
-!             REPERAGE DES CELLULES OU L'ON IMPOSE UNE PDC
-! IAPPEL = 3 :
-!             CALCUL DES VALEURS DES COEFS DE PDC
-
-
-! CKUPDC EST LE COEFF DE PDC CALCULE.
-
-!  IL INTERVIENT DANS LA QDM COMME SUIT :
-!    RHO DU/DT = - GRAD P + TSPDC        (+ AUTRES TERMES)
-!                      AVEC TSPDC = - RHO CKUPDC U ( en kg/(m2 s))
-
-
-!  POUR UNE PDC REPARTIE,
-
-!    SOIT KSIL = DHL/(0.5 RHO U**2) DONNE DANS LA LITTERATURE
-!    (DHL EST LA PERTE DE CHARGE PAR UNITE DE LONGUEUR)
-
-!    LE TERME SOURCE TSPDC VAUT DHL = - KSIL *(0.5 RHO U**2)
-
-!    ON A CKUPDC = 0.5 KSIL ABS(U)
-
-
-!  POUR UNE PDC SINGULIERE,
-
-!    SOIT KSIS = DHS/(0.5 RHO U**2) DONNE DANS LA LITTERATURE
-!    (DHS EST LA PERTE DE CHARGE SINGULIERE)
-
-!    LE TERME SOURCE TSPDC VAUT DHS/L = - KSIS/L *(0.5 RHO U**2)
-
-!    ON A CKUPDC = 0.5 KSIS/L ABS(U)
-
-!    OU L DESIGNE LA LONGUEUR SUR LAQUELLE
-!           ON A CHOISI DE REPRESENTER LA ZONE DE PDC SINGULIERE
-
-
-! IDENTIFICATION DES CELLULES/FACES DE BORD/FACES INTERNES
-! ========================================================
-
-!  Les commandes GETCEL, GETFBR et GETFAC permettent d'identifier
-!  respectivement les cellules, faces ou faces de bord en fonction
-!  de differents criteres.
-
-!  GETCEL(CHAINE,NLELT,LSTELT) :
-!  - CHAINE est une chaine de caractere fournie par l'utilisateur
-!    qui donne les criteres de selection
-!  - NLTELT est renvoye par la commande. C'est un entier qui
-!    correspond au nombre de cellules trouveees repondant au
-!    critere
-!  - LSTELT est renvoye par la commande. C'est un tableau d'entiers
-!    de taille NLTELT donnant la liste des cellules trouvees
-!    repondant au critere.
-
-!  CHAINE peut etre constitue de :
-!  - references de couleurs (ex. : 1, 8, 26, ...
-!  - references de groupes (ex. : entrees, groupe1, ...)
-!  - criteres geometriques (ex. X<0.1, Y>=0.25, ...)
-!  Ces criteres peuvent etre combines par des operateurs logiques
-!  (AND et OR) et des parentheses
-!  ex. : '1 AND (groupe2 OR groupe3) AND Y<1' permettra de recuperer
-!  les cellules de couleur 1, appartenant aux groupes 'groupe2'
-!  ou 'groupe3' et de coordonnee Y inferieure a 1.
-
-!  La syntaxe des commandes GETFBR et GETFAC est identique.
-
-
-!-------------------------------------------------------------------------------
-!ARGU                             ARGUMENTS
-!__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
-!__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! ncelbr           ! e  ! <-- ! nombre d'elements ayant au moins une           !
-!                  !    !     ! face de bord                                   !
-! nvar             ! e  ! <-- ! nombre total de variables                      !
-! nscal            ! e  ! <-- ! nombre total de scalaires                      !
-! nphas            ! e  ! <-- ! nombre de phases                               !
-! ncepdp           ! e  ! <-- ! nombre de cellules avec pdc                    !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! iappel           ! e  ! <-- ! indique les donnes a renvoyer                  !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! nfml  ,nprfml    !    !     !                                                !
-! maxelt           !  e ! <-- ! nb max d'elements (cell,fac,fbr)               !
-! lstelt(maxelt) te ! --- ! tableau de travail                             !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfac)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (nfac+1)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfbr)       !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (nfabor+1)     !    !     !  (optionnel)                                   !
-! icepdc(ncepdp    ! te ! <-- ! numero des ncepdp cellules avec pdc            !
-! idevel(nideve    ! te ! <-- ! tab entier complementaire developemt           !
-! ituser(nituse    ! te ! <-- ! tab entier complementaire utilisateur          !
-! ia(*)            ! tr ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet          !    !     !                                                !
-! dt(ncelet)       ! tr ! <-- ! pas de temps                                   !
-! rtp, rtpa        ! tr ! <-- ! variables de calcul au centre des              !
-! (ncelet,*)       !    !     !    cellules (instant courant ou prec)          !
-! propce           ! tr ! <-- ! proprietes physiques au centre des             !
-! (ncelet,*)       !    !     !    cellules                                    !
-! propfa           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfac,*)        !    !     !    faces internes                              !
-! propfb           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! coefa, coefb     ! tr ! <-- ! conditions aux limites aux                     !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! ckupdc           ! tr ! <-- ! tableau de travail pour pdc                    !
-!  (ncepdp,6)      !    !     !                                                !
-! rdevel(nrdeve    ! tr ! <-- ! tab reel complementaire developemt             !
-! rtuser(nrtuse    ! tr ! <-- ! tab reel complementaire utilisateur            !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
-!__________________!____!_____!________________________________________________!
-
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
-
-!===============================================================================
-
-implicit none
-
-!===============================================================================
-!     DONNEES EN COMMON
-!===============================================================================
-
-include "paramx.h"
-include "pointe.h"
-include "numvar.h"
-include "optcal.h"
-include "cstnum.h"
-include "parall.h"
-include "period.h"
-
-!===============================================================================
-
-! Arguments
-
-integer          idbia0 , idbra0
-integer          ndim   , ncelet , ncel   , nfac   , nfabor
-integer          nfml   , nprfml
-integer          nnod   , lndfac , lndfbr , ncelbr
-integer          nvar   , nscal  , nphas
-integer          ncepdp
-integer          nideve , nrdeve , nituse , nrtuse
-integer          iappel
-
-integer          ifacel(2,nfac) , ifabor(nfabor)
-integer          ifmfbr(nfabor) , ifmcel(ncelet)
-integer          iprfml(nfml,nprfml)
-integer          maxelt, lstelt(maxelt)
-integer          ipnfac(nfac+1), nodfac(lndfac)
-integer          ipnfbr(nfabor+1), nodfbr(lndfbr)
-integer          icepdc(ncepdp)
-integer          idevel(nideve), ituser(nituse), ia(*)
-
-double precision xyzcen(ndim,ncelet)
-double precision surfac(ndim,nfac), surfbo(ndim,nfabor)
-double precision cdgfac(ndim,nfac), cdgfbo(ndim,nfabor)
-double precision xyznod(ndim,nnod), volume(ncelet)
-double precision dt(ncelet), rtp(ncelet,*), rtpa(ncelet,*)
-double precision propce(ncelet,*)
-double precision propfa(nfac,*), propfb(nfabor,*)
-double precision coefa(nfabor,*), coefb(nfabor,*)
-double precision ckupdc(ncepdp,6)
-double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
-
-! VARIABLES LOCALES
-
-integer          idebia, idebra
-integer          iel, ielpdc, iphas, ikpdc
-integer          ilelt, nlelt
-
-double precision alpha, cosalp, sinalp, vit1, vit2, ck1, ck2
-
-!===============================================================================
-
-idebia = idbia0
-idebra = idbra0
-
-if(iappel.eq.1.or.iappel.eq.2) then
-
-!===============================================================================
-
-! 1. POUR CHAQUE PHASE : UN OU DEUX APPELS
-
-!      PREMIER APPEL :
-
-!        IAPPEL = 1 : NCEPDP : CALCUL DU NOMBRE DE CELLULES
-!                                AVEC PERTES DE CHARGE
-
-
-!      DEUXIEME APPEL (POUR LES PHASES AVEC NCEPDP > 0) :
-
-!        IAPPEL = 2 : ICEPDC : REPERAGE DU NUMERO DES CELLULES
-!                                AVEC PERTES DE CHARGE
-
-! REMARQUES :
-
-!        Ne pas utiliser CKUPDC dans cette section
-!          (il est rempli au troisieme appel, IAPPEL = 3)
-
-!        Ne pas utiliser ICEPDC dans cette section
-!           au premier appel (IAPPEL = 1)
-
-!        On passe ici a chaque pas de temps
-!           (ATTENTION au cout calcul de vos developpements)
-
-!===============================================================================
-
-
-!  1.1 A completer par l'utilisateur : selection des cellules
-!  -----------------------------------------------------------
-
-! --- Exemple 1 : Aucune pdc (defaut)
-
-  ielpdc = 0
-
-
-! --- Exemple 2 : Pdc definies par coordonnees pour la phase 1
-!                 Pas de pertes de charge pour la phase 2
-!                 Le traitement etant different pour les phases
-!                   un test est necessaire.
-
-  if(iphas.eq.1) then
-    ielpdc = 0
-
-    call getcel('X <= 0.4 and X >= 0.2 and Y >= -0.75 and Y <= -0.25',   &
-                nlelt,lstelt)
-     
-    do ilelt = 1, nlelt
-      iel = lstelt(ilelt)
-      ielpdc = ielpdc + 1
-      if (iappel.eq.2) icepdc(ielpdc) = iel
-    enddo
-     
-  else
-    ielpdc = 0
-  endif
-
-
-!  1.2 Sous section generique a ne pas modifier
-!  ---------------------------------------------
-
-! --- Pour IAPPEL = 1,
-!      Renseigner NCEPDP, nombre de cellules avec pdc
-!      Le bloc ci dessous est valable pourles 2 exemples ci dessus
-
-  if (iappel.eq.1) then
-    ncepdp = ielpdc
-  endif
-
-!-------------------------------------------------------------------------------
-
-elseif(iappel.eq.3) then
-
-!===============================================================================
-
-! 2. POUR CHAQUE PHASE AVEC NCEPDP > 0 , TROISIEME APPEL
-
-!      TROISIEME APPEL (POUR LES PHASES AVEC NCEPDP > 0) :
-
-!       IAPPEL = 3 : CKUPDC : CALCUL DES COEFFICIENTS DE PERTE DE CHARGE
-!                             DANS LE REPERE DE CALCUL
-!                             STOCKES DANS L'ORDRE
-!                             K11, K22, K33, K12, K13, K23
-
-
-!    REMARQUE :
-
-!        Veillez a ce que les coefs diagonaux soient positifs.
-
-!        Vous risquez un PLANTAGE si ce n'est pas le cas.
-
-!        AUCUN controle ulterieur ne sera effectue.
-
-!      ===========================================================
-
-
-!  2.1 A completer par l'utilisateur : valeur des coefs
-!  -----------------------------------------------------
-
-! --- Attention
-!   Il est important que les CKUPDC soient completes (par des valeurs
-!     nulles eventuellement) dans la mesure ou ils seront utilises pour
-!     calculer un terme source dans les cellules identifiees precedemment.
-
-!   On les initialise tous par des valeurs nulles.
-!       Et on demande a l'utilisateur de conserver cette initialisation.
-!                                        =========
-
-  do ikpdc = 1, 6
-    do ielpdc = 1, ncepdp
-      ckupdc(ielpdc,ikpdc) = 0.d0
-    enddo
-  enddo
-
-  if(iphas.eq.1) then
-
-!   Exemple de pertes de charges isotropes (tenseur diagonal)
-
-
-      do ielpdc = 1, ncepdp
-        iel=icepdc(ielpdc)
-        ckupdc(ielpdc,1) = 1.d4
-        ckupdc(ielpdc,2) = 1.d4
-        ckupdc(ielpdc,3) = 1.d4
-      enddo
-
-  endif
-
-!-------------------------------------------------------------------------------
-
-endif
-
-return
-
-end
diff --git a/examples/2-full_domain/case4/usphyv.f90 b/examples/2-full_domain/case4/usphyv.f90
deleted file mode 100644
index c0ee651..0000000
--- a/examples/2-full_domain/case4/usphyv.f90
+++ /dev/null
@@ -1,313 +0,0 @@
-!-------------------------------------------------------------------------------
-
-!                      Code_Saturne version 2.0.0-beta2
-!                      --------------------------
-
-!     This file is part of the Code_Saturne Kernel, element of the
-!     Code_Saturne CFD tool.
-
-!     Copyright (C) 1998-2009 EDF S.A., France
-
-!     contact: saturne-support at edf.fr
-
-!     The Code_Saturne Kernel is free software; you can redistribute it
-!     and/or modify it under the terms of the GNU General Public License
-!     as published by the Free Software Foundation; either version 2 of
-!     the License, or (at your option) any later version.
-
-!     The Code_Saturne Kernel 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 General Public License for more details.
-
-!     You should have received a copy of the GNU General Public License
-!     along with the Code_Saturne Kernel; if not, write to the
-!     Free Software Foundation, Inc.,
-!     51 Franklin St, Fifth Floor,
-!     Boston, MA  02110-1301  USA
-
-!-------------------------------------------------------------------------------
-
-subroutine usphyv &
-!================
-
- ( idbia0 , idbra0 ,                                              &
-   ndim   , ncelet , ncel   , nfac   , nfabor , nfml   , nprfml , &
-   nnod   , lndfac , lndfbr , ncelbr ,                            &
-   nvar   , nscal  , nphas  ,                                     &
-   nideve , nrdeve , nituse , nrtuse , nphmx  ,                   &
-   ifacel , ifabor , ifmfbr , ifmcel , iprfml ,                   &
-   ipnfac , nodfac , ipnfbr , nodfbr , ibrom  ,                   &
-   idevel , ituser , ia     ,                                     &
-   xyzcen , surfac , surfbo , cdgfac , cdgfbo , xyznod , volume , &
-   dt     , rtp    , rtpa   ,                                     &
-   propce , propfa , propfb ,                                     &
-   coefa  , coefb  ,                                              &
-   w1     , w2     , w3     , w4     ,                            &
-   w5     , w6     , w7     , w8     ,                            &
-   rdevel , rtuser , ra     )
-
-!===============================================================================
-! FONCTION :
-! --------
-
-! ROUTINE UTILISATEUR : REMPLISSAGE DES VARIABLES PHYSIQUES
-
-
-
-! ATTENTION :
-! =========
-
-
-! Il est INTERDIT de modifier la viscosite turbulente VISCT ici
-!        ========
-!  (une routine specifique est dediee a cela : usvist)
-
-
-!  Il FAUT AVOIR PRECISE ICP(IPHAS) = 1
-!     ==================
-!    dans usini1 si on souhaite imposer une chaleur specifique
-!    CP variable pour la phase IPHAS (sinon: ecrasement memoire).
-
-
-!  Il FAUT AVOIR PRECISE IVISLS(Numero de scalaire) = 1
-!     ==================
-!     dans usini1 si on souhaite une diffusivite VISCLS variable
-!     pour le scalaire considere (sinon: ecrasement memoire).
-
-
-
-
-! Remarques :
-! ---------
-
-! Cette routine est appelee au debut de chaque pas de temps
-
-!    Ainsi, AU PREMIER PAS DE TEMPS (calcul non suite), les seules
-!    grandeurs initialisees avant appel sont celles donnees
-!      - dans usini1 :
-!             . la masse volumique (initialisee a RO0(IPHAS))
-!             . la viscosite       (initialisee a VISCL0(IPHAS))
-!      - dans usiniv :
-!             . les variables de calcul  (initialisees a 0 par defaut
-!             ou a la valeur donnee dans usiniv)
-
-! On peut donner ici les lois de variation aux cellules
-!     - de la masse volumique                      ROM    kg/m3
-!         (et eventuellememt aux faces de bord     ROMB   kg/m3)
-!     - de la viscosite moleculaire                VISCL  kg/(m s)
-!     - de la chaleur specifique associee          CP     J/(kg degres)
-!     - des "diffusivites" associees aux scalaires VISCLS kg/(m s)
-
-
-! On dispose des types de faces de bord au pas de temps
-!   precedent (sauf au premier pas de temps, ou les tableaux
-!   ITYPFB et ITRIFB n'ont pas ete renseignes)
-
-
-! Il est conseille de ne garder dans ce sous programme que
-!    le strict necessaire.
-
-
-
-! Arguments
-!__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
-!__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! ncelbr           ! e  ! <-- ! nombre d'elements ayant au moins une           !
-!                  !    !     ! face de bord                                   !
-! nvar             ! e  ! <-- ! nombre total de variables                      !
-! nscal            ! e  ! <-- ! nombre total de scalaires                      !
-! nphas            ! e  ! <-- ! nombre de phases                               !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! nphmx            ! e  ! <-- ! nphsmx                                         !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! nfml  ,nprfml    !    !     !                                                !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfac)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (nfac+1)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfbr)       !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (nfabor+1)     !    !     !  (optionnel)                                   !
-! ibrom            ! te ! <-- ! indicateur de remplissage de romb              !
-!   (nphmx   )     !    !     !                                                !
-! idevel(nideve    ! te ! <-- ! tab entier complementaire developemt           !
-! ituser(nituse    ! te ! <-- ! tab entier complementaire utilisateur          !
-! ia(*)            ! tr ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet          !    !     !                                                !
-! dt(ncelet)       ! tr ! <-- ! pas de temps                                   !
-! rtp, rtpa        ! tr ! <-- ! variables de calcul au centre des              !
-! (ncelet,*)       !    !     !    cellules (instant courant ou prec)          !
-! propce           ! tr ! <-- ! proprietes physiques au centre des             !
-! (ncelet,*)       !    !     !    cellules                                    !
-! propfa           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfac,*)        !    !     !    faces internes                              !
-! propfb           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! coefa, coefb     ! tr ! <-- ! conditions aux limites aux                     !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! w1...8(ncelet    ! tr ! --- ! tableau de travail                             !
-! rdevel(nrdeve    ! tr ! <-- ! tab reel complementaire developemt             !
-! rtuser(nrtuse    ! tr ! <-- ! tab reel complementaire utilisateur            !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
-!__________________!____!_____!________________________________________________!
-
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
-!===============================================================================
-
-implicit none
-
-!===============================================================================
-!     DONNEES EN COMMON
-!===============================================================================
-
-include "paramx.h"
-include "pointe.h"
-include "numvar.h"
-include "optcal.h"
-include "cstphy.h"
-include "entsor.h"
-include "parall.h"
-include "period.h"
-
-!===============================================================================
-
-! Arguments
-
-integer          idbia0 , idbra0
-integer          ndim   , ncelet , ncel   , nfac   , nfabor
-integer          nfml   , nprfml
-integer          nnod   , lndfac , lndfbr , ncelbr
-integer          nvar   , nscal  , nphas
-integer          nideve , nrdeve , nituse , nrtuse , nphmx
-
-integer          ifacel(2,nfac) , ifabor(nfabor)
-integer          ifmfbr(nfabor) , ifmcel(ncelet)
-integer          iprfml(nfml,nprfml)
-integer          ipnfac(nfac+1), nodfac(lndfac)
-integer          ipnfbr(nfabor+1), nodfbr(lndfbr), ibrom(nphmx)
-integer          idevel(nideve), ituser(nituse), ia(*)
-
-double precision xyzcen(ndim,ncelet)
-double precision surfac(ndim,nfac), surfbo(ndim,nfabor)
-double precision cdgfac(ndim,nfac), cdgfbo(ndim,nfabor)
-double precision xyznod(ndim,nnod), volume(ncelet)
-double precision dt(ncelet), rtp(ncelet,*), rtpa(ncelet,*)
-double precision propce(ncelet,*)
-double precision propfa(nfac,*), propfb(nfabor,*)
-double precision coefa(nfabor,*), coefb(nfabor,*)
-double precision w1(ncelet),w2(ncelet),w3(ncelet),w4(ncelet)
-double precision w5(ncelet),w6(ncelet),w7(ncelet),w8(ncelet)
-double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
-
-! VARIABLES LOCALES
-
-integer          idebia, idebra
-integer          ivart, iclvar, iel, iphas
-integer          ipcrom, ipbrom, ipcvis, ipccp
-integer          ipcvsl, ith, iscal, ii
-integer          iutile
-double precision vara, varb, varc, varam, varbm, varcm, vardm
-double precision                   varal, varbl, varcl, vardl
-double precision                   varac, varbc
-double precision xrtp
-
-!===============================================================================
-
-!===============================================================================
-! 0. Initializations
-!===============================================================================
-
-! --- Memory initialization
-
-idebia = idbia0
-idebra = idbra0
-
-
-!===============================================================================
-
-! Variable density, as a function of temperature
-! ================
-
-! We use the same density law for all phases.
-!    Values of this property are assigned to cell centers.
-!    (and optionally to boundary faces).
-
-!===============================================================================
-
-do iphas = 1, nphas ! Loop on phases
-
-  ! The position of the density of phase iphas in propce
-  ! (physical properties at element centers) given by ipcrom.
-
-  ipcrom = ipproc(irom(iphas))
-
-  ! Coefficients chosen and prescribed by the user.
-
-  vara  = -4.0668d-3
-  varb  = -5.0754d-2
-  varc  =  1000.9d0
-
-  ! Density at cell centers
-  ! -----------------------
-  !   Law:              rho        =   t  * (  a *  t +  b ) +   c
-  !   Code:    propce(iel, ipcrom) = xrtp * (vara*xrtp+varb) + varc
-
-  do iel = 1, ncel
-    xrtp = rtp(iel,isca(1))
-    propce(iel,ipcrom) = xrtp * (vara*xrtp+varb) + varc
-  enddo
-
-enddo ! End of loop on phases
-
-!===============================================================================
-
-!----
-! Formats
-!----
-
-!----
-! Fin
-!----
-
-return
-end
diff --git a/examples/2-full_domain/case4/usproj.f90 b/examples/2-full_domain/case4/usproj.f90
index e6e1686..03a363a 100644
--- a/examples/2-full_domain/case4/usproj.f90
+++ b/examples/2-full_domain/case4/usproj.f90
@@ -1,12 +1,12 @@
 !-------------------------------------------------------------------------------
 
-!                      Code_Saturne version 2.0.0-beta2
+!                      Code_Saturne version 2.0.0-rc1
 !                      --------------------------
 
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2008 EDF S.A., France
+!     Copyright (C) 1998-2009 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -47,184 +47,166 @@ subroutine usproj &
    rdevel , rtuser , ra     )
 
 !===============================================================================
-! FONCTION :
-! --------
+! Purpose:
+! -------
 
-! MODIFICATION UTILISATEUR EN FIN DE PAS DE TEMPS
-!   TOUT EST POSSIBLE,
+!    User subroutine.
 
+!    Called at end of each time step, very general purpose
+!    (i.e. anything that does not have another dedicated user subroutine)
 
-! ON DONNE ICI PLUSIEURS EXEMPLES :
 
-!  - CALCUL DE BILAN THERMIQUE
-!    (au besoin, voir "ADAPTATION A UN SCALAIRE QUELCONQUE")
+! Several examples are given here:
 
-!  - CALCUL DES EFFORTS GLOBAUX SUR UN SOUS-ENSEMBLE DE FACES
+!  - compute a thermal balance
+!    (if needed, see note  below on adapting this to any scalar)
 
-!  - MODIFICATION ARBITRAIRE D'UNE VARIABLE DE CALCUL
+!  - compute global efforts on a subset of faces
 
-!  - EXTRACTION D'UN PROFIL 1D
+!  - arbitrarily modify a calculation variable
 
-!  - IMPRESSION D'UN MOMENT
+!  - extract a 1 d profile
 
-!  - EXEMPLES D'UTILISATION DES ROUTINES DE PARALLELISME
+!  - print a moment
 
-! CES EXEMPLES SONT DONNES EN SUPPOSANT UN CAS AVEC PERIODICITE
-!  (IPERIO    .GT.0) ET PARALLELISME (IRANGP.GE.0).
+!  - examples on using parallel utility functions
 
+! These examples are valid when using periodicity (iperio .gt. 0)
+! and in parallel (irangp .ge. 0).
 
-! LE CALCUL DE BILAN THERMIQUE FOURNIT EN OUTRE UNE TRAME POUR
-!  PLUSIEURS CHOSES
-!  - CALCUL DE GRADIENT (AVEC LES PRECAUTIONS UTILES EN PARALLELE ET
-!    PERIODIQUE)
-!  - CALCUL DE GRANDEUR DEPENDANT DES VALEURS AUX CELLULES VOISINES
-!    D'UNE FACE (AVEC LES PRECAUTIONS A PRENDRE EN PARALLELE ET
-!    PERIODIQUE : VOIR L'ECHANGE DE DT ET DE CP)
-!  - CALCUL D'UNE SOMME SUR LES PROCESSEURS LORS D'UN CALCUL
-!    PARALLELE (PARSOM)
+! The thermal balance compution also illustates a few other features,
+! including the required precautions in parallel or with periodicity):
+! - gradient calculation
+! - computation of a value depending on cells adjacent to a face
+!   (see synchronization of Dt and Cp)
+! - computation of a global sum in parallel (parsom)
 
 
-! IDENTIFICATION DES CELLULES/FACES DE BORD/FACES INTERNES
-! ========================================================
+! Cells, boundary faces and interior faces identification
+! =======================================================
 
-!  Les commandes GETCEL, GETFBR et GETFAC permettent d'identifier
-!  respectivement les cellules, faces ou faces de bord en fonction
-!  de differents criteres.
+! Cells, boundary faces and interior faces may be identified using
+! the subroutines 'getcel', 'getfbr' and 'getfac' (respectively).
 
-!  GETCEL(CHAINE,NLELT,LSTELT) :
-!  - CHAINE est une chaine de caractere fournie par l'utilisateur
-!    qui donne les criteres de selection
-!  - NLTELT est renvoye par la commande. C'est un entier qui
-!    correspond au nombre de cellules trouveees repondant au
-!    critere
-!  - LSTELT est renvoye par la commande. C'est un tableau d'entiers
-!    de taille NLTELT donnant la liste des cellules trouvees
-!    repondant au critere.
+!  getfbr(string, nelts, eltlst):
+!  - string is a user-supplied character string containing selection criteria;
+!  - nelts is set by the subroutine. It is an integer value corresponding to
+!    the number of boundary faces verifying the selection criteria;
+!  - lstelt is set by the subroutine. It is an integer array of size nelts
+!    containing the list of boundary faces verifying the selection criteria.
 
-!  CHAINE peut etre constitue de :
-!  - references de couleurs (ex. : 1, 8, 26, ...
-!  - references de groupes (ex. : entrees, groupe1, ...)
-!  - criteres geometriques (ex. X<0.1, Y>=0.25, ...)
-!  Ces criteres peuvent etre combines par des operateurs logiques
-!  (AND et OR) et des parentheses
-!  ex. : '1 AND (groupe2 OR groupe3) AND Y<1' permettra de recuperer
-!  les cellules de couleur 1, appartenant aux groupes 'groupe2'
-!  ou 'groupe3' et de coordonnee Y inferieure a 1.
+!  string may contain:
+!  - references to colors (ex.: 1, 8, 26, ...)
+!  - references to groups (ex.: inlet, group1, ...)
+!  - geometric criteria (ex. x < 0.1, y >= 0.25, ...)
+!  These criteria may be combined using logical operators ('and', 'or') and
+!  parentheses.
+!  Example: '1 and (group2 or group3) and y < 1' will select boundary faces
+!  of color 1, belonging to groups 'group2' or 'group3' and with face center
+!  coordinate y less than 1.
 
-!  La syntaxe des commandes GETFBR et GETFAC est identique.
+! Similarly, interior faces and cells can be identified using the 'getfac'
+! and 'getcel' subroutines (respectively). Their syntax are identical to
+! 'getfbr' syntax.
+
+! For a more thorough description of the criteria syntax, it can be referred
+! to the user guide.
 
 
 !-------------------------------------------------------------------------------
 ! Arguments
 !__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
+! name             !type!mode ! role                                           !
 !__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! ncelbr           ! e  ! <-- ! nombre d'elements ayant au moins une           !
-!                  !    !     ! face de bord                                   !
-! nvar             ! e  ! <-- ! nombre total de variables                      !
-! nscal            ! e  ! <-- ! nombre total de scalaires                      !
-! nphas            ! e  ! <-- ! nombre de phases                               !
-! nbpmax           ! e  ! <-- ! nombre max de particules autorise              !
-! nvp              ! e  ! <-- ! nombre de variables particulaires              !
-! nvep             ! e  ! <-- ! nombre info particulaires (reels)              !
-! nivep            ! e  ! <-- ! nombre info particulaires (entiers)            !
-! ntersl           ! e  ! <-- ! nbr termes sources de couplage retour          !
-! nvlsta           ! e  ! <-- ! nombre de var statistiques lagrangien          !
-! nvisbr           ! e  ! <-- ! nombre de statistiques aux frontieres          !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! nfml  ,nprfml    !    !     !                                                !
-! maxelt           !  e ! <-- ! nb max d'elements (cell,fac,fbr)               !
-! lstelt(maxelt) te ! --- ! tableau de travail                             !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (nfac+1)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (lndfac)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!  (nfabor+1)      !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (lndfbr  )     !    !     !  (optionnel)                                   !
-! itepa            ! te ! <-- ! info particulaires (entiers)                   !
-! (nbpmax,nivep    !    !     !   (cellule de la particule,...)                !
-! idevel(nideve    ! te ! <-- ! tab entier complementaire developemt           !
-! ituser(nituse    ! te ! <-- ! tab entier complementaire utilisateur          !
-! ia(*)            ! tr ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet          !    !     !                                                !
-! dt(ncelet)       ! tr ! <-- ! pas de temps                                   !
-! rtp, rtpa        ! tr ! <-- ! variables de calcul au centre des              !
-! (ncelet,*)       !    !     !    cellules (instant courant ou prec)          !
-! propce           ! tr ! <-- ! proprietes physiques au centre des             !
-! (ncelet,*)       !    !     !    cellules                                    !
-! propfa           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfac,*)        !    !     !    faces internes                              !
-! propfb           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! coefa, coefb     ! tr ! <-- ! conditions aux limites aux                     !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! ettp             ! tr ! <-- ! tableaux des variables liees                   !
-!  (nbpmax,nvp)    !    !     !   aux particules etape courante                !
-! ettpa            ! tr ! <-- ! tableaux des variables liees                   !
-!  (nbpmax,nvp)    !    !     !   aux particules etape precedente              !
-! tepa             ! tr ! <-- ! info particulaires (reels)                     !
-! (nbpmax,nvep)    !    !     !   (poids statistiques,...)                     !
-! statis           ! tr ! <-- ! moyennes statistiques                          !
-!(ncelet,nvlsta    !    !     !                                                !
-! stativ           ! tr ! <-- ! cumul pour les variances des                   !
-!(ncelet,          !    !     !    statistiques volumiques                     !
-!   nvlsta-1)      !    !     !                                                !
-! tslagr           ! tr ! <-- ! terme de couplage retour du                    !
-!(ncelet,ntersl    !    !     !   lagrangien sur la phase porteuse             !
-! parbor           ! tr ! <-- ! infos sur interaction des particules           !
-!(nfabor,nvisbr    !    !     !   aux faces de bord                            !
-! rdevel(nrdeve    ! tr ! <-- ! tab reel complementaire developemt             !
-! rtuser(nrtuse    ! tr ! <-- ! tab reel complementaire utilisateur            !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
+! idbia0           ! i  ! <-- ! number of first free position in ia            !
+! idbra0           ! i  ! <-- ! number of first free position in ra            !
+! ndim             ! i  ! <-- ! spatial dimension                              !
+! ncelet           ! i  ! <-- ! number of extended (real + ghost) cells        !
+! ncel             ! i  ! <-- ! number of cells                                !
+! nfac             ! i  ! <-- ! number of interior faces                       !
+! nfabor           ! i  ! <-- ! number of boundary faces                       !
+! nfml             ! i  ! <-- ! number of families (group classes)             !
+! nprfml           ! i  ! <-- ! number of properties per family (group class)  !
+! nnod             ! i  ! <-- ! number of vertices                             !
+! lndfac           ! i  ! <-- ! size of nodfac indexed array                   !
+! lndfbr           ! i  ! <-- ! size of nodfbr indexed array                   !
+! ncelbr           ! i  ! <-- ! number of cells with faces on boundary         !
+! nvar             ! i  ! <-- ! total number of variables                      !
+! nscal            ! i  ! <-- ! total number of scalars                        !
+! nphas            ! i  ! <-- ! number of phases                               !
+! nbpmax           ! i  ! <-- ! max. number of particles allowed               !
+! nvp              ! i  ! <-- ! number of particle-defined variables           !
+! nvep             ! i  ! <-- ! number of real particle properties             !
+! nivep            ! i  ! <-- ! number of integer particle properties          !
+! ntersl           ! i  ! <-- ! number of return coupling source terms         !
+! nvlsta           ! i  ! <-- ! number of Lagrangian statistical variables     !
+! nvisbr           ! i  ! <-- ! number of boundary statistics                  !
+! nideve, nrdeve   ! i  ! <-- ! sizes of idevel and rdevel arrays              !
+! nituse, nrtuse   ! i  ! <-- ! sizes of ituser and rtuser arrays              !
+! ifacel(2, nfac)  ! ia ! <-- ! interior faces -> cells connectivity           !
+! ifabor(nfabor)   ! ia ! <-- ! boundary faces -> cells connectivity           !
+! ifmfbr(nfabor)   ! ia ! <-- ! boundary face family numbers                   !
+! ifmcel(ncelet)   ! ia ! <-- ! cell family numbers                            !
+! iprfml           ! ia ! <-- ! property numbers per family                    !
+!  (nfml, nprfml)  !    !     !                                                !
+! maxelt           ! i  ! <-- ! max number of cells and faces (int/boundary)   !
+! lstelt(maxelt)   ! ia ! --- ! work array                                     !
+! ipnfac(nfac+1)   ! ia ! <-- ! interior faces -> vertices index (optional)    !
+! nodfac(lndfac)   ! ia ! <-- ! interior faces -> vertices list (optional)     !
+! ipnfbr(nfabor+1) ! ia ! <-- ! boundary faces -> vertices index (optional)    !
+! nodfbr(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
+! itepa            ! ia ! <-- ! integer particle attributes                    !
+!  (nbpmax, nivep) !    !     !   (containing cell, ...)                       !
+! idevel(nideve)   ! ia ! <-- ! integer work array for temporary development   !
+! ituser(nituse)   ! ia ! <-- ! user-reserved integer work array               !
+! ia(*)            ! ia ! --- ! main integer work array                        !
+! xyzcen           ! ra ! <-- ! cell centers                                   !
+!  (ndim, ncelet)  !    !     !                                                !
+! surfac           ! ra ! <-- ! interior faces surface vectors                 !
+!  (ndim, nfac)    !    !     !                                                !
+! surfbo           ! ra ! <-- ! boundary faces surface vectors                 !
+!  (ndim, nfabor)  !    !     !                                                !
+! cdgfac           ! ra ! <-- ! interior faces centers of gravity              !
+!  (ndim, nfac)    !    !     !                                                !
+! cdgfbo           ! ra ! <-- ! boundary faces centers of gravity              !
+!  (ndim, nfabor)  !    !     !                                                !
+! xyznod           ! ra ! <-- ! vertex coordinates (optional)                  !
+!  (ndim, nnod)    !    !     !                                                !
+! volume(ncelet)   ! ra ! <-- ! cell volumes                                   !
+! dt(ncelet)       ! ra ! <-- ! time step (per cell)                           !
+! rtp, rtpa        ! ra ! <-- ! calculated variables at cell centers           !
+!  (ncelet, *)     !    !     !  (at current and previous time steps)          !
+! propce(ncelet, *)! ra ! <-- ! physical properties at cell centers            !
+! propfa(nfac, *)  ! ra ! <-- ! physical properties at interior face centers   !
+! propfb(nfabor, *)! ra ! <-- ! physical properties at boundary face centers   !
+! coefa, coefb     ! ra ! <-- ! boundary conditions                            !
+!  (nfabor, *)     !    !     !                                                !
+! ettp, ettpa      ! ra ! <-- ! particle-defined variables                     !
+!  (nbpmax, nvp)   !    !     !  (at current and previous time steps)          !
+! tepa             ! ra ! <-- ! real particle properties                       !
+!  (nbpmax, nvep)  !    !     !  (statistical weight, ...                      !
+! statis           ! ra ! <-- ! statistic means                                !
+!  (ncelet, nvlsta)!    !     !                                                !
+! stativ(ncelet,   ! ra ! <-- ! accumulator for variance of volume statisitics !
+!        nvlsta -1)!    !     !                                                !
+! tslagr           ! ra ! <-- ! Lagrangian return coupling term                !
+!  (ncelet, ntersl)!    !     !  on carrier phase                              !
+! parbor           ! ra ! <-- ! particle interaction properties                !
+!  (nfabor, nvisbr)!    !     !  on boundary faces                             !
+! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
+! rtuser(nrtuse)   ! ra ! <-- ! user-reserved real work array                  !
+! ra(*)            ! ra ! --- ! main real work array                           !
 !__________________!____!_____!________________________________________________!
 
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
 !===============================================================================
 
 implicit none
 
 !===============================================================================
-!     DONNEES EN COMMON
+! Common blocks
 !===============================================================================
 
 include "dimfbr.h"
@@ -281,7 +263,7 @@ double precision tslagr(ncelet,ntersl)
 double precision parbor(nfabor,nvisbr)
 double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
 
-! VARIABLES LOCALES
+! Local variables
 
 integer          idebia, idebra
 integer          iel
@@ -293,7 +275,7 @@ double precision sum, sumvol
 
 
 !===============================================================================
-! 1. INITIALISATION
+! 1. Initialization
 !===============================================================================
 
 ! ---> Extra memory handling
@@ -339,4 +321,4 @@ if (ntcabs.eq.ntmabs .and. irangp.le.0) then
 endif
 
 return
-end
+end subroutine
diff --git a/examples/3-stratified_junction/case5/case5.xml b/examples/3-stratified_junction/case5/case5.xml
index b1ba5da..13a0882 100644
--- a/examples/3-stratified_junction/case5/case5.xml
+++ b/examples/3-stratified_junction/case5/case5.xml
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE5" study="STRATIFIED_JUNCTION" version="1.0">
+<?xml version="1.0" encoding="utf-8"?><Code_Saturne_GUI case="CASE5" study="STRATIFIED_JUNCTION" version="2.0">
 	<solution_domain>
 		<volumic_conditions>
 			<zone head_losses="off" initialization="on" label="all_cells" mass_source_term="off" momentum_source_term="off" name="1" scalar_source_term="off" thermal_source_term="off">all[]</zone>
@@ -9,22 +9,21 @@
 		<join_meshes status="off"/>
 		<faces_cutting status="off"/>
 		<reorientation status="off"/>
-		<syrthes_coupling status="off"/>
 		<periodic_boundary/>
 		<standalone/>
 	</solution_domain>
 	<thermophysical_models>
 		<velocity_pressure>
-			<variable label="Pression" name="pressure">
+			<variable label="Pressure" name="pressure">
 				<reference_pressure>101325</reference_pressure>
 			</variable>
-			<variable label="VitesseX" name="velocity_U">
+			<variable label="VelocityX" name="velocity_U">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseY" name="velocity_V">
+			<variable label="VelocityY" name="velocity_V">
 				<blending_factor>1</blending_factor>
 			</variable>
-			<variable label="VitesseZ" name="velocity_W">
+			<variable label="VelocityZ" name="velocity_W">
 				<blending_factor>1</blending_factor>
 			</variable>
 			<property label="total_pressure" name="total_pressure"/>
@@ -34,25 +33,30 @@
 		</velocity_pressure>
 		<ale_method status="off"/>
 		<turbulence model="k-epsilon">
-			<variable label="EnerTurb" name="turb_k"/>
+			<variable label="TurbEnergy" name="turb_k"/>
 			<variable label="Dissip" name="turb_eps"/>
-			<property label="visc. tu" name="turb_viscosity"/>
+			<property label="TurbVisc" name="turb_viscosity"/>
 			<initialization choice="reference_velocity">
 				<reference_velocity>0.03183</reference_velocity>
 			</initialization>
-			<scale_model>1</scale_model>
-			<gravity_terms status="on"/>
 		</turbulence>
 		<thermal_scalar model="temperature_celsius">
-			<property label="Flux_thermique_entrant" name="input_thermal_flux" support="boundary"/>
+			<property label="Input_thermal_flux" name="input_thermal_flux" support="boundary"/>
 		</thermal_scalar>
-		<radiative_transfer model="off"/>
+		<radiative_transfer model="off">
+			<restart status="off"/>
+			<absorption_coefficient type="constant">0</absorption_coefficient>
+		</radiative_transfer>
+		<conjugate_heat_transfer>
+			<external_coupling status="off"/>
+			<external_coupling status="off"/>
+			<external_coupling status="on"/>
+		</conjugate_heat_transfer>
 		<gas_combustion model="off"/>
 		<pulverized_coal model="off"/>
 		<joule_effect model="off"/>
-		<atmospheric_flows model="off">
-			<read_meteo_data status="off"/>
-		</atmospheric_flows>
+		<atmospheric_flows model="off"/>
+		<heads_losses/>
 	</thermophysical_models>
 	<numerical_parameters>
 		<multigrid status="on"/>
@@ -64,18 +68,20 @@
 	</numerical_parameters>
 	<physical_properties>
 		<fluid_properties>
-			<property choice="variable" label="Masse vo" name="density">
+			<property choice="user_law" label="Density" name="density">
 				<initial_value>998.671</initial_value>
+				<formula>rho = TempC*(-4.0668e-3*TempC -5.0754e-2) + 1000.9;</formula>
 			</property>
-			<property choice="variable" label="Visc. la" name="molecular_viscosity">
-				<initial_value>4.45e-05</initial_value>
+			<property choice="user_law" label="Molecular_visc" name="molecular_viscosity">
+				<initial_value>0.001445</initial_value>
+				<formula>mu = TempC*(TempC*(-3.4016e-9*TempC + 6.2332e-7) -4.5577e-5) + 1.6935e-3;</formula>
 			</property>
-			<property choice="constant" label="Ch.spec." name="specific_heat">
+			<property choice="constant" label="Sp_heat" name="specific_heat">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>4182.88</initial_value>
 			</property>
-			<property choice="constant" label="Cond. th" name="thermal_conductivity">
+			<property choice="constant" label="Th_cond" name="thermal_conductivity">
 				<listing_printing status="off"/>
 				<postprocessing_recording status="off"/>
 				<initial_value>0.601498</initial_value>
@@ -89,30 +95,39 @@
 		<hydrostatic_pressure status="on"/>
 	</physical_properties>
 	<additional_scalars>
-		<scalar label="Temp.C" name="temperature_celsius" type="thermal">
-			<initial_value zone="1">38.5</initial_value>
+		<scalar label="TempC" name="temperature_celsius" type="thermal">
+			<initial_value label="all_cells" zone="1">38.5</initial_value>
 			<min_value>18.26</min_value>
 			<max_value>38.5</max_value>
 			<blending_factor>1</blending_factor>
 		</scalar>
 	</additional_scalars>
 	<boundary_conditions>
+		<boundary label="wall" name="3" nature="wall">5</boundary>
+		<wall label="wall">
+			<velocity_pressure choice="off">
+				<dirichlet name="velocity_U">0</dirichlet>
+				<dirichlet name="velocity_V">0</dirichlet>
+				<dirichlet name="velocity_W">0</dirichlet>
+			</velocity_pressure>
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
+				<neumann>0</neumann>
+			</scalar>
+		</wall>
 		<boundary label="cold_inlet" name="1" nature="inlet">2</boundary>
+		<boundary label="hot_inlet" name="2" nature="inlet">6</boundary>
+		<boundary label="outlet" name="5" nature="outlet">7</boundary>
 		<inlet label="cold_inlet">
 			<velocity_pressure choice="norm" direction="normal">
 				<norm>0.03183</norm>
-				<direction_x>0</direction_x>
-				<direction_y>0</direction_y>
-				<direction_z>0</direction_z>
 			</velocity_pressure>
 			<turbulence choice="hydraulic_diameter">
 				<hydraulic_diameter>0.4</hydraulic_diameter>
 			</turbulence>
-			<scalar choice="dirichlet" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="dirichlet" label="TempC" name="temperature_celsius" type="thermal">
 				<dirichlet>18.6</dirichlet>
 			</scalar>
 		</inlet>
-		<boundary label="hot_inlet" name="2" nature="inlet">6</boundary>
 		<inlet label="hot_inlet">
 			<velocity_pressure choice="norm" direction="normal">
 				<norm>0.03183</norm>
@@ -120,39 +135,28 @@
 			<turbulence choice="hydraulic_diameter">
 				<hydraulic_diameter>0.4</hydraulic_diameter>
 			</turbulence>
-			<scalar choice="dirichlet" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="dirichlet" label="TempC" name="temperature_celsius" type="thermal">
 				<dirichlet>38.5</dirichlet>
 			</scalar>
 		</inlet>
-		<boundary label="wall" name="3" nature="wall">5</boundary>
-		<wall label="wall">
-			<velocity_pressure choice="off">
-				<dirichlet name="velocity_U">0</dirichlet>
-				<dirichlet name="velocity_V">0</dirichlet>
-				<dirichlet name="velocity_W">0</dirichlet>
-			</velocity_pressure>
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
-				<neumann>0</neumann>
-			</scalar>
-		</wall>
-		<boundary label="outlet" name="5" nature="outlet">7</boundary>
+		<variable/>
 		<outlet label="outlet">
-			<scalar choice="neumann" label="Temp.C" name="temperature_celsius" type="thermal">
+			<scalar choice="neumann" label="TempC" name="temperature_celsius" type="thermal">
 				<neumann>0</neumann>
 			</scalar>
 		</outlet>
-		<variable/>
 	</boundary_conditions>
 	<analysis_control>
 		<output>
 			<postprocessing_mesh_options choice="0"/>
+			<syrthes_boundary status="off"/>
 			<postprocessing_format choice="EnSight"/>
 			<postprocessing_options choice="binary"/>
+			<domain_boundary status="off"/>
 			<listing_printing_frequency>1</listing_printing_frequency>
 			<postprocessing_frequency>10</postprocessing_frequency>
 			<probe_recording_frequency>1</probe_recording_frequency>
 			<fluid_domain status="on"/>
-			<domain_boundary status="off"/>
 			<probe name="1" status="on">
 				<probe_x>0.010025</probe_x>
 				<probe_y>0.01534</probe_y>
@@ -175,18 +179,21 @@
 			</probe>
 		</output>
 		<time_parameters>
-			<property label="Nb Courant" name="courant_number"/>
-			<property label="Nb Fourier" name="fourier_number"/>
 			<time_step_ref>1</time_step_ref>
-			<iterations>10</iterations>
+			<iterations>100</iterations>
 			<time_passing>1</time_passing>
+			<property label="CFL_number" name="courant_number"/>
+			<property label="Fourier_number" name="fourier_number"/>
 			<thermal_time_step status="on"/>
 			<zero_time_step status="off"/>
-			<property label="pdtlocal" name="local_time_step"/>
+			<property label="local_dt" name="local_time_step">
+				<postprocessing_recording status="off"/>
+				<probes choice="0"/>
+			</property>
 			<max_courant_num>20</max_courant_num>
 			<max_fourier_num>60</max_fourier_num>
-			<time_step_min>0.01</time_step_min>
-			<time_step_max>70</time_step_max>
+			<time_step_min_factor>0.01</time_step_min_factor>
+			<time_step_max_factor>70</time_step_max_factor>
 			<time_step_var>0.1</time_step_var>
 		</time_parameters>
 		<steady_management status="off"/>
@@ -197,6 +204,8 @@
 		<start_restart>
 			<restart status="off"/>
 			<frozen_field status="off"/>
+			<restart_rescue>0</restart_rescue>
+			<restart_with_auxiliary status="on"/>
 		</start_restart>
 		<integer_user_array>
 			<ncelet>0</ncelet>
diff --git a/examples/3-stratified_junction/case5/runcase b/examples/3-stratified_junction/case5/runcase
deleted file mode 100755
index 3f4de8a..0000000
--- a/examples/3-stratified_junction/case5/runcase
+++ /dev/null
@@ -1,1125 +0,0 @@
-#!/bin/sh
-# bin/runcase.  Generated from runcase.in by configure.
-#============================================================================
-#
-#     This file is part of the Code_Saturne Kernel, element of the
-#     Code_Saturne CFD tool.
-#
-#     Copyright (C) 1998-2009 EDF S.A., France
-#
-#     contact: saturne-support at edf.fr
-#
-#     The Code_Saturne Kernel is free software; you can redistribute it
-#     and/or modify it under the terms of the GNU General Public License
-#     as published by the Free Software Foundation; either version 2 of
-#     the License, or (at your option) any later version.
-#
-#     The Code_Saturne Kernel 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 General Public License for more details.
-#
-#     You should have received a copy of the GNU General Public License
-#     along with the Code_Saturne Kernel; if not, write to the
-#     Free Software Foundation, Inc.,
-#     51 Franklin St, Fifth Floor,
-#     Boston, MA  02110-1301  USA
-#
-#============================================================================
-#
-########################################################################
-#
-#                  BATCH FILE FOR THE CCRT (Platine under LSF)
-#                  ===========================================
-#
-#BSUB -n 2
-#BSUB -W 00:30
-#BSUB -o stratified_junctioncaseo.%J 
-#BSUB -e stratified_junctioncasee.%J 
-#BSUB -J stratified_junctioncase
-#
-#  -n : number of processors
-#  -W : walltime as hh:mm
-#  -o : output file name
-#  -e : error file name
-#  -J : job name
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE FOR THE Chatou CLUSTER (PBS)
-#                  =======================================
-#
-#PBS -l nodes=4:ppn=2
-#PBS -l walltime=1:00:00
-#PBS -l mem=320mb
-#
-#PBS -j eo
-#PBS -N stratified_junctioncase5
-#
-#  nodes    : number of nodes
-#  ppn      : number of process per node
-#  walltime : wall clock time (hh:mm:ss)
-#  mem      : memory
-#
-#WARNING: when coupling with SYRTHES, 1 processor will be reserved for each
-#         instance of SYRTHES. The Kernel will be executed on the remaining
-#         processors, so make sure to reserve a sufficiently high number
-#         of processors.
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (University of Manchester Cluster)
-#                  =============================================
-#
-# set the name of the job
-##$ -N stratified_junctioncase5
-#
-# request between 2 and 4 slots
-##$ -pe mpich 2-4
-#
-# Execute the job from the current working directory
-# Job output will appear in this directory
-##$ -cwd
-#   can use -o dirname to redirect stdout
-#   can use -e dirname to redirect stderr
-
-#  Export these environment variables
-##$ -v MPI_HOME
-
-#set -x
-#
-# ------------------------------------------------------------------
-#
-#                  BATCH FILE (AIX, Loadlever)
-#                  ===========================
-#
-#@ shell = /bin/sh
-#
-#@ job_name = stratified_junctioncase5
-#
-#@ job_type = parallel
-#@ cpus = 128
-#@ node_usage = not_shared
-#
-#@ network.MPI = csss,shared,US
-#@ bulkxfer = yes
-#
-#@ wall_clock_limit = 00:20:00
-#@ account_no = z001
-#
-#@ output = $(job_name).$(schedd_host).$(jobid).out
-#@ error  = $(job_name).$(schedd_host).$(jobid).err
-#@ notification = never
-#
-#@ queue
-# suggested environment settings:
-#  export MP_EAGER_LIMIT=65536
-#  export MP_SHARED_MEMORY=yes
-#  export MEMORY_AFFINITY=MCM
-#  export MP_TASK_AFFINITY=MCM
-#
-########################################################################
-#
-# BEGINNING OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-# runcase.help gives more details about the different variables.
-#
-#                    -------------------------------
-#
-SOLCOM=0
-#
-# On some systems, some external libraries may require TERM to be defined.
-export TERM=xterm
-#
-STUDY=STRATIFIED_JUNCTION
-CASE=CASE5
-PARAM=case5.xml
-MESH=sn_total.des
-COMMAND_REORIENT=
-COMMAND_JOIN=
-COMMAND_CWF=
-COMMAND_PERIO=
-THERMOCHEMISTRY_DATA=
-METEO_DATA=
-#
-# Choose the total number of processors used (if empty, automatic detection
-# through the batch system if possible, set to 1 otherwise).
-# When coupling with SYRTHES with COUPLING_MODE=MPI, the 1st processor is
-# used by SYRTHES, so the effective number of processors assigned to the
-# Kernel is reduced by 1.
-# The processors list is only usable when not running on a batch system
-# (as such a system usually already defines a similar list)
-NUMBER_OF_PROCESSORS=
-PROCESSOR_LIST=
-#
-PARTITION_LIST=
-#
-USER_INPUT_FILES=""
-USER_OUTPUT_FILES=""
-#
-# Working directory (leave empty for automatic default directory)
-CS_TMP_PREFIX=
-#CS_TMP_PREFIX=/local00/users/`whoami`
-#
-CS_LIB_ADD=
-VALGRIND=
-#
-ARG_CS_VERIF=""
-ARG_CS_OUTPUT=""
-#
-# Adaptation using HOMARD
-ADAPTATION=
-#
-summary=summary
-CASEDIR=/home/saturne/TEST_CASE/STRATIFIED_JUNCTION/CASE5
-DATA=$CASEDIR/DATA
-RESU=$CASEDIR/RESU
-SRC=$CASEDIR/SRC
-SCRIPTS=$CASEDIR/SCRIPTS
-RESTART_IN=$DATA/RESTART
-PREPROCESSOR_OUTPUT_IN=$DATA/preprocessor_output
-PARTITION_OUTPUT_IN=$DATA/PARTITION_OUTPUT
-MESHDIR=$CASEDIR/../MESH
-#
-# The following variables are only used in case of coupling with SYRTHES.
-#  DATA_SYR: directory where to find SYRTHES_ENV
-#  SRC_SYR:  directory where to find possible user source files
-DATA_SYR=$CASEDIR/DATA_SYR
-SRC_SYR=$CASEDIR/SRC_SYR
-SYRTHES_ENV=syrthes.env
-#
-# The possible coupling mode with SYRTHES may be chosen here.
-#
-#  COUPLING_MODE=MPI        : should work on most machines.
-#  COUPLING_MODE=sockets    : should be activated on clusters when the MPI rank
-#                             of a process is not determinable or if MPI can
-#                             not be used.
-COUPLING_MODE=MPI
-ECHO_SYR_COMM=""
-#
-#  Indicate which steps should be executed; if both the Preprocessor and the
-#  Kernel are executed, the "preprocessor_output" and eventual "domain_number_*"
-#  files are not saved. If only the preprocessor and / or partitioner are
-#  executed, the corresponding files will be saved in a RESU/PREPROCESSOR_OUTPUT
-#  and RESU/PARTITION directory. If the Preprocessor is not executed,
-#  "preprocessor_output" will be read from $PREPROCESSOR_OUTPUT_IN. If the
-#  Partitioner is not executed, "domain_number_*" will be read from
-#  $PARTITION_OUTPUT_IN if available (otherwise, unoptimized default
-#  partitioning will be used).
-#
-#  EXEC_PREPROCESS : should the Preprocessor be run ? (yes/no)
-#  EXEC_PARTITION  : should the Partitioner be run ? (yes/no)
-#  EXEC_KERNEL     : should the Kernel be run ? (yes/no)
-#
-EXEC_PREPROCESS=yes
-EXEC_PARTITION=yes
-EXEC_KERNEL=yes
-#
-#
-#
-########################################################################
-#
-# END OF USER MODIFIABLE ZONE FOR STANDARD CALCULATIONS
-#
-########################################################################
-#
-# Kernel installation parameters
-#
-prefix=/home/saturne/Code_Saturne/2.0-beta2/arch/Linux_x86_64
-#
-exec_prefix=${prefix}
-bindir=${exec_prefix}/bin
-datarootdir=${prefix}/share
-datadir=${datarootdir}
-pkgdatadir=${datadir}/ncs
-#
-# Preprocessor installation parameters
-#
-ecs_prefix=
-#
-ecs_exec_prefix=${ecs_prefix}
-ecs_bindir=${ecs_exec_prefix}/bin
-#
-# HOMARD installation parameters (to be completed if needed)
-#
-homard_prefix=
-#
-########################################################################
-#  Mesh Adaptation
-#
-if [ ! -z  "${ADAPTATION}" ] ; then
-  if [ "${ADAPTATION}" = "-help" ] ; then
-    ${homard_prefix}/saturne_homard ${ADAPTATION}
-    exit 0
-  else
-    HOMARD_options="  -v"
-    ${homard_prefix}/saturne_homard -Saturne_Script $0 -Donnees_Calcul $CASEDIR \
-                    -Pilotage_Adaptation $ADAPTATION $HOMARD_options || exit 1
-  fi
-fi
-#
-#########################################################################
-#
-N_SYRTHES_COUPLINGS=0
-if [ -f "${SRC}/ussyrc.f90" ] ; then
-  N_SYRTHES_COUPLINGS=`grep -e ^' ' ${SRC}/ussyrc.f90 | grep -i -c defsyr`
-fi
-#
-if [ $N_SYRTHES_COUPLINGS = 0 ] ; then
-  SYRTHES_COUPLING=no
-else
-  SYRTHES_COUPLING=yes
-  export SYRTHES
-  if [ $N_SYRTHES_COUPLINGS -gt 1 ] ; then
-   echo "This script can not handle multiple couplings with SYRTHES"
-   echo "Number of SYRTHES couplings requested: $N_SYRTHES_COUPLINGS"
-  fi
-fi
-#
-if [ $SYRTHES_COUPLING = yes ] ; then
-  if [ $SOLCOM -eq 1 ] ; then
-   echo "SYRTHES coupling is not compatible with SOLCOM-type meshes"
-   exit 1
-  fi
-else
-  COUPLING_MODE=
-fi
-#
-########################################################################
-#
-# Parameters for execution
-#
-# General variables
-THISSCRIPT=$0
-USER=`whoami`
-DATE=`date '+%m%d%H%M'`
-SUFFIX=$DATE
-EXE=cs_solver
-EXE_SYR=syrthes
-#
-# Copy runcase before changing to the working directory
-# (as after that, the relative path will not be up to date).
-#
-cp $0 $RESU/runcase.$SUFFIX
-#
-# Execution directory (reachable by all the processors)
-#
-if [ ! -z "$CS_TMP_PREFIX" ] ; then
-  RUN=${CS_TMP_PREFIX}/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-else
-#  Default if not specified by the user
-#
-#  On the CCRT, there is no TMPDIR. We work by default in SCRATCHDIR
-  if [ "$SCRATCHDIR" != "" ] ; then
-    RUN=$SCRATCHDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-#
-  elif [ "$TMPDIR" != "" -a "$TMPDIR" != "/tmp" ] ; then
-    RUN=$TMPDIR/tmp_Saturne/$STUDY.$CASE.$DATE
-  else
-    RUN=$HOME/tmp_Saturne/$STUDY.$CASE.$DATE
-  fi
-fi
-#
-# Create directory if necessary
-if [ "$RUN" != "$TMPDIR" ] ; then
-  if [ ! -d $RUN ] ; then
-    mkdir -p $RUN || exit 1
-  else
-    echo "RUN=$RUN already exists."
-    echo "The simulation will not be run."
-    exit 1
-  fi
-fi
-#
-# Create a temporary file for Salome (equivalent to "ficstp")
-if [ "$ARG_CS_OUTPUT" = "--log 0" ] ; then
-  echo $RUN > $SCRIPTS/runningstd.$DATE
-else
-  echo $RUN > $SCRIPTS/runningext.$DATE
-fi
-#
-cd $RUN
-#
-########################################################################
-#
-# Set up MPI environment
-#
-# Use makefile query to obtain the path to MPI binaries if those are
-# not on the default path. This is a peculiar use of make, but allows
-# us to avoid defining the MPI configuration in multiple files.
-
-CS_MPI_PATH=/home/saturne/opt/openmpi-1.3.1/arch/Linux_x86_64/bin
-
-# NUMBER_OF_PROCESSORS is determined here if not already set;
-# MPIHOSTS, MPIRUN, MPIBOOT, MPIHALT, and NUMBER_OF_NODES are
-# defined by the sourced script, and PATH may be updated.
-#
-. ${pkgdatadir}/runcase_mpi_env
-#
-# Check for the number of requested processors
-nproc_kernel="${NUMBER_OF_PROCESSORS}"
-echo
-echo
-if [ $SYRTHES_COUPLING = yes ] ; then
-  echo "Coupling of Code_Saturne and SYRTHES activated."
-  #  1 processor is reserved for SYRTHES if coupled through MPI.
-  if [ "$COUPLING_MODE" = "MPI" ] ; then
-    (( nproc_kernel = nproc_kernel - N_SYRTHES_COUPLINGS ))
-    if [ $nproc_kernel -lt 1 ] ; then
-      echo
-      echo
-      echo " Warning, if COUPLING_MODE = MPI, SYRTHES reserves 1 processor"
-      echo " (which need not be a physical processor)."
-      echo " Here, NUMBER_OF_PROCESSORS=${NUMBER_OF_PROCESSORS}, while it must"
-      echo " be strictly greater than 1."
-      echo " Increase the number of requested processors."
-      echo
-      exit 1
-    fi
-  fi
-fi
-if [ $nproc_kernel -gt 1 ] ; then
-  echo "Parallel Code_Saturne with partitioning in $nproc_kernel sub-domains"
-  if [ $SOLCOM = 1 ] ; then
-    echo
-    echo
-    echo " Parallel run impossible with SOLCOM = $SOLCOM "
-    echo " Use SOLCOM = 0 "
-    echo
-    exit 1
-  fi
-else
-  echo "Single processor Code_Saturne simulation"
-fi
-if [ ! -z "$MPIHOSTS" ] ; then
-  echo "Total number of processors: $NUMBER_OF_PROCESSORS"
-fi
-#
-# In parallel mode, the corresponding argument must be set
-if [ $nproc_kernel -gt 1 ] ; then
-  ARG_CS_MPI=" --mpi"
-else
-  ARG_CS_MPI=""
-fi
-#
-#
-########################################################################
-#
-# Communications
-#
-# To help debug coupling problems, make communication more verbose
-if [ ! -z "$ECHO_SYR_COMM" ] ; then
-  ECHOCOMMSYR="-echo-comm $ECHO_SYR_COMM"
-else
-  ECHOCOMMSYR=""
-fi
-########################################################################
-# Greeting message
-#
-echo ' '
-echo '                      Code_Saturne is running '
-echo '                      *********************** '
-echo ' '
-echo ' Working directory (to be periodically cleaned) : '
-echo '    ' $RUN
-#
-########################################################################
-#
-# Compilation and link
-#
-# Note: we also check the for the presence of certain user subroutines here.
-#
-echo
-echo ' Kernel version:          ' $prefix
-echo ' Preprocessor version:    ' $ecs_prefix
-
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  cur_dir=`pwd`
-
-  source_cas=$SRC
-
-  #
-  # Copy of the parameter file
-  if [ ! -z "$PARAM" ] ; then
-    var=$DATA/$PARAM
-    if [ -f $var ] ; then
-      COMMAND_PARAM="--param $PARAM"
-      cp $var .
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The parameters file ' $var
-      echo ' can not be accessed.'
-      exit 1
-    fi
-  fi
-
-  src_files=`ls ${source_cas}/*.[fF]90 ${source_cas}/*.[ch] 2>/dev/null`
-
-  if [ ! -z "${src_files}" ] ; then
-
-    echo
-    echo  "  ***************************************************************"
-    echo  "   Compilation of user subroutines and linking of Code_Saturne"
-    echo  "  ***************************************************************"
-
-    if [ -f compil.log ] ; then
-      rm -f compil.log
-    fi
-
-    src_dir="src_saturne"
-
-    # Copy of the user source files
-    # (no links: the directory is copied later)
-    mkdir ${src_dir}
-    for f in ${src_files} ; do
-      if [ -f $f ] ; then
-        cp ${f} ${src_dir}/
-      fi
-    done
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --source=$src_dir --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    # Compilation
-    if [ ! -z "${CS_LIB_ADD}" ] ; then
-      OPTLIBS="--opt-libs=${CS_LIB_ADD}"
-    fi
-    ${bindir}/cs compile \
-      --source=$src_dir ${OPTLIBS} 2>>$cur_dir/compil.log 1>&2
-    if [ $? -ne 0 ]
-    then
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-      echo "COMPILE OR LINK ERROR"
-      rm -f *.o
-      exit 1
-    else
-      cp $cur_dir/compil.log $RESU/compil.log.$SUFFIX
-    fi
-
-  else
-
-    # Detect presence and test for compatibility of modules.
-    if [ ! -z "$PARAM" ] ; then
-      ${bindir}/cs check_consistency --param=$PARAM --nproc=$nproc_kernel
-    else
-      ${bindir}/cs check_consistency --nproc=$nproc_kernel
-    fi
-    if [ $? = 1 ] ; then
-      exit 1
-    fi
-
-    ln -s ${bindir}/$EXE .
-
-  fi
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-
-    ${pkgdatadir}/runcase_syrthes -compile \
-      -cs-bindir=${bindir} -src-syr=${SRC_SYR} \
-      -src-copy=${RESU}/SRC_SYR.${SUFFIX} -log=${RESU}/compil_syrthes.log.${SUFFIX}
-
-  fi
-
-fi # EXEC_KERNEL = yes
-
-#
-########################################################################
-#
-# Data setup
-#
-echo
-echo  "  ********************************************"
-echo  "             Preparing calculation            "
-echo  "  ********************************************"
-echo
-#
-ERROR=false
-PREPROCESS_ERROR=false
-PARTITION_ERROR=false
-EXECUTION_ERROR=false
-#
-if [ $SOLCOM = 1 ]
-then
-  EXEC_PREPROCESS=no
-  EXEC_PARTITION=no
-  ln -s $MESHDIR/$MESH geomet || exit 1
-fi
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ]
-then
-  for var in $MESH ; do
-    ln -s $MESHDIR/$var $var || exit 1
-    # Special case for meshes in EnSight format: link to .geo file necessary
-    # (retrieve name through .case file)
-    var2=`basename $var .case`
-    if [ $var2 != $var ] ; then
-      ficgeo_ensight=`awk '/^model:/ {print $2}' $var`
-      ln -s $MESHDIR/$ficgeo_ensight $ficgeo_ensight || FIN
-    fi
-  done
-else
-  if [ -f ${PREPROCESSOR_OUTPUT_IN} ] ; then
-    ln -s ${PREPROCESSOR_OUTPUT_IN} preprocessor_output || exit 1
-  else
-    echo "Error: no preprocessor output file is available;"
-    echo "       (${PREPROCESSOR_OUTPUT_IN} does not exist."
-    echo "       or is not a standard file."
-    exit 1
-  fi
-fi
-#
-if [ $nproc_kernel -eq 1 -a "${EXEC_KERNEL}" = "yes" ] ; then
-  EXEC_PARTITION=no
-elif [ "${EXEC_PARTITION}" = "no" -a "${PARTITION_OUTPUT_IN}" != "" ]
-then
-  if [ -f ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} ] ; then
-    ln -s ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel} .
-  else
-    echo "Warning: no partitioning file is available;"
-    echo "         (no ${PARTITION_OUTPUT_IN}/domain_number_${nproc_kernel})."
-    echo
-    echo "         Unoptimized partitioning will be used."
-    echo "         Parallel performance may be degraded."
-  fi
-fi
-#
-if [ "${EXEC_KERNEL}" = "yes" ] ; then
-
-  for var in ${RESTART_IN}/* ; do
-    if [ -f $var ] ; then
-      varb=`basename $var`
-      if   [ $varb = suiava ] ; then
-        vara=suiamo
-      elif [ $varb = suiavx ] ; then
-        vara=suiamx
-      elif [ $varb = vorava ] ; then
-        vara=voramo
-      elif [ $varb = t1dava ] ; then
-        vara=t1damo
-      elif [ $varb = rayava ] ; then
-        vara=rayamo
-      elif [ $varb = lagava ] ; then
-        vara=lagamo
-      elif [ $varb = lasava ] ; then
-        vara=lasamo
-      else
-        vara=$varb
-      fi
-      ln -s $var $vara
-    fi
-  done
-  #
-  if [ "$THERMOCHEMISTRY_DATA" != "" ] ; then
-    var=$DATA/$THERMOCHEMISTRY_DATA
-    if [ -f $var ] ; then
-      cp $var dp_tch
-      # Copy so as to have correct name upon backup
-      if [ "$THERMOCHEMISTRY_DATA" != "dp_tch" ] ; then
-        cp dp_tch $THERMOCHEMISTRY_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The thermochemistry file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  if [ "$METEO_DATA" != "" ] ; then
-    var=$DATA/$METEO_DATA
-    if [ -f $var ] ; then
-      cp $var meteo
-      # Copy so as to have correct name upon backup
-      if [ "$METEO_DATA" != "meteo" ] ; then
-        cp meteo $METEO_DATA
-      fi
-    else
-      echo ' '
-      echo ' -- ERROR -- '
-      echo ' The meteo profile file ' $var
-      echo ' can not be accessed. '
-      exit 1
-    fi
-  fi
-  #
-  for f in uscpcl.f90 usd3pc.f90 usebuc.f90 uslwcc.f90 usfucl.f90
-  do
-    if [ -f "${SRC}/${f}" -a ! -f JANAF ] ; then
-      cp ${datadir}/data/thch/JANAF JANAF
-    fi
-  done
-  #
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    #
-    ${pkgdatadir}/runcase_syrthes -copy-data -syrthes-env=${DATA_SYR}/$SYRTHES_ENV
-    #
-  fi
-  #
-  if [ ! -z "$USER_INPUT_FILES" ] ; then
-    for f in $USER_INPUT_FILES ; do
-      cp $DATA/$f .
-    done
-  fi
-  #
-fi # EXEC_KERNEL = yes
-
-########################################################################
-# Maximum time for PBS (done here so as to leave time for PBS to
-# realize that things have started).
-#
-if [ "$PBS_JOBID" != "" ] ; then
-  CS_MAXTIME=`qstat -r $PBS_JOBID | grep $PBS_JOBID | sed -e's/ \{1,\}/ /g' | cut -d ' ' -f 9`
-  export CS_MAXTIME
-fi
-#
-########################################################################
-#
-# Summary: start
-#
-CURDATE=`unset LANG ; date`
-#
-echo '========================================================'>>$summary
-echo '   Start time       : ' $CURDATE                         >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Kernel          : ' $prefix                          >>$summary
-echo '    Preprocessor    : ' $ecs_prefix                      >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    HOMARD          : ' $homard_prefix                   >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    CS_MPI_PATH     : ' $CS_MPI_PATH                     >>$summary
-echo '    PATH            : ' $PATH                            >>$summary
-echo '    ------------------------------------------------  '  >>$summary
-echo '    User            : ' $USER                            >>$summary
-echo '========================================================'>>$summary
-echo '    Machine         : '                                  >>$summary
-     uname -a                                                  >>$summary
-if [ -z "$NUMBER_OF_PROCESSORS" ] ; then
-  echo '    N Procs         : ' 1                              >>$summary
-else
-  echo '    N Procs         : ' $NUMBER_OF_PROCESSORS          >>$summary
-fi
-if [ -z "$PROCESSOR_LIST" ] ; then
-  echo '    Processors      : ' default                        >>$summary
-else
-  echo '    Processors      : ' $PROCESSOR_LIST                >>$summary
-fi
-echo '========================================================'>>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Case            : ' $CASE                            >>$summary
-echo '      DATA          : ' $DATA                            >>$summary
-echo '      SRC           : ' $SRC                             >>$summary
-echo '      RESU          : ' $RESU                            >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-echo '    Exec. dir.      : ' $RUN                             >>$summary
-echo '  ----------------------------------------------------'  >>$summary
-if [ "$EXEC_PREPROCESSOR" = "yes" ] ; then
-  echo '    Preprocessor    : ' ${ecs_bindir}/cs_preprocess    >>$summary
-fi
-if [ "$EXEC_PARTITION" = "yes" ] ; then
-  echo '    Partitioner     : ' ${ecs_bindir}/cs_partition     >>$summary
-fi
-if [ "$EXEC_KERNEL" = "yes" ] ; then
-  echo '    Executable      : ' $EXE                           >>$summary
-fi
-echo '  ----------------------------------------------------'  >>$summary
-#
-# Execution
-echo
-echo  "  ********************************************"
-echo  "             Starting calculation"
-echo  "  ********************************************"
-echo
-#
-# Preprocessor start
-#
-if [ "${EXEC_PREPROCESS}" = "yes" ] ; then
-  #
-  ${ecs_bindir}/cs_preprocess --mesh $MESH "--case" $CASE \
-                   $COMMAND_REORIENT $COMMAND_JOIN $COMMAND_PERIO \
-                   > listpre 2>&1
-  if [ $? != 0 ] ; then
-    echo "Error running the preprocessor."
-    echo "Check preprocessor log (listpre) for details."
-    echo
-    PREPROCESS_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PREPROCESSOR_OUTPUT_OUT=$RESU/preprocessor_output.$SUFFIX
-    cp preprocessor_output ${PREPROCESSOR_OUTPUT_OUT}
-  fi
-  #
-fi
-#
-# Partitioner start
-#
-if [ ! -f ${ecs_bindir}/cs_partition ] ; then
-  echo "Warning: ${ecs_bindir}/cs_partition not found."
-  echo
-  echo "The partitioner may not have been installed"
-  echo "  (this is the case if neither METIS nor."
-  echo "  SCOTCH are avaialable)."
-  echo
-  echo "Unoptimized partitioning will be used, so"
-  echo "parallel performance may be degraded."
-  echo
-  EXEC_PARTITION=no
-fi
-#
-if [ "${EXEC_PARTITION}" = "yes" ] ; then
-  #
-  if [ "${EXEC_KERNEL}" = "yes" ] ; then
-    ${ecs_bindir}/cs_partition $nproc_kernel > listpart 2>&1
-  else
-    if [ -z "$PARTITION_LIST" ] ; then
-      echo "Error running the partitioner."
-      echo "PARTITION_LIST is not set."
-      echo "This variable should contain the number of processors"
-      echo "for which we partition (or a list of such numbers)."
-      PARTITION_ERROR=true
-      ERROR=true
-    else
-      ${ecs_bindir}/cs_partition $PARTITION_LIST > listpart 2>&1
-    fi
-  fi
-  if [ $? != 0 -a $PARTITION_ERROR = false ] ; then
-    echo "Error running the partitioner."
-    echo "Check partitioner log (listpart) for details."
-    echo
-    PARTITION_ERROR=true
-    ERROR=true
-  fi
-  #
-  if [ "${EXEC_KERNEL}" = "no" ] ; then
-    #
-    PARTITION_OUTPUT_OUT=$RESU/PARTITION_OUTPUT.$SUFFIX
-    mkdir $PARTITION_OUTPUT_OUT
-    cp -r domain_number_* ${PARTITION_OUTPUT_OUT}/
-  fi
-#
-fi
-#
-# Run calculation proper.
-#
-if [ "$ERROR" != "true" -a "$EXEC_KERNEL" = "yes" ] ; then
-#
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    # MPI Communication
-    #
-    # Make sure to transmit possible additional arguments assigned by mpirun to
-    # the executable with some MPI-1 implementations (vanilla MPICH 1.2 sets the
-    # parameters needed by MPI_Init through argc/argv): we use $@ to forward
-    # arguments passed to localexec to the true executable files.
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo "MPI_RANK=\`${pkgdatadir}/runcase_mpi_rank \$@\`" >> $localexec
-    echo cd $RUN >> $localexec
-    echo "if [ \$MPI_RANK -eq 0 ] ; then" >> $localexec
-    echo "  $RUN/$EXE_SYR \$@ -app-num 0 -comm-mpi 1 $ECHOCOMMSYR > listsyr 2>&1" >> $localexec
-    echo "else" >> $localexec
-    echo "  $VALGRIND $RUN/$EXE \$@ --mpi 1 $COMMAND_CWF "\
-         "$ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM " >> $localexec
-    echo "fi" >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    #
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  elif [ $SYRTHES_COUPLING = yes  ] ; then
-    # Socket communications
-    #
-    # We provide the executables with a "random" port number.
-    PORT=35623
-    SOCKETNCS="--syr-socket $PORT"
-    SOCKETSYR="-comm-socket $PORT"
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI $COMMAND_CWF "\
-                 " $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-                 " $COMMAND_PARAM $SOCKETNCS " >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true &
-    #
-    ./$EXE_SYR $ECHOCOMMSYR $SOCKETSYR > listsyr 2>&1
-    #
-    $MPIHALT
-    #
-  elif [ $SOLCOM = 0 ] ; then
-    #
-    localexec=$RUN/localexec
-    echo '#!/bin/sh' > $localexec
-    echo cd $RUN >> $localexec
-    echo "$VALGRIND $RUN/$EXE \$@ $ARG_CS_MPI "\
-         " $COMMAND_CWF $ARG_CS_VERIF $ARG_CS_OUTPUT "\
-         " $COMMAND_PARAM "  >> $localexec
-    echo "retour=\$?" >> $localexec
-    echo "exit \$retour" >> $localexec
-    chmod 700 $localexec
-    $MPIBOOT
-    $MPIRUN $localexec || EXECUTION_ERROR=true
-    $MPIHALT
-    #
-  else # cas SOLCOM = 1
-    #
-    $VALGRIND $RUN/$EXE --solcom \
-          $ARG_CS_VERIF $ARG_CS_OUTPUT $COMMAND_PARAM \
-          || EXECUTION_ERROR=true
-    #
-  fi
-#
-fi
-#
-# Remove the Salome temporary files
-rm -f $SCRIPTS/running*.$DATE
-#
-########################################################################
-#
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  if [ "$SYRTHES_COUPLING" = "yes" -a "$COUPLING_MODE" = "MPI" ] ; then
-    echo "Error running the coupled calculation."
-    echo "Either the Kernel or SYRTHES may have failed."
-    echo
-    echo "Check Kernel log (listing) and SYRTHES log (listsyr) for details,"
-    echo "as well as eventual error* files."
-    echo
-  else
-    echo "Error running the calculation."
-    echo
-    echo "Check Kernel log (listing) and error* files for details"
-    echo
-  fi
-  ERROR=true
-fi
-#
-# Treatment of the ouput files:
-#   Starts with the restart files
-#   (in case of full disk, increases chances of being able to continue).
-#
-if [ $EXEC_KERNEL = yes ] ; then
-
-  RESTART_OUT=$RESU/RESTART.$SUFFIX
-  iok=1
-  mkdir ${RESTART_OUT} || iok=0
-  if [ $iok = 1 ] ; then
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f ${RESTART_OUT}
-      fi
-    done
-  else
-    for f in suiava suiavx t1dava vorava rayava lagava* lasava* ; do
-      if [ -f $f ] ; then
-        cp $f $RESU/$f.$SUFFIX
-      fi
-    done
-  fi
-
-  resuser=0
-  for f in ${USER_OUTPUT_FILES} ; do
-    if [ -f $f ] ; then
-      resuser=1
-    fi
-  done
-  if [ ${resuser} = 1 ] ; then
-    RES_USER=$RESU/RES_USER.$SUFFIX
-    iok=1
-    mkdir ${RES_USER} || iok=0
-    if [ $iok = 1 ] ; then
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f ${RES_USER}
-        fi
-      done
-    else
-      for f in ${USER_OUTPUT_FILES} ; do
-        if [ -f $f ] ; then
-          cp $f $RESU/$f.$SUFFIX
-        fi
-      done
-    fi
-  fi
-
-  for f in $PARAM $THERMOCHEMISTRY_DATA $METEO_DATA ; do
-    if [ -f $f ] ; then
-      cp $f $RESU/$f.$SUFFIX
-    fi
-  done
-
-  for f in probes_*.dat ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-  for f in ush* ; do
-    if [ -f $f ] ; then
-      if [ ! -d $RESU/HIST.$SUFFIX ] ; then
-        mkdir $RESU/HIST.$SUFFIX
-      fi
-      cp $f $RESU/HIST.$SUFFIX
-    fi
-  done
-
-fi  # output files
-
-for f in list* error* *.med *.cgns ; do
-  if [ -f $f ] ; then
-    cp $f $RESU/$f.$SUFFIX
-  fi
-done
-
-# Treatment of EnSight and MED files
-#   The $dir (=*.ensight and/or *.med) directories are copied
-#   to $DIR.$SUFFIX
-
-#   We place directories $dir (=*.ensight and/or *.med)
-#   in $DIR.$SUFFIX
-
-cas=`echo $CASE |tr "[:upper:]" "[:lower:]"`
-
-for dir in *.ensight *.med ; do
-  if [ -d $dir ] ; then
-    DIR=`echo $dir |tr "[:lower:]" "[:upper:]"`
-    mkdir $RESU/$DIR.$SUFFIX
-    if [ $? -ne 0 ] ; then
-      echo Creating $RESU/$DIR.$SUFFIX failed
-    else
-      for f in $dir/*  ; do
-        if [ -f $f ] ; then
-          cp -R ${f} $RESU/$DIR.$SUFFIX/.
-        fi
-      done
-    fi
-  fi
-done
-
-if [ $EXEC_KERNEL = yes ] ; then
-
-  rayt_list=`ls bord* 2>/dev/null`
-  if [ ! -z "${rayt_list}" ] ; then
-    for f in $rayt_list ; do
-      if [ ! -d $RESU/CHR.$SUFFIX ] ; then
-        mkdir $RESU/CHR.$SUFFIX
-      fi
-      cp $f $RESU/CHR.$SUFFIX/.
-    done
-  fi
-
-  lagr_list=`ls debug* deplacement* trajectoire* frontiere* 2>/dev/null`
-  if [ ! -z "${lagr_list}" ] ; then
-    mkdir $RESU/LAGR.$SUFFIX
-    for f in $lagr_list ; do
-      cp $f $RESU/LAGR.$SUFFIX
-    done
-  fi
-
-  # Matisse output files
-  if [ -f ${RUN}/resuMatisse ] ; then
-    matisse=`grep -i matisse $DATA/$PARAM`
-    if [ ! -z "$matisse" ] ; then
-  # The date is added to the first line of resuMatisse
-      AFDATE="Date of the case                                       : "$DATE
-      sed  "1i\ ${AFDATE}" ${RUN}/resuMatisse >> ${RUN}/resuMatisse.mod
-      mv ${RUN}/resuMatisse.mod ${RUN}/resuMatisse
-    fi
-    cp ${RUN}/resuMatisse ${RESU}/resuMatisse.$SUFFIX
-  fi
-
-  for dir in src_saturne ; do
-    if [ -d $dir ] ; then
-      mkdir $RESU/SRC.$SUFFIX
-      if [ $? -ne 0 ] ; then
-        echo Failure creating $RESU/SRC.$SUFFIX
-      else
-        for f in $dir/*.[fF]90 $dir/*.[ch] ; do
-          if [ -f ${f} ] ; then
-            cp -R ${f} $RESU/SRC.$SUFFIX/.
-            fbase=`basename ${f}`
-            chmod a-w $RESU/SRC.$SUFFIX/${fbase}
-          fi
-        done
-      fi
-    fi
-  done
-
-  if [ $SYRTHES_COUPLING = yes ] ; then
-    ${pkgdatadir}/runcase_syrthes -copy-results \
-      -result-dir=${RESU}/RESU_SYR.${SUFFIX}
-  fi
-
-fi  # input data and outputs
-#
-########################################################################
-#
-# Summary: end
-#
-if  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  EXEC_PREPROCESS="failed"
-fi
-echo "    Preprocessing   : " $EXEC_PREPROCESS                 >>$summary
-if  [ "$PARTITION_ERROR" = "true" ] ; then
-  EXEC_PARTITION="failed"
-fi
-echo "    Partitioning    : " $EXEC_PARTITION                  >>$summary
-if  [ "$EXECUTION_ERROR" = "true" ] ; then
-  EXEC_KERNEL="failed"
-fi
-echo "    Calculation     : " $EXEC_KERNEL                     >>$summary
-#
-CURDATE=`unset LANG ; date`
-#
-echo '  ----------------------------------------------------'  >>$summary
-echo '   Finish time      : ' $CURDATE                         >>$summary
-echo '========================================================'>>$summary
-#
-cp $summary  $RESU/$summary.$SUFFIX
-#
-########################################################################
-#
-#
-# Finish
-#
-echo
-echo  "  ********************************************"
-if [ "$EXECUTION_ERROR" = "true" ] ; then
-  echo  "         Error in calculation stage."
-elif  [ "$PARTITION_ERROR" = "true" ] ; then
-  echo  "         Error in partitioning stage."
-elif  [ "$PREPROCESS_ERROR" = "true" ] ; then
-  echo  "         Error in preprocessing stage."
-else
-  echo  "           Normal simulation finish"
-fi
-echo  "  ********************************************"
-
-if [ "$ERROR" = "true" ] ; then
-  exit 1
-else
-  exit 0
-fi
-#
-########################################################################
diff --git a/examples/3-stratified_junction/case5/usdpst.f90 b/examples/3-stratified_junction/case5/usdpst.f90
index 5962aed..db5e35e 100644
--- a/examples/3-stratified_junction/case5/usdpst.f90
+++ b/examples/3-stratified_junction/case5/usdpst.f90
@@ -1,12 +1,12 @@
 !-------------------------------------------------------------------------------
 
-!                      Code_Saturne version 2.0.0-beta1
+!                      Code_Saturne version 2.0.0-rc1
 !                      --------------------------
 
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2008 EDF S.A., France
+!     Copyright (C) 1998-2009 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -28,7 +28,7 @@
 
 !-------------------------------------------------------------------------------
 
-subroutine  usdpst &
+subroutine usdpst &
 !=================
 
  ( idbia0 , idbra0 ,                                              &
@@ -43,78 +43,75 @@ subroutine  usdpst &
    rdevel , rtuser , ra     )
 
 !===============================================================================
-! FONCTION :
-! --------
+! Purpose:
+! -------
 
-! ROUTINE UTILISATEUR POUR LOCALISER DES CELLULES, DES FACES
-! INTERNES ET/OU DES FACES DE BORD DEFINISSANT UN MAILLAGE DE
-! POST-TRAITEMENT.
+!    User subroutine.
+
+! Define additional post-processing writers and meshes.
+!
+! Post-processing writers allow outputs in different formats or with
+! different format options and output frequancy than the default writer.
+!
+! Post-processing meshes are defined as a subset of the main meshe's
+! cells or faces (interior and boundary).
 
 !-------------------------------------------------------------------------------
 ! Arguments
 !__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
+! name             !type!mode ! role                                           !
 !__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! (nfml,nprfml)    !    !     !                                                !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (nfac+1)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (lndfac)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!  (nfabor+1)      !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (lndfbr  )     !    !     !  (optionnel)                                   !
-! lstcel           ! te ! --- ! tableau de travail (liste des                  !
-! (ncelet)         !    !     !  cellules d'un maillage de sortie)             !
-! lstfac           ! te ! --- ! tableau de travail (liste des faces            !
-! (nfac)           !    !     !  internes d'un maillage de sortie)             !
-! lstfbr           ! te ! --- ! tableau de travail (liste des faces            !
-! (nfabor)         !    !     !  de bord d'un maillage de sortie)              !
-! ia(*)            ! te ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet          !    !     !                                                !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
+! idbia0           ! i  ! <-- ! number of first free position in ia            !
+! idbra0           ! i  ! <-- ! number of first free position in ra            !
+! ndim             ! i  ! <-- ! spatial dimension                              !
+! ncelet           ! i  ! <-- ! number of extended (real + ghost) cells        !
+! ncel             ! i  ! <-- ! number of cells                                !
+! nfac             ! i  ! <-- ! number of interior faces                       !
+! nfabor           ! i  ! <-- ! number of boundary faces                       !
+! nfml             ! i  ! <-- ! number of families (group classes)             !
+! nprfml           ! i  ! <-- ! number of properties per family (group class)  !
+! nnod             ! i  ! <-- ! number of vertices                             !
+! lndfac           ! i  ! <-- ! size of nodfac indexed array                   !
+! lndfbr           ! i  ! <-- ! size of nodfbr indexed array                   !
+! nideve, nrdeve   ! i  ! <-- ! sizes of idevel and rdevel arrays              !
+! nituse, nrtuse   ! i  ! <-- ! sizes of ituser and rtuser arrays              !
+! ifacel(2, nfac)  ! ia ! <-- ! interior faces -> cells connectivity           !
+! ifabor(nfabor)   ! ia ! <-- ! boundary faces -> cells connectivity           !
+! ifmfbr(nfabor)   ! ia ! <-- ! boundary face family numbers                   !
+! ifmcel(ncelet)   ! ia ! <-- ! cell family numbers                            !
+! iprfml           ! ia ! <-- ! property numbers per family                    !
+!  (nfml, nprfml)  !    !     !                                                !
+! ipnfac(nfac+1)   ! ia ! <-- ! interior faces -> vertices index (optional)    !
+! nodfac(lndfac)   ! ia ! <-- ! interior faces -> vertices list (optional)     !
+! ipnfbr(nfabor+1) ! ia ! <-- ! boundary faces -> vertices index (optional)    !
+! nodfbr(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
+! lstcel(ncelet)   ! ia ! --- ! work array (list of cells)                     !
+! lstfac(nfac)     ! ia ! --- ! work array (list of interior faces)            !
+! lstfbr(nfabor)   ! ia ! --- ! work array (list of boundary faces)            !
+! idevel(nideve)   ! ia ! <-> ! integer work array for temporary development   !
+! ituser(nituse)   ! ia ! <-> ! user-reserved integer work array               !
+! ia(*)            ! ia ! --- ! main integer work array                        !
+! xyzcen           ! ra ! <-- ! cell centers                                   !
+!  (ndim, ncelet)  !    !     !                                                !
+! surfac           ! ra ! <-- ! interior faces surface vectors                 !
+!  (ndim, nfac)    !    !     !                                                !
+! surfbo           ! ra ! <-- ! boundary faces surface vectors                 !
+!  (ndim, nfabor)  !    !     !                                                !
+! cdgfac           ! ra ! <-- ! interior faces centers of gravity              !
+!  (ndim, nfac)    !    !     !                                                !
+! cdgfbo           ! ra ! <-- ! boundary faces centers of gravity              !
+!  (ndim, nfabor)  !    !     !                                                !
+! xyznod           ! ra ! <-- ! vertex coordinates (optional)                  !
+!  (ndim, nnod)    !    !     !                                                !
+! volume(ncelet)   ! ra ! <-- ! cell volumes                                   !
+! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
+! rtuser(nrtuse)   ! ra ! <-> ! user-reserved real work array                  !
+! ra(*)            ! ra ! --- ! main real work array                           !
 !__________________!____!_____!________________________________________________!
 
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
 !===============================================================================
 
 implicit none
@@ -122,7 +119,7 @@ implicit none
 !===============================================================================
 
 !===============================================================================
-!     DONNEES EN COMMON
+! Common blocks
 !===============================================================================
 
 include "paramx.h"
@@ -157,9 +154,9 @@ double precision xyznod(ndim,nnod), volume(ncelet)
 double precision rdevel(nrdeve), rtuser(nrtuse)
 double precision ra(*)
 
-! VARIABLES LOCALES
+! Local variables
 
-integer          indmod, icas, nbcas, ipart, nbpart, ipref
+integer          indmod, icas, nbcas, ipart, nbpart, ipref, icat
 integer          ntchrl
 
 integer          nlcel, nlfac , nlfbr
@@ -171,7 +168,6 @@ character*96     nomrep, optfmt
 
 double precision xfac  , yfac  , zfac
 
-
 !===============================================================================
 
 
@@ -179,118 +175,121 @@ double precision xfac  , yfac  , zfac
 nbcas  = 0
 nbpart = 0
 
-! Entiers "pointeurs" sur la premiere case libre de IA et RA
+! "pointeurs" to the first free positions in 'ia' and 'ra'
 
 idebia = idbia0
 idebra = idbra0
 
 !===============================================================================
-!     CREATION DES GESTIONNAIRES D'ECRITURE POUR LE POST TRAITEMENT
-!         (UN PAR CAS ET PAR FORMAT, A RENSEIGNER PAR L'UTILISATEUR)
+! Create output writers for post-processing
+! (one per case and per format, to be adapted by the user)
 !===============================================================================
 
-!     NOMBRE DE GESTIONNAIRES (case au sens EnSight, etude au sens MED,
-!                              ou racine d'une arborescence CGNS)
+! Number of writers (case in the EnSight sense, study in the MED sense,
+!                    or root of a CGNS tree)
 
 nbcas = 1
 
 do icas = 1, nbcas
 
-!       INITIALISATIONS DIVERSES
+  ! Miscellaneous initializations
 
   do ii = 1, len(nomcas)
-    NOMCAS (II:II) = ' '
+    nomcas (II:II) = ' '
   enddo
   do ii = 1, len(nomrep)
-    NOMREP (II:II) = ' '
+    nomrep (ii:ii) = ' '
   enddo
   do ii = 1, len(nomfmt)
-    NOMFMT (II:II) = ' '
+    nomfmt (ii:ii) = ' '
   enddo
   do ii = 1, len(optfmt)
-    OPTFMT (II:II) = ' '
+    optfmt (ii:ii) = ' '
   enddo
 
-!       DEFINITION UTILISATEUR :
-
-!       NOMCAS et NOMREP indiquent respectivement le prefixe du nom
-!       des fichiers et le repertoire correspondant.
-!       Si NOMREP est de la forme xxxx.ensight ou xxxx.med, le lanceur le
-!       rapatriera automatiquement sous le nom XXXX.ENSIGHT.$DATE ou
-!       XXXX.MED.$DATE dans le repertoire RESU. Si NOMREP est d'une autre
-!       forme, il faudra gerer son rapatriement a la main.
-
-!       NOMFMT permet de choisir le format de sortie
-!       ("EnSight Gold", "MED_fichier", ou "CGNS").
-
-!       OPTFMT permet de fournir des options specifiques au format de
-!       sortie (separees par des virgules) ;
-!         Pour EnSight : "text" ou "binary" (defaut),
-!         Pour EnSight, MED, ou CGNS :
-!                        "discard_polygons" pour supprimer les polygones,
-!                        "discard_polyhedra" pour supprimer les polyedres.
-!         Pour EnSight  ou MED :
-!                        "divide_polygons" pour d�couper les polygones,
-!                        "divide_polyhedra" pour d�couper les polyedres.
-
-!       INDMOD indique si les maillages ecrits seront :
-!         0 : fixes,
-!         1 : deformables a topologie constante,
-!         2 : modifiables (pourront etre completement redefinis en
-!             cours de calcul via le sous-programme USMPST).
-!        10 : comme INDMOD = 0, avec champ de d�placement
-!        11 : comme INDMOD = 1, avec champ de d�placement
-!        12 : comme INDMOD = 2, avec champ de d�placement
-
-!       NTCHRL donne la frequence de sortie par defaut associee,
-!       (la sortie a un pas de temps donne pouvant etre forcee ou
-!       empechee via le sous-programme utilisateur USNPST).
+  ! User definition:
+
+  ! 'nomcas' and 'nomrep' respectively define the file names prefix and
+  ! the corresponding directory path.
+  ! If 'nomrep' is a local name of the "xxxx.ensight" or "xxxx.med" form,
+  ! the script will automatically retreive the results to the 'RESU'
+  ! directory, under a name such as XXXX.ENSIGHT.$DATE or XXXX.MED.$DATE.
+  ! If 'nomrep' is of another form, it will have to be defined as a
+  ! generic user output dire or directory so as to be copied.
+
+  ! A user may also defined 'nomrep' as an absolute path, outside of the
+  ! execution directory, in which case the results are output directly
+  ! to that directory, and not managed by the script.
+
+  ! 'nomfmt' allows choosing the output format ("EnSight Gold",
+  ! "MED_fichier", or "CGNS").
+
+  ! 'optfmt' allows the addition of a list of comma-separated
+  ! format-specific output options:
+  ! - EnSight:
+  !      "text" ou "binary" (default),
+  ! - EnSight, MED, or CGNS:
+  !     "discard_polygons" to ignore polygons in output.
+  !     "discard_polyhedra" to ignore polyhedra in output.
+  ! - EnSight or MED :
+  !     "divide_polygons" to divide polygons into triangles
+  !     "divide_polyhedra" to divide polyhedra into tetrahedra and pyramids
+
+  ! 'indmod' indicates if the meshes output using this writer will be:
+  !     0: fixed,
+  !     1: deformables with constant topology constante,
+  !     2 : modifyable (may be redefined during the calculation through
+  !         the 'usmpst' user subroutine).
+  !     10: as indmod = 0, with a vertex displacement field
+  !     11: as indmod = 1, with a vertex displacement field
+  !     12: as indmod = 2, with a vertex displacement field
+
+  ! 'ntchrl' defines the default output frequency (output at a specific
+  ! time may still be forced or inhibited using the 'usnpst' user subroutine).
 
   if (icas .eq. 1) then
 
-    NOMCAS = 'chr'
-    NOMREP = 'TINF21.ensight'
-    NOMFMT = 'EnSight Gold'
-    OPTFMT = 'binary, discard_polygons'
+    nomcas = 'chr'
+    nomrep = 'tinf21.ensight'
+    nomfmt = 'EnSight Gold'
+    optfmt = 'binary, discard_polygons'
     indmod = 2
     ntchrl = 5
-
   endif
 
-!       DEFINITION EFFECTIVE
+  ! Create writer
 
-  call pstcwr (icas  , nomcas, nomrep, nomfmt, optfmt, &
+  call pstcwr (icas  , nomcas, nomrep, nomfmt, optfmt, indmod, ntchrl)
   !==========
-               indmod, ntchrl)
 
 enddo
 
-!===============================================================================
-!     NOMBRE DE MAILLAGES EXTRAITS POUR POST TRAITEMENT
-!         A RENSEIGNER PAR L'UTILISATEUR
-!===============================================================================
+! Define number of additional postprocessing output meshes
+!=========================================================
 
-!   NBPART est le nombre de "parts" qui seront generees
-!   (au sens EnSight ; les �quivalents MED et CGNS sont le maillage
-!    et la base respectivement)
+! 'nbpart' is the number of parts which will be generated (in the EnSight
+! sense; the MED and CGNS equivalent terms are mesh and base respectively).
 
-!   Une "part" peut etre tout volume ou surface que l'on definira par
-!   l'identification des cellules ou faces du maillage
+! A "part" may be any volume or surface defined through a selection of the
+! main meshe's cells of faces.
 
+! Example:
+!
+! 4 "parts", correspondant respectivey to a mixed "interior faces"
+! / "exterior faces" extraction, an extraction containing only
+! interior faces, and 2 time-varying mesh pieces.
+
+! We will later add a 5th "part", which is an alias of the second.
 
 nbpart = 2
 
-!===============================================================================
-!     DEBUT DE LA BOUCLE SUR LES PARTS DEFINIES PAR L'UTILISATEUR
-!===============================================================================
+! Start of loop on user-defined parts
+!====================================
 
 do ipart = 1, nbpart
 
-
-!===============================================================================
-!       INITIALISATIONS DIVERSES
-!         PAS D'INTERVENTION UTILISATEUR REQUISE
-!===============================================================================
+  ! Miscellaneous initializations
+  !==============================
 
   nlcel = 0
   nlfac = 0
@@ -306,98 +305,80 @@ do ipart = 1, nbpart
   enddo
 
   do ii = 1, len(nommai)
-    NOMMAI(II:II) = ' '
+    nommai(ii:ii) = ' '
   enddo
 
-!===============================================================================
-!       REPERAGE DES CELLULES OU FACES INCLUSES DANS LE MAILLAGE
-!         A RENSEIGNER PAR L'UTILISATEUR
-!===============================================================================
-
-!       Ce sous programme est appele avant la definition des
-!        conditions aux limites
+  ! Mark cells or faces included in the mesh (to be adapted by the user)
+  !=====================================================================
 
+  ! Note that this subroutine is called before boundary conditions
+  ! are defined.
 
-!       POUR LA 1ere COUPE (PART 1) : coupe exemple
-
-!         Exemple : on selectionne
-!                   les faces internes sur le plan median
+  ! Part 1:
+  !   We select interior faces separating cells with color 2 from cells
+  !   with color 3, as well as boundary faces of color 4.
 
   if (ipart .eq. 1) then
 
-    NOMMAI = 'Coupe'
+    nommai = 'Cut 1'
 
-!         Pour les faces internes
+!         internal faces
 
     do ifac = 1, nfac
 
-!           Determination si la face appartient a la coupe
+!         look if the face belongs to the cut
 
       if (abs(cdgfac(2,ifac)).lt.1.d-4) then
         nlfac = nlfac+1
         lstfac(nlfac)= ifac
       endif
-
     enddo
-
-
-
-
-!       POUR LA 2eme COUPE (PART 2) : cellules a T<21 degres
-
-!         Exemple : on initialise a NCELET, le choix
-!                   des cellules sera fait dans usmpst.F
-
-  else if (ipart .eq. 2) then
-
-    NOMMAI = 'celTinf21'
-
-!         Si NLCEL = NCELET, pas la peine de definir LSTCEL
-
-    nlcel = ncelet
-
+!
+!   Second cut (part 2) : cells at T < 21 degree
+!
+!   Example : ncelet is initialised, the choice of cells will be done in usmpst.f90
+
+  elseif(ipart .eq. 2) then
+!
+        nommai = 'celTinf21'
+        nlcel = ncelet
+!
   endif
 
-!===============================================================================
-!       CREATION DES STRUCTURES CONSERVANT LES DONNEES DES PARTS
-!         PAS D'INTERVENTION UTILISATEUR REQUISE
-!===============================================================================
+  ! Create post-processing mesh
+  !============================
 
   call pstcma (ipart, nommai, nlcel, nlfac, nlfbr, lstcel, lstfac, lstfbr)
   !==========
 
-!===============================================================================
-!       IDENTIFICATION DU MAILLAGE EXTRAIT ET GESTION DE SORTIE
-!         A RENSEIGNER PAR L'UTILISATEUR
-!===============================================================================
+  ! Associate extracted mesh and writer (to be adapted by the user)
+  !================================================================
 
-  if (ipart .eq. 1) then
+  if ( ipart .eq. 1 ) then
 
-!         Le maillage 1 est associe a la sortie standard (ICAS=-1)
+    ! Associate post-processing mesh 1 with standard output (icas= -1).
     icas = -1
     call pstass(ipart, icas)
-    !==========
 
-  else if (ipart .eq. 2) then
+  elseif ( ipart .eq. 2 ) then
 
-!         Le maillage 2 est associe au cas cree ici (ICAS=1)
+    ! Associate post-processing mesh 2 with case created here (icas= 1) .
     icas = 1
     call pstass(ipart, icas)
     !==========
 
   endif
 
-!===============================================================================
-!     FIN   DE LA BOUCLE SUR LES PARTS DEFINIES PAR L'UTILISATEUR
-!===============================================================================
+  ! End of loop on user-defined parts
+  !==================================
 
 enddo
 
+
 return
 
 !===============================================================================
-!     FORMATS
+! Formats
 !===============================================================================
 
-end
-
+end subroutine
diff --git a/examples/3-stratified_junction/case5/usmpst.f90 b/examples/3-stratified_junction/case5/usmpst.f90
index 596efea..ec5cd8f 100644
--- a/examples/3-stratified_junction/case5/usmpst.f90
+++ b/examples/3-stratified_junction/case5/usmpst.f90
@@ -1,12 +1,12 @@
 !-------------------------------------------------------------------------------
 
-!                      Code_Saturne version 2.0.0-beta1
+!                      Code_Saturne version 2.0.0-rc1
 !                      --------------------------
 
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2008 EDF S.A., France
+!     Copyright (C) 1998-2009 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -45,120 +45,108 @@ subroutine usmpst &
    dt     , rtpa   , rtp    , propce , propfa , propfb ,          &
    coefa  , coefb  , statis ,                                     &
    tracel , trafac , trafbr , rdevel , rtuser , ra     )
+
 !===============================================================================
-! FONCTION :
-! --------
-
-! ROUTINE UTILISATEUR POUR LA MODIFICATION DES LISTES DE CELLULES
-! OU FACES INTERNES ET DE BORD DEFINISSANT UN MAILLAGE DE POST
-! TRAITEMENT EXISTANT ; CETTE ROUTINE EST APPELEE AUX PAS DE
-! TEMPS AUQUEL CE MAILLAGE EST ACTIF, ET UNIQUEMENT POUR LES
-! MAILLAGES POST UTILISATEUR PRINCIPAUX (NON ALIAS), SI TOUS LES
-! "WRITERS" ASSOCIES A CE MAILLAGE OU SES ALIAS PERMETTENT
-! CETTE MODIFICATION
+! Purpose:
+! -------
+
+!    User subroutine.
+
+! Modify list of cells or faces defining an existing post-processing
+! output mesh; this subroutine is called for true (non-alias) user meshes,
+! for each time step at which output on this mesh is active, and only if
+! all writers associated with this mesh allow mesh modification
+! (i.e. were defined with 'indmod' = 2 or 12).
+
 !-------------------------------------------------------------------------------
 ! Arguments
 !__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
+! name             !type!mode ! role                                           !
 !__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ipart            ! e  ! <-- ! numero du maillage post                        !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! ncelbr           ! e  ! <-- ! nombre d'elements ayant au moins une           !
-!                  !    !     ! face de bord                                   !
-! nvar             ! e  ! <-- ! nombre total de variables                      !
-! nscal            ! e  ! <-- ! nombre total de scalaires                      !
-! nphas            ! e  ! <-- ! nombre de phases                               !
-! nvlsta           ! e  ! <-- ! nombre de variables stat. lagrangien           !
-! ncelps           ! e  ! <-- ! nombre de cellules du maillage post            !
-! nfacps           ! e  ! <-- ! nombre de faces interieur post                 !
-! nfbrps           ! e  ! <-- ! nombre de faces de bord post                   !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! imodif           ! e  ! <-- ! 0 si maillage non modifie par cette            !
-!                  !    !     ! fonction, 1 si modifie                         !
-! itypps(3)        ! te ! <-- ! indicateur de presence (0 ou 1) de             !
-!                  !    !     ! cellules (1), faces (2), ou faces de           !
-!                  !    !     ! de bord (3) dans le maillage post              !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! nfml  ,nprfml    !    !     !                                                !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfac)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (nfac+1)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfbr)       !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (nfabor+1)     !    !     !  (optionnel)                                   !
-! lstcel(ncelps    ! te ! <-- ! liste des cellules du maillage post            !
-! lstfac(nfacps    ! te ! <-- ! liste des faces interieures post               !
-! lstfbr(nfbrps    ! te ! <-- ! liste des faces de bord post                   !
-! idevel(nideve    ! te ! <-- ! tab entier complementaire developemt           !
-! ituser(nituse    ! te ! <-- ! tab entier complementaire utilisateur          !
-! ia(*)            ! te ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet)         !    !     !                                                !
-! dt(ncelet)       ! tr ! <-- ! pas de temps                                   !
-! rtp, rtpa        ! tr ! <-- ! variables de calcul au centre des              !
-! (ncelet,*)       !    !     !    cellules (instant courant ou prec)          !
-! propce           ! tr ! <-- ! proprietes physiques au centre des             !
-! (ncelet,*)       !    !     !    cellules                                    !
-! propfa           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfac,*)        !    !     !    faces internes                              !
-! propfb           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! coefa, coefb     ! tr ! <-- ! conditions aux limites aux                     !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! statis           ! tr ! <-- ! statistiques (lagrangien)                      !
-!ncelet,nvlsta)    !    !     !                                                !
-! tracel(*)        ! tr ! <-- ! tab reel valeurs cellules post                 !
-! trafac(*)        ! tr ! <-- ! tab reel valeurs faces int. post               !
-! trafbr(*)        ! tr ! <-- ! tab reel valeurs faces bord post               !
-! rdevel(nrdeve    ! tr ! <-- ! tab reel complementaire developemt             !
-! rtuser(nrtuse    ! tr ! <-- ! tab reel complementaire utilisateur            !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
+! idbia0           ! i  ! <-- ! number of first free position in ia            !
+! idbra0           ! i  ! <-- ! number of first free position in ra            !
+! ipart            ! i  ! <-- ! number of the post-processing mesh (< 0 or > 0)!
+! ndim             ! i  ! <-- ! spatial dimension                              !
+! ncelet           ! i  ! <-- ! number of extended (real + ghost) cells        !
+! ncel             ! i  ! <-- ! number of cells                                !
+! nfac             ! i  ! <-- ! number of interior faces                       !
+! nfabor           ! i  ! <-- ! number of boundary faces                       !
+! nfml             ! i  ! <-- ! number of families (group classes)             !
+! nprfml           ! i  ! <-- ! number of properties per family (group class)  !
+! nnod             ! i  ! <-- ! number of vertices                             !
+! lndfac           ! i  ! <-- ! size of nodfac indexed array                   !
+! lndfbr           ! i  ! <-- ! size of nodfbr indexed array                   !
+! ncelbr           ! i  ! <-- ! number of cells with faces on boundary         !
+! nvar             ! i  ! <-- ! total number of variables                      !
+! nscal            ! i  ! <-- ! total number of scalars                        !
+! nphas            ! i  ! <-- ! number of phases                               !
+! nvlsta           ! i  ! <-- ! number of Lagrangian statistical variables     !
+! ncelps           ! i  ! <-- ! number of cells in post-processing mesh        !
+! nfacps           ! i  ! <-- ! number of interior faces in post-process. mesh !
+! nfbrps           ! i  ! <-- ! number of boundary faces in post-process. mesh !
+! nideve, nrdeve   ! i  ! <-- ! sizes of idevel and rdevel arrays              !
+! nituse, nrtuse   ! i  ! <-- ! sizes of ituser and rtuser arrays              !
+! imodif           ! i  ! --> ! 0 if the mesh was not modified by this call,   !
+!                  !    !     ! 1 if it has been modified.                     !
+! itypps(3)        ! ia ! <-- ! global presence flag (0 or 1) for cells (1),   !
+!                  !    !     ! interior faces (2), or boundary faces (3) in   !
+!                  !    !     ! post-processing mesh                           !
+! ifacel(2, nfac)  ! ia ! <-- ! interior faces -> cells connectivity           !
+! ifabor(nfabor)   ! ia ! <-- ! boundary faces -> cells connectivity           !
+! ifmfbr(nfabor)   ! ia ! <-- ! boundary face family numbers                   !
+! ifmcel(ncelet)   ! ia ! <-- ! cell family numbers                            !
+! iprfml           ! ia ! <-- ! property numbers per family                    !
+!  (nfml, nprfml)  !    !     !                                                !
+! ipnfac(nfac+1)   ! ia ! <-- ! interior faces -> vertices index (optional)    !
+! nodfac(lndfac)   ! ia ! <-- ! interior faces -> vertices list (optional)     !
+! ipnfbr(nfabor+1) ! ia ! <-- ! boundary faces -> vertices index (optional)    !
+! nodfbr(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
+! lstcel(ncelps)   ! ia ! --> ! list of cells in post-processing mesh          !
+! lstfac(nfacps)   ! ia ! --> ! list of interior faces in post-processing mesh !
+! lstfbr(nfbrps)   ! ia ! --> ! list of boundary faces in post-processing mesh !
+! idevel(nideve)   ! ia ! <-> ! integer work array for temporary development   !
+! ituser(nituse)   ! ia ! <-- ! user-reserved integer work array               !
+! ia(*)            ! ia ! --- ! main integer work array                        !
+! xyzcen           ! ra ! <-- ! cell centers                                   !
+!  (ndim, ncelet)  !    !     !                                                !
+! surfac           ! ra ! <-- ! interior faces surface vectors                 !
+!  (ndim, nfac)    !    !     !                                                !
+! surfbo           ! ra ! <-- ! boundary faces surface vectors                 !
+!  (ndim, nfabor)  !    !     !                                                !
+! cdgfac           ! ra ! <-- ! interior faces centers of gravity              !
+!  (ndim, nfac)    !    !     !                                                !
+! cdgfbo           ! ra ! <-- ! boundary faces centers of gravity              !
+!  (ndim, nfabor)  !    !     !                                                !
+! xyznod           ! ra ! <-- ! vertex coordinates (optional)                  !
+!  (ndim, nnod)    !    !     !                                                !
+! volume(ncelet)   ! ra ! <-- ! cell volumes                                   !
+! dt(ncelet)       ! ra ! <-- ! time step (per cell)                           !
+! rtp, rtpa        ! ra ! <-- ! calculated variables at cell centers           !
+!  (ncelet, *)     !    !     !  (at current and previous time steps)          !
+! propce(ncelet, *)! ra ! <-- ! physical properties at cell centers            !
+! propfa(nfac, *)  ! ra ! <-- ! physical properties at interior face centers   !
+! propfb(nfabor, *)! ra ! <-- ! physical properties at boundary face centers   !
+! coefa, coefb     ! ra ! <-- ! boundary conditions                            !
+!  (nfabor, *)     !    !     !                                                !
+! statis           ! ra ! <-- ! statistic means                                !
+!  (ncelet, nvlsta)!    !     !                                                !
+! tracel(*)        ! ra ! --- ! work array for post-processed cell values      !
+! trafac(*)        ! ra ! --- ! work array for post-processed face values      !
+! trafbr(*)        ! ra ! --- ! work array for post-processed boundary face v. !
+! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
+! rtuser(nrtuse)   ! ra ! <-> ! user-reserved real work array                  !
+! ra(*)            ! ra ! --- ! main real work array                           !
 !__________________!____!_____!________________________________________________!
 
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
 !===============================================================================
 
 implicit none
 
 !===============================================================================
-!     DONNEES EN COMMON
+! Common blocks
 !===============================================================================
 
 include "paramx.h"
@@ -205,25 +193,22 @@ double precision trafac(nfacps*3), trafbr(nfbrps*3)
 double precision rdevel(nrdeve), rtuser(nrtuse)
 double precision ra(*)
 
-! VARIABLES LOCALES
+! Local variables
 
 integer          ii
 
-
 !===============================================================================
 
-!     Remarque : le tableau ITYPPS permet de savoir si le maillage post
-!                contient a l'origine des cellules, des faces internes,
-!                ou des faces de bord (sur l'ensemble des processeurs).
+! Note:
+
+! The 'itypps" array allows determining if the mesh contains at first cells,
+! interior faces, or boundary faces (in a global sense when in parallel).
 
-!                Ceci permet d'avoir un traitement "generique" qui
-!                peut fonctionner pour tous les numeros de maillage,
-!                mais si le maillage post est vide a un instant de
-!                post traitement donne, on ne saura plus s'il contenait
-!                des cellules ou faces. Dans ce cas, il est preferable
-!                d'utiliser explicitement le numero du maillage post
-!                pour bien determiner s'il doit contenir des cellules
-!                ou des faces.
+! This enables using "generic" selection criteria, which may function on any
+! post-processing mesh, but if such a mesh is empty for a given call to this
+! function, we will not know at the next call if it contained cells of faces.
+! In this case, it may be preferable to use its number to decide if it should
+! contain cells or faces.
 
 
 !===============================================================================
@@ -231,9 +216,7 @@ integer          ii
 !         A RENSEIGNER PAR L'UTILISATEUR aux endroits indiques
 !===============================================================================
 
-!     Exemple : maillage 2 : cellules ou T<21 degres
-!              
-
+! Example: mesh 2 : cells where T < 21 degrees
 
 if (ipart.eq.2) then
 
@@ -243,28 +226,24 @@ if (ipart.eq.2) then
   nfacps = 0
   nfbrps = 0
 
-!       SI LE MAILLAGE POST CONTIENT DES CELLULES
-!       -----------------------------------------
+
+  ! If the mesh contains cells
+  ! --------------------------
 
   if (itypps(1) .eq. 1) then
 
     do ii = 1, ncel
 
-
       if (rtp(ii,isca(1)) .le. 21.d0) then
         ncelps = ncelps + 1
         lstcel(ncelps) = ii
       endif
 
     enddo
-
-
   endif
 
-endif
-!     Fin du test sur le numero de maillage post.
-
+endif ! end of test on post-processing mesh number
 
 return
 
-end
+end subroutine
diff --git a/examples/3-stratified_junction/case5/usphyv.f90 b/examples/3-stratified_junction/case5/usphyv.f90
deleted file mode 100644
index aff78f0..0000000
--- a/examples/3-stratified_junction/case5/usphyv.f90
+++ /dev/null
@@ -1,403 +0,0 @@
-!-------------------------------------------------------------------------------
-
-!                      Code_Saturne version 2.0.0-beta1
-!                      --------------------------
-
-!     This file is part of the Code_Saturne Kernel, element of the
-!     Code_Saturne CFD tool.
-
-!     Copyright (C) 1998-2008 EDF S.A., France
-
-!     contact: saturne-support at edf.fr
-
-!     The Code_Saturne Kernel is free software; you can redistribute it
-!     and/or modify it under the terms of the GNU General Public License
-!     as published by the Free Software Foundation; either version 2 of
-!     the License, or (at your option) any later version.
-
-!     The Code_Saturne Kernel 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 General Public License for more details.
-
-!     You should have received a copy of the GNU General Public License
-!     along with the Code_Saturne Kernel; if not, write to the
-!     Free Software Foundation, Inc.,
-!     51 Franklin St, Fifth Floor,
-!     Boston, MA  02110-1301  USA
-
-!-------------------------------------------------------------------------------
-
-subroutine usphyv &
-!================
-
- ( idbia0 , idbra0 ,                                              &
-   ndim   , ncelet , ncel   , nfac   , nfabor , nfml   , nprfml , &
-   nnod   , lndfac , lndfbr , ncelbr ,                            &
-   nvar   , nscal  , nphas  ,                                     &
-   nideve , nrdeve , nituse , nrtuse , nphmx  ,                   &
-   ifacel , ifabor , ifmfbr , ifmcel , iprfml ,                   &
-   ipnfac , nodfac , ipnfbr , nodfbr , ibrom  ,                   &
-   idevel , ituser , ia     ,                                     &
-   xyzcen , surfac , surfbo , cdgfac , cdgfbo , xyznod , volume , &
-   dt     , rtp    , rtpa   ,                                     &
-   propce , propfa , propfb ,                                     &
-   coefa  , coefb  ,                                              &
-   w1     , w2     , w3     , w4     ,                            &
-   w5     , w6     , w7     , w8     ,                            &
-   rdevel , rtuser , ra     )
-
-!===============================================================================
-! FONCTION :
-! --------
-
-! ROUTINE UTILISATEUR : REMPLISSAGE DES VARIABLES PHYSIQUES
-
-
-
-! ATTENTION :
-! =========
-
-
-! Il est INTERDIT de modifier la viscosite turbulente VISCT ici
-!        ========
-!  (une routine specifique est dediee a cela : usvist)
-
-
-!  Il FAUT AVOIR PRECISE ICP(IPHAS) = 1
-!     ==================
-!    dans usini1 si on souhaite imposer une chaleur specifique
-!    CP variable pour la phase IPHAS (sinon: ecrasement memoire).
-
-
-!  Il FAUT AVOIR PRECISE IVISLS(Numero de scalaire) = 1
-!     ==================
-!     dans usini1 si on souhaite une diffusivite VISCLS variable
-!     pour le scalaire considere (sinon: ecrasement memoire).
-
-
-
-
-! Remarques :
-! ---------
-
-! Cette routine est appelee au debut de chaque pas de temps
-
-!    Ainsi, AU PREMIER PAS DE TEMPS (calcul non suite), les seules
-!    grandeurs initialisees avant appel sont celles donnees
-!      - dans usini1 :
-!             . la masse volumique (initialisee a RO0(IPHAS))
-!             . la viscosite       (initialisee a VISCL0(IPHAS))
-!      - dans usiniv :
-!             . les variables de calcul  (initialisees a 0 par defaut
-!             ou a la valeur donnee dans usiniv)
-
-! On peut donner ici les lois de variation aux cellules
-!     - de la masse volumique                      ROM    kg/m3
-!         (et eventuellememt aux faces de bord     ROMB   kg/m3)
-!     - de la viscosite moleculaire                VISCL  kg/(m s)
-!     - de la chaleur specifique associee          CP     J/(kg degres)
-!     - des "diffusivites" associees aux scalaires VISCLS kg/(m s)
-
-
-! On dispose des types de faces de bord au pas de temps
-!   precedent (sauf au premier pas de temps, ou les tableaux
-!   ITYPFB et ITRIFB n'ont pas ete renseignes)
-
-
-! Il est conseille de ne garder dans ce sous programme que
-!    le strict necessaire.
-
-
-
-! Arguments
-!__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
-!__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! ncelbr           ! e  ! <-- ! nombre d'elements ayant au moins une           !
-!                  !    !     ! face de bord                                   !
-! nvar             ! e  ! <-- ! nombre total de variables                      !
-! nscal            ! e  ! <-- ! nombre total de scalaires                      !
-! nphas            ! e  ! <-- ! nombre de phases                               !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! nphmx            ! e  ! <-- ! nphsmx                                         !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! nfml  ,nprfml    !    !     !                                                !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfac)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (nfac+1)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfbr)       !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (nfabor+1)     !    !     !  (optionnel)                                   !
-! ibrom            ! te ! <-- ! indicateur de remplissage de romb              !
-!   (nphmx   )     !    !     !                                                !
-! idevel(nideve    ! te ! <-- ! tab entier complementaire developemt           !
-! ituser(nituse    ! te ! <-- ! tab entier complementaire utilisateur          !
-! ia(*)            ! tr ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet          !    !     !                                                !
-! dt(ncelet)       ! tr ! <-- ! pas de temps                                   !
-! rtp, rtpa        ! tr ! <-- ! variables de calcul au centre des              !
-! (ncelet,*)       !    !     !    cellules (instant courant ou prec)          !
-! propce           ! tr ! <-- ! proprietes physiques au centre des             !
-! (ncelet,*)       !    !     !    cellules                                    !
-! propfa           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfac,*)        !    !     !    faces internes                              !
-! propfb           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! coefa, coefb     ! tr ! <-- ! conditions aux limites aux                     !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! w1...8(ncelet    ! tr ! --- ! tableau de travail                             !
-! rdevel(nrdeve    ! tr ! <-- ! tab reel complementaire developemt             !
-! rtuser(nrtuse    ! tr ! <-- ! tab reel complementaire utilisateur            !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
-!__________________!____!_____!________________________________________________!
-
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
-!===============================================================================
-
-implicit none
-
-!===============================================================================
-!     DONNEES EN COMMON
-!===============================================================================
-
-include "paramx.h"
-include "pointe.h"
-include "numvar.h"
-include "optcal.h"
-include "cstphy.h"
-include "entsor.h"
-include "parall.h"
-include "period.h"
-
-!===============================================================================
-
-! Arguments
-
-integer          idbia0 , idbra0
-integer          ndim   , ncelet , ncel   , nfac   , nfabor
-integer          nfml   , nprfml
-integer          nnod   , lndfac , lndfbr , ncelbr
-integer          nvar   , nscal  , nphas
-integer          nideve , nrdeve , nituse , nrtuse , nphmx
-
-integer          ifacel(2,nfac) , ifabor(nfabor)
-integer          ifmfbr(nfabor) , ifmcel(ncelet)
-integer          iprfml(nfml,nprfml)
-integer          ipnfac(nfac+1), nodfac(lndfac)
-integer          ipnfbr(nfabor+1), nodfbr(lndfbr), ibrom(nphmx)
-integer          idevel(nideve), ituser(nituse), ia(*)
-
-double precision xyzcen(ndim,ncelet)
-double precision surfac(ndim,nfac), surfbo(ndim,nfabor)
-double precision cdgfac(ndim,nfac), cdgfbo(ndim,nfabor)
-double precision xyznod(ndim,nnod), volume(ncelet)
-double precision dt(ncelet), rtp(ncelet,*), rtpa(ncelet,*)
-double precision propce(ncelet,*)
-double precision propfa(nfac,*), propfb(nfabor,*)
-double precision coefa(nfabor,*), coefb(nfabor,*)
-double precision w1(ncelet),w2(ncelet),w3(ncelet),w4(ncelet)
-double precision w5(ncelet),w6(ncelet),w7(ncelet),w8(ncelet)
-double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
-
-! VARIABLES LOCALES
-
-integer          idebia, idebra
-integer          ivart, iclvar, iel, iphas
-integer          ipcrom, ipbrom, ipcvis, ipccp
-integer          ipcvsl, ith, iscal, ii
-integer          iutile
-double precision vara, varb, varc, varam, varbm, varcm, vardm
-double precision                   varal, varbl, varcl, vardl
-double precision                   varac, varbc
-double precision xrtp
-
-!===============================================================================
-
-
-
-!===============================================================================
-! 0. INITIALISATIONS A CONSERVER
-!===============================================================================
-
-! --- Initialisation memoire
-
-idebia = idbia0
-idebra = idbra0
-
-
-
-
-
-!===============================================================================
-
-
-!   LES EXEMPLES FANTAISISTES SUIVANTS SONT A ADAPTER PAR L'UTILISATEUR
-!   ====================================================================
-
-!   Chaque exemple est encadre par un test sur IUTILE, par securite.
-!   Mettre IUTILE a 1 pour activer l'exemple.
-
-!   Il est conseille de ne garder dans ce sous programme que
-!     le strict necessaire.
-
-
-
-!  EXEMPLE 1 : MASSE VOLUMIQUE VARIABLE EN FONCTION DE LA TEMPERATURE
-!  EXEMPLE 2 : VISCOSITE       VARIABLE EN FONCTION DE LA TEMPERATURE
-!  EXEMPLE 3 : CHALEUR SPECIFIQUE VARIABLE EN FONCTION DE LA TEMPERATURE
-!  EXEMPLE 4 : Lambda/CP  VARIABLE EN FONCTION DE LA TEMPERATURE
-!                  POUR LA TEMPERATURE OU L'ENTHALPIE
-!  EXEMPLE 5 : DIFFUSIVITE VARIABLE EN FONCTION DE LA TEMPERATURE
-!                  POUR LES SCALAIRES
-!===============================================================================
-
-
-
-
-
-
-
-
-
-
-!===============================================================================
-!  EXEMPLE 1 : MASSE VOLUMIQUE VARIABLE EN FONCTION DE LA TEMPERATURE
-! ===========
-!    Ci dessous on donne pour toutes les phases la meme loi pour
-!       la masse volumique
-!    Les valeurs de cette propriete doivent etre fournies au centre des
-!       cellules (et, de facon optionnelle, aux faces de bord).
-!  ===================================================================
-
-
-! --- Boucle sur les phases : debut
-  do iphas = 1, nphas
-
-! --- Rang de la masse volumique de la phase courante IPHAS
-!     dans PROPCE, prop. physiques au centre des elements       : IPCROM
-!     dans PROPFB, prop. physiques au centre des faces de bord  : IPBROM
-
-    ipcrom = ipproc(irom(iphas))
-
-! --- Coefficients des lois choisis et imposes par l'utilisateur
-!       Les valeurs donnees ici sont fictives
-
-    vara  = -4.0668d-3
-    varb  = -5.0754d-2
-    varc  =  1000.9d0
-
-
-
-!   Masse volumique au centre des cellules
-!   ---------------------------------------
-!       loi              RHO       =   T  * (  A *  T +  B ) +   C
-!       soit    PROPCE(IEL,IPCROM) = XRTP * (VARA*XRTP+VARB) + VARC
-
-    do iel = 1, ncel
-      xrtp = rtp(iel,isca(1))
-      propce(iel,ipcrom) = xrtp * (vara*xrtp+varb) + varc
-    enddo
-
-
-  enddo
-! --- Boucle sur les phases : fin
-
-
-!===============================================================================
-!  EXEMPLE 2 : VISCOSITE       VARIABLE EN FONCTION DE LA TEMPERATURE
-! ===========
-!    Ci dessous on donne pour toutes les phases la meme loi pour
-!       la viscosite
-!    Les valeurs de cette propriete doivent etre fournies au centre des
-!       cellules.
-!  ===================================================================
-
-!     Le test sur IUTILE permet de desactiver les instructions (qui
-!       ne sont fournies qu'a titre d'exemple a adapter)
-
-! --- Boucle sur les phases : debut
-  do iphas = 1, nphas
-
-
-!   Positions des variables, coefficients
-!   -------------------------------------
-
-! --- Rang de la viscosite dynamique moleculaire de la phase IPHAS
-!     dans PROPCE, prop. physiques au centre des elements       : IPCVIS
-
-    ipcvis = ipproc(iviscl(iphas))
-
-! --- Coefficients des lois choisis et imposes par l'utilisateur
-!       Les valeurs donnees ici sont fictives
-
-    varam = -3.4016d-9
-    varbm =  6.2332d-7
-    varcm = -4.5577d-5
-    vardm =  1.6935d-3
-
-
-
-!   Viscosite moleculaire dynamique en kg/(m s) au centre des cellules
-!   ------------------------------------------------------------------
-!       loi              MU        =
-!                              T  *( T  *( AM  * T +  BM  )+ CM  )+ DM
-!       soit    PROPCE(IEL,IPCVIS) =
-!     &                       XRTP*(XRTP*(VARAM*XRTP+VARBM)+VARCM)+VARDM
-
-    do iel = 1, ncel
-      xrtp = rtp(iel,isca(1))
-      propce(iel,ipcvis) =                                        &
-           xrtp*(xrtp*(varam*xrtp+varbm)+varcm)+vardm
-    enddo
-
-
-  enddo
-! --- Boucle sur les phases : fin
-
-
-!----
-! FIN
-!----
-
-return
-end
diff --git a/examples/3-stratified_junction/case5/usvpst.f90 b/examples/3-stratified_junction/case5/usvpst.f90
index 4ca66b6..2ec4124 100644
--- a/examples/3-stratified_junction/case5/usvpst.f90
+++ b/examples/3-stratified_junction/case5/usvpst.f90
@@ -1,12 +1,12 @@
 !-------------------------------------------------------------------------------
 
-!                      Code_Saturne version 2.0.0-beta1
+!                      Code_Saturne version 2.0.0-rc1
 !                      --------------------------
 
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2008 EDF S.A., France
+!     Copyright (C) 1998-2009 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -45,124 +45,115 @@ subroutine usvpst &
    dt     , rtpa   , rtp    , propce , propfa , propfb ,          &
    coefa  , coefb  , statis ,                                     &
    tracel , trafac , trafbr , rdevel , rtuser , ra     )
+
 !===============================================================================
-! FONCTION :
-! --------
+! Purpose:
+! -------
+
+!    User subroutine.
 
-! ROUTINE UTILISATEUR POUR LA SORTIE DE VARIABLES SUR UN MAILLAGE
-!   DE POST TRAITEMENT DEJA DEFINI
+!    Output additional variables on a postprocessing mesh.
 
-! PAR DEFAUT, DEUX MAILLAGES SONT DEFINIS AUTOMATIQUEMENT :
-!      - LE MAILLAGE VOLUMIQUE (IPART=-1) SELON LA VALEUR DE ICHRVL
-!      - LE MAILLAGE DE BORD   (IPART=-2) SELON LA VALEUR DE ICHRBO
-! DES MAILLAGES SUPPLEMENTAIRES (CELLULES OU FACES INTERNES ET
-!   DE BORD) PEUVENT ETRE DEFINIS ET PARAMETRES A TRAVERS
-!   usdpst    .F ET usmpst.F.
+! Several "automatic" postprocessing meshes may be defined:
+! - The volume mesh (ipart=-1) if 'ichrvl' = 1
+! - The boundary mesh (ipart=-2) if 'ichrbo' = 1
+! - SYRTHES coupling surface (ipart < -2) if 'ichrsy' = 1
+! - Cooling tower exchange zone meshes (ipart < -2) if 'ichrze' = 1
+!
+! Additional meshes (cells or faces) may also be defined using the
+! 'usdpst' user subroutine, (and possibly modified using 'usmpst').
 
-!ETTE  CETTE ROUTINE EST APPELEE UNE FOIS PAR MAILLAGE POST
-!   ET PAR PAS DE TEMPS AUQUEL CE MAILLAGE EST ACTIF
+! This subroutine is called once for each post-processing mesh
+! (with a different value of 'ipart') for each time step at which output
+! on this mesh is active.
 
 !-------------------------------------------------------------------------------
 ! Arguments
 !__________________.____._____.________________________________________________.
-!    nom           !type!mode !                   role                         !
+! name             !type!mode ! role                                           !
 !__________________!____!_____!________________________________________________!
-! idbia0           ! e  ! <-- ! numero de la 1ere case libre dans ia           !
-! idbra0           ! e  ! <-- ! numero de la 1ere case libre dans ra           !
-! ipart            ! e  ! <-- ! numero du maillage post                        !
-! ndim             ! e  ! <-- ! dimension de l'espace                          !
-! ncelet           ! e  ! <-- ! nombre d'elements halo compris                 !
-! ncel             ! e  ! <-- ! nombre d'elements actifs                       !
-! nfac             ! e  ! <-- ! nombre de faces internes                       !
-! nfabor           ! e  ! <-- ! nombre de faces de bord                        !
-! nfml             ! e  ! <-- ! nombre de familles d entites                   !
-! nprfml           ! e  ! <-- ! nombre de proprietese des familles             !
-! nnod             ! e  ! <-- ! nombre de sommets                              !
-! lndfac           ! e  ! <-- ! longueur du tableau nodfac (optionnel          !
-! lndfbr           ! e  ! <-- ! longueur du tableau nodfbr (optionnel          !
-! ncelbr           ! e  ! <-- ! nombre d'elements ayant au moins une           !
-!                  !    !     ! face de bord                                   !
-! nvar             ! e  ! <-- ! nombre total de variables                      !
-! nscal            ! e  ! <-- ! nombre total de scalaires                      !
-! nphas            ! e  ! <-- ! nombre de phases                               !
-! nvlsta           ! e  ! <-- ! nombre de variables stat. lagrangien           !
-! ncelps           ! e  ! <-- ! nombre de cellules du maillage post            !
-! nfacps           ! e  ! <-- ! nombre de faces interieur post                 !
-! nfbrps           ! e  ! <-- ! nombre de faces de bord post                   !
-! nideve nrdeve    ! e  ! <-- ! longueur de idevel rdevel                      !
-! nituse nrtuse    ! e  ! <-- ! longueur de ituser rtuser                      !
-! itypps(3)        ! te ! <-- ! indicateur de presence (0 ou 1) de             !
-!                  !    !     ! cellules (1), faces (2), ou faces de           !
-!                  !    !     ! de bord (3) dans le maillage post              !
-! ifacel           ! te ! <-- ! elements voisins d'une face interne            !
-! (2, nfac)        !    !     !                                                !
-! ifabor           ! te ! <-- ! element  voisin  d'une face de bord            !
-! (nfabor)         !    !     !                                                !
-! ifmfbr           ! te ! <-- ! numero de famille d'une face de bord           !
-! (nfabor)         !    !     !                                                !
-! ifmcel           ! te ! <-- ! numero de famille d'une cellule                !
-! (ncelet)         !    !     !                                                !
-! iprfml           ! te ! <-- ! proprietes d'une famille                       !
-! nfml  ,nprfml    !    !     !                                                !
-! ipnfac           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfac)       !    !     !  face interne dans nodfac (optionnel)          !
-! nodfac           ! te ! <-- ! connectivite faces internes/noeuds             !
-!   (nfac+1)       !    !     !  (optionnel)                                   !
-! ipnfbr           ! te ! <-- ! position du premier noeud de chaque            !
-!   (lndfbr)       !    !     !  face de bord dans nodfbr (optionnel)          !
-! nodfbr           ! te ! <-- ! connectivite faces de bord/noeuds              !
-!   (nfabor+1)     !    !     !  (optionnel)                                   !
-! lstcel(ncelps    ! te ! <-- ! liste des cellules du maillage post            !
-! lstfac(nfacps    ! te ! <-- ! liste des faces interieures post               !
-! lstfbr(nfbrps    ! te ! <-- ! liste des faces de bord post                   !
-! idevel(nideve    ! te ! <-- ! tab entier complementaire developemt           !
-! ituser(nituse    ! te ! <-- ! tab entier complementaire utilisateur          !
-! ia(*)            ! te ! --- ! macro tableau entier                           !
-! xyzcen           ! tr ! <-- ! point associes aux volumes de control          !
-! (ndim,ncelet     !    !     !                                                !
-! surfac           ! tr ! <-- ! vecteur surface des faces internes             !
-! (ndim,nfac)      !    !     !                                                !
-! surfbo           ! tr ! <-- ! vecteur surface des faces de bord              !
-! (ndim,nfabor)    !    !     !                                                !
-! cdgfac           ! tr ! <-- ! centre de gravite des faces internes           !
-! (ndim,nfac)      !    !     !                                                !
-! cdgfbo           ! tr ! <-- ! centre de gravite des faces de bord            !
-! (ndim,nfabor)    !    !     !                                                !
-! xyznod           ! tr ! <-- ! coordonnes des noeuds (optionnel)              !
-! (ndim,nnod)      !    !     !                                                !
-! volume           ! tr ! <-- ! volume d'un des ncelet elements                !
-! (ncelet)         !    !     !                                                !
-! dt(ncelet)       ! tr ! <-- ! pas de temps                                   !
-! rtp, rtpa        ! tr ! <-- ! variables de calcul au centre des              !
-! (ncelet,*)       !    !     !    cellules (instant courant ou prec)          !
-! propce           ! tr ! <-- ! proprietes physiques au centre des             !
-! (ncelet,*)       !    !     !    cellules                                    !
-! propfa           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfac,*)        !    !     !    faces internes                              !
-! propfb           ! tr ! <-- ! proprietes physiques au centre des             !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! coefa, coefb     ! tr ! <-- ! conditions aux limites aux                     !
-!  (nfabor,*)      !    !     !    faces de bord                               !
-! statis           ! tr ! <-- ! statistiques (lagrangien)                      !
-!ncelet,nvlsta)    !    !     !                                                !
-! tracel(*)        ! tr ! <-- ! tab reel valeurs cellules post                 !
-! trafac(*)        ! tr ! <-- ! tab reel valeurs faces int. post               !
-! trafbr(*)        ! tr ! <-- ! tab reel valeurs faces bord post               !
-! rdevel(nrdeve    ! tr ! <-- ! tab reel complementaire developemt             !
-! rtuser(nrtuse    ! tr ! <-- ! tab reel complementaire utilisateur            !
-! ra(*)            ! tr ! --- ! macro tableau reel                             !
+! idbia0           ! i  ! <-- ! number of first free position in ia            !
+! idbra0           ! i  ! <-- ! number of first free position in ra            !
+! ipart            ! i  ! <-- ! number of the post-processing mesh (< 0 or > 0)!
+! ndim             ! i  ! <-- ! spatial dimension                              !
+! ncelet           ! i  ! <-- ! number of extended (real + ghost) cells        !
+! ncel             ! i  ! <-- ! number of cells                                !
+! nfac             ! i  ! <-- ! number of interior faces                       !
+! nfabor           ! i  ! <-- ! number of boundary faces                       !
+! nfml             ! i  ! <-- ! number of families (group classes)             !
+! nprfml           ! i  ! <-- ! number of properties per family (group class)  !
+! nnod             ! i  ! <-- ! number of vertices                             !
+! lndfac           ! i  ! <-- ! size of nodfac indexed array                   !
+! lndfbr           ! i  ! <-- ! size of nodfbr indexed array                   !
+! ncelbr           ! i  ! <-- ! number of cells with faces on boundary         !
+! nvar             ! i  ! <-- ! total number of variables                      !
+! nscal            ! i  ! <-- ! total number of scalars                        !
+! nphas            ! i  ! <-- ! number of phases                               !
+! nvlsta           ! i  ! <-- ! number of Lagrangian statistical variables     !
+! ncelps           ! i  ! <-- ! number of cells in post-processing mesh        !
+! nfacps           ! i  ! <-- ! number of interior faces in post-process. mesh !
+! nfbrps           ! i  ! <-- ! number of boundary faces in post-process. mesh !
+! nideve, nrdeve   ! i  ! <-- ! sizes of idevel and rdevel arrays              !
+! nituse, nrtuse   ! i  ! <-- ! sizes of ituser and rtuser arrays              !
+! itypps(3)        ! ia ! <-- ! global presence flag (0 or 1) for cells (1),   !
+!                  !    !     ! interior faces (2), or boundary faces (3) in   !
+!                  !    !     ! post-processing mesh                           !
+! ifacel(2, nfac)  ! ia ! <-- ! interior faces -> cells connectivity           !
+! ifabor(nfabor)   ! ia ! <-- ! boundary faces -> cells connectivity           !
+! ifmfbr(nfabor)   ! ia ! <-- ! boundary face family numbers                   !
+! ifmcel(ncelet)   ! ia ! <-- ! cell family numbers                            !
+! iprfml           ! ia ! <-- ! property numbers per family                    !
+!  (nfml, nprfml)  !    !     !                                                !
+! ipnfac(nfac+1)   ! ia ! <-- ! interior faces -> vertices index (optional)    !
+! nodfac(lndfac)   ! ia ! <-- ! interior faces -> vertices list (optional)     !
+! ipnfbr(nfabor+1) ! ia ! <-- ! boundary faces -> vertices index (optional)    !
+! nodfbr(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
+! lstcel(ncelps)   ! ia ! <-- ! list of cells in post-processing mesh          !
+! lstfac(nfacps)   ! ia ! <-- ! list of interior faces in post-processing mesh !
+! lstfbr(nfbrps)   ! ia ! <-- ! list of boundary faces in post-processing mesh !
+! idevel(nideve)   ! ia ! <-> ! integer work array for temporary development   !
+! ituser(nituse)   ! ia ! <-> ! user-reserved integer work array               !
+! ia(*)            ! ia ! --- ! main integer work array                        !
+! xyzcen           ! ra ! <-- ! cell centers                                   !
+!  (ndim, ncelet)  !    !     !                                                !
+! surfac           ! ra ! <-- ! interior faces surface vectors                 !
+!  (ndim, nfac)    !    !     !                                                !
+! surfbo           ! ra ! <-- ! boundary faces surface vectors                 !
+!  (ndim, nfabor)  !    !     !                                                !
+! cdgfac           ! ra ! <-- ! interior faces centers of gravity              !
+!  (ndim, nfac)    !    !     !                                                !
+! cdgfbo           ! ra ! <-- ! boundary faces centers of gravity              !
+!  (ndim, nfabor)  !    !     !                                                !
+! xyznod           ! ra ! <-- ! vertex coordinates (optional)                  !
+!  (ndim, nnod)    !    !     !                                                !
+! volume(ncelet)   ! ra ! <-- ! cell volumes                                   !
+! dt(ncelet)       ! ra ! <-- ! time step (per cell)                           !
+! rtp, rtpa        ! ra ! <-- ! calculated variables at cell centers           !
+!  (ncelet, *)     !    !     !  (at current and previous time steps)          !
+! propce(ncelet, *)! ra ! <-- ! physical properties at cell centers            !
+! propfa(nfac, *)  ! ra ! <-- ! physical properties at interior face centers   !
+! propfb(nfabor, *)! ra ! <-- ! physical properties at boundary face centers   !
+! coefa, coefb     ! ra ! <-- ! boundary conditions                            !
+!  (nfabor, *)     !    !     !                                                !
+! statis           ! ra ! <-- ! statistic values (Lagrangian)                  !
+!  (ncelet, nvlsta)!    !     !                                                !
+! tracel(*)        ! ra ! --- ! work array for post-processed cell values      !
+! trafac(*)        ! ra ! --- ! work array for post-processed face values      !
+! trafbr(*)        ! ra ! --- ! work array for post-processed boundary face v. !
+! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
+! rtuser(nrtuse)   ! ra ! <-> ! user-reserved real work array                  !
+! ra(*)            ! ra ! --- ! main real work array                           !
 !__________________!____!_____!________________________________________________!
 
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
 !===============================================================================
 
 implicit none
 
 !===============================================================================
-!     DONNEES EN COMMON
+! Common blocks
 !===============================================================================
 
 include "paramx.h"
@@ -178,18 +169,18 @@ include "period.h"
 
 ! Arguments
 
-integer          idbia0 , idbra0
+integer          idbia0, idbra0
 integer          ipart
-integer          ndim   , ncelet , ncel   , nfac   , nfabor
-integer          nfml   , nprfml
-integer          nnod   , lndfac , lndfbr , ncelbr
-integer          nvar   , nscal  , nphas  , nvlsta
-integer          ncelps , nfacps , nfbrps
-integer          nideve , nrdeve , nituse , nrtuse
+integer          ndim,   ncelet, ncel,   nfac,   nfabor
+integer          nfml,   nprfml
+integer          nnod,   lndfac, lndfbr, ncelbr
+integer          nvar,   nscal , nphas , nvlsta
+integer          ncelps, nfacps, nfbrps
+integer          nideve, nrdeve, nituse, nrtuse
 
 integer          itypps(3)
-integer          ifacel(2,nfac) , ifabor(nfabor)
-integer          ifmfbr(nfabor) , ifmcel(ncelet)
+integer          ifacel(2,nfac), ifabor(nfabor)
+integer          ifmfbr(nfabor), ifmcel(ncelet)
 integer          iprfml(nfml,nprfml)
 integer          ipnfac(nfac+1), nodfac(lndfac)
 integer          ipnfbr(nfabor+1), nodfbr(lndfbr)
@@ -210,7 +201,7 @@ double precision trafac(nfacps*3), trafbr(nfbrps*3)
 double precision rdevel(nrdeve), rtuser(nrtuse)
 double precision ra(*)
 
-! VARIABLES LOCALES
+! Local variables
 
 character*32     namevr
 
@@ -226,141 +217,129 @@ integer          ipass
 data             ipass /0/
 save             ipass
 
+!===============================================================================
+
 
 !===============================================================================
+! 1. Handle variables to output
+!    MUST BE FILLED IN by the user at indicated places
+!===============================================================================
 
+! A post-processing id a "part" (using the EnSight vocabulary; the MED and
+! CGNS equivalents are "mesh" and "base" respectively).
+! The user will have defined post-processing meshes in 'usdpst' ('nbpart'
+! post-processing meshes).
+
+! This subroutine is called once for each post-processing mesh
+! (with a different value of 'ipart') for each time step at which output
+! on this mesh is active. For each mesh and for all variables we wish to
+! post-process here, we must define certain parameters and pass them to
+! the 'psteva' subroutine, which is in charge of the actual output.
+! These parameters are:
+
+! namevr <-- variable name
+! idimt  <-- variable dimension
+!            (1: scalar, 3: vector, 6: symmetric tensor, 9: tensor)
+! ientla <-- when idimt >1, this flag specifies if the array containing the
+!            variable values is interlaced when ientla = 1
+!            (x1, y1, z1, x2, y2, z2, x3, y3, z3...), or non-interlaced
+!            when ientla = 0 (x1,x2,x3,...,y1,y2,y3,...,z1,z2,z3,...).
+! ivarpr <-- specifies if the array containing the variable is defined on
+!            the "parent" mesh or locally.
+!            Even if the 'ipart' post-processing mesh contains all the
+!            elements of its parent mesh, their numbering may be different,
+!            especially when different element types are present.
+!            The 'tracel' array passed as an argument to 'psteva' is built
+!            relative to the numbering of the 'ipart' post-processing mesh.
+!            To post-process a variable contained for example in the 'rtuser'
+!            array, it should first be re-ordered, as shown here:
+!              do iloc = 1, ncelps
+!                iel = lstcel(iloc)
+!                tracel(iloc) = rtuser(iel)
+!              enddo
+!            An alternative option is provided, to avoid unnecessary copies:
+!            an array defined on the parent mesh, such our 'rtuser' example,
+!            may be passed directly to 'psteva', specifying that values
+!            are defined on the parent mesh instead of the post-processing mesh,
+!            by setting the 'ivarpr' argument of 'psteva' to 1.
+
+! Note: be cautious with variable name lengths.
+
+! We allow up to 32 characters here, but names may be truncted depending on the
+! output format:
+
+! - 19 characters for EnSight
+! - 32 characters for MED
+
+! The nam length is not limited internally, so in case of 2 variables whoses
+! names differ only after the 19th character, the corresponding names will
+! both appear in the ".case" file; simply renaming one of the field descriptors
+! in this text file will correct the output.
+
+! Whitespace at the beginning or the end of a line is truncated automatically.
+! Depending on the format used, prohibited characters (under EnSight, characters
+! (  ) ] [ + - @           ! # * ^ $ / as well as white spaces and tabulations
+! are automatically replaced by the _ character.
+
+! Examples:
+
+! For post-processing mesh 2, we output the velocity, pressure, and prescribed
+! temperature at boundary faces (as well as 0 on possible interior faces)
+
+! For post-processing mesh 1, we output all the variables usually
+! post-processed, using a more compact coding.
+
+! Examples given here correspond to the meshes defined in usdpst.f90 and
+! modified in usmpst.f90.
 
 
 !===============================================================================
-!     1. TRAITEMENT DES VARIABLES A SORTIR
-!         A RENSEIGNER PAR L'UTILISATEUR aux endroits indiques
+! 1.1. Examples of volume variables on the main volume mesh (ipart = -1)
 !===============================================================================
 
+if (ipart.eq.1) then
+
+  ! Initialisation
+  ! no user intervention required --------------
 
-!     Un maillage de posttraitement est une "part"
-!       (au sens EnSight ; les �quivalents MED et CGNS sont le maillage
-!       et la base respectivement)
-!     L'utilisateur aura defini ses maillages de posttraitement dans
-!       usdpst (NBPART maillages de posttraitement)
-
-
-!     La routine est appelee une fois pour chaque maillage IPART.
-!     Pour chaque maillage et pour chacune des variables que l'on
-!       souhaite posttraiter, on doit definir certains parametres et les
-!       passer a la routine PSTEVA qui se charge de l'ecriture effective.
-!     Ces parametres sont :
-!       NAMEVR : nom de la variable
-!       IDIMT  : dimension de la variable
-!       IENTLA : dans le cas ou IDIMT est >1, IENTLA permet de specifier
-!                si le tableau contenant la variable est range de maniere
-!                entrelacee X1,Y1,Z1,X2,Y2,Z2,X3,Y3,Z3,... (IENTLA=1)
-!                ou non entrelancee X1,X2,X3,...,Y1,Y2,Y3,...,Z1,Z2,Z3,...
-!                                                               (IENTLA=0)
-!       IVARPR : specifie si le tableau contenant la variable traitee est
-!                defini sur le maillage "parent"/
-!                En effet, meme si le maillage IPART considere contient
-!                le meme nombre d'elements que le maillage complet "parent"
-!                (NCELPS=NCEL), l'ordre de numerotation des elements n'est pas
-!                forcement le meme. Le tableau TRACEL passe en argument de
-!                PSTEVA est construit selon la numerotation du maillage IPART.
-!                Pour posttraiter une variable contenue dans un tableau RTUSER
-!                par exemple, il faut donc d'abord le reordonner dans le
-!                tableau TRACEL :
-!                  DO ILOC = 1, NCELPS
-!                    IEL = LSTCEL(ILOC)
-!                    TRACEL(ILOC) = RTUSER(IEL)
-!                  ENDDO
-!                Une alternative est cependant offerte, pour eviter des copies
-!                inutiles. Si NCELPS=NCEL, on peut directement passer RTUSER
-!                en argument de PSTEVA, en specifiant IVARPR=1, pour avertir
-!                le code que la numerotation est celle du maillage "parent".
-!                L'exemple ci-dessus concerne les cellules, mais la
-!                problematique est la meme avec les faces internes ou faces de
-!                bord.
-
-
-!     Remarque : attention aux longueurs des noms de variables.
-
-!                On autorise ici jusqu'� 32 caracteres , mais selon le
-!                format utilise, les noms peuvent etre tronques :
-
-!                  - a 19 caracteres pour une sortie EnSight
-!                  - a 32 caracteres pour ue sortie MED 2.2
-
-!                La longueur du nom n'est pas limitee en interne, et en
-!                cas de deux variables aux noms tronques ne differant
-!                qu'apres le 19ieme caractere, les lignes correspondantes
-!                apparaitront normalement dans le fichier texte ".case"
-!                EnSight, avec un meme champ de description ; il suffit
-!                alors de renommer un de ces champs dans ce fichier
-!                texte pour corriger le probleme.
-
-!                Les caracteres blancs en debut ou fin de chaine sont
-!                supprimes automatiquement. Selon le format utilise,
-!                les caracteres interdits (sous EnSight, les caracteres
-!                (  ) ] [ + - @           ! # * ^ $ / ainsi que les blancs et les
-!                tabulations seront remplaces par le caractere ___________.
-!                Ceci ne necessite aucune intervention utilisateur
-!                (i.e. inutile d'utiliser ici les anciennes fonctions
-!                Fortran VERLON et UNDSCR).
-
-
-!     Exemples :
-!               pour le maillage post 1, on sort
-!                 la temperature interpolee a la face
-!                   (et 0 sur les eventuelles faces interieures)
-
-!               pour le maillage post 2, on sort
-!                 la temperature
-
-
-if (ipart.eq.1 ) then
-
-
-!       Initialisation
-!         pas d'intervention utilisateur requise
+  ! Initialize variable name
   do ii = 1, 32
-    NAMEVR (II:II) = ' '
+    namevr(ii:ii) = ' '
   enddo
 
-!       Nom de la variable
-!         a renseigner par l'utilisateur
-  NAMEVR = 'Temperature interpolee'
+  ! Variable name
+    namevr = 'interpolated Temperature'
 
-!       Dimension de la variable (3 = vecteur, 1=scalaire)
-!         a renseigner par l'utilisateur
+  ! Variable dimension (1: scalar, 3: vector, 6/9: symm/non-symm tensor)
   idimt = 1
 
-!       Valeurs entrelac�es
+  ! Values are not interlaced (dimension 1 here, so no effect).
   ientla = 0
 
+  ! Computation of variable values on internal faces
+  ! To simplify the example, we use here a simple linear interpolation
+  ! In muti-processor calculations, if neighouring cells are used, it is 
+  ! necessary to exchange informations as usual. In calculations with periodicity
+  ! and several processors, it is in addition necessary to call the routine 'parcom'
+  ! before calling the routine 'percom'.
 
-!       Calcul des valeurs de la variable sur les faces internes
-!         Pour simplifier l'exemple, on se contente ici d'une simple
-!           interpolation lineaire.
-!         Dans les calculs paralleles, si l'on utilise les voisins,
-!           il faut faire un echange au prealable, comme d'habitude.
-!         Dans les calculs avec periodicite, il faut egalement le faire
-!         Pour les calculs ou periodicite et parallelisme coexistent,
-!           l'appel a ces routines doit etre fait dans l'ordre
-!           PARCOM puis PERCOM
-
-!         a renseigner par l'utilisateur
+  ! user intervention:
 
-  if(irangp.ge.0) then
-    call parcom (rtp(1,isca(1)))
+  if (irangp.ge.0) then
+    call  parcom (rtp(1,isca(1)))
+    !===========
   endif
 
-  if(iperio.eq.1) then
+  if (iperio.eq.1) then
     ivar = isca(1)
     idimte = 0
     itenso = 0
-    call percom                                                   &
+    call percom &
     !==========
-         ( idimte , itenso ,                                      &
-           rtp(1,ivar), rtp(1,ivar), rtp(1,ivar),                 &
-           rtp(1,ivar), rtp(1,ivar), rtp(1,ivar),                 &
-           rtp(1,ivar), rtp(1,ivar), rtp(1,ivar))
+  ( idimte, itenso,   &
+    rtp(1,ivar), rtp(1,ivar), rtp(1,ivar),  &
+    rtp(1,ivar), rtp(1,ivar), rtp(1,ivar),  &
+    rtp(1,ivar), rtp(1,ivar), rtp(1,ivar))
   endif
 
   do iloc = 1, nfacps
@@ -370,62 +349,53 @@ if (ipart.eq.1 ) then
     jj = ifacel(2, ifac)
     pond = ra(ipond-1+ifac)
 
-    trafac(iloc)                                                  &
-         =         pond  * rtp(ii, isca(1))                       &
-         + (1.d0 - pond) * rtp(jj, isca(1))
-
+    trafac(iloc) =         pond  * rtp(ii,isca(1))  &
+                 + (1.d0 - pond) * rtp(jj,isca(1))
   enddo
 
-
-!       Ecriture effective des valeurs calculees
+  ! Writing of calculated values
 
   ivarpr = 0
 
-  call psteva(ipart , namevr, idimt, ientla, ivarpr,              &
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,  &
   !==========
               ntcabs, ttcabs, tracel, trafac, trafbr)
 
+elseif (ipart .eq. 2) then
 
+  ! Post-processing of velocity
+  ! ---------------------------
 
+  ! Initialisation
+  ! no user intervention required --------------
 
-else if  (ipart.eq.2) then
-
-
-!       1.4.1 TRAITEMENT DE LA VITESSE
-!       ------------------------------
-
-!       Initialisation
-!         pas d'intervention utilisateur requise
+  ! Initialize variable name
   do ii = 1, 32
-    NAMEVR (II:II) = ' '
+    namevr (ii:ii) = ' '
   enddo
 
-!       Nom de la variable
-!         a renseigner par l'utilisateur
-  NAMEVR = 'Temperature'
+  ! Variable name
+  namevr = 'Temperature'
 
-!       Dimension de la variable (3 = vecteur, 1=scalaire)
-!         a renseigner par l'utilisateur
+  ! Variable dimension (1: scalar, 3: vector, 6/9: symm/non-symm tensor)
   idimt = 1
 
-!       Valeurs non entrelac�es
+  ! Values are not interlaced (dimension 1 here, so no effect).
   ientla = 0
 
   do iloc = 1, ncelps
     iel = lstcel(iloc)
-    tracel(iloc) = rtp(iel,isca(1))
+    tracel(iloc)= rtp(iel,isca(1))
   enddo
 
   ivarpr = 0
 
-  call psteva(ipart , namevr, idimt, ientla, ivarpr,              &
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,   &
   !==========
               ntcabs, ttcabs, tracel, trafac, trafbr)
 
-endif
-!     Fin du test sur le numero de maillage post.
-
+endif ! end of test on post-processing mesh number
 
 return
 
-end
+end subroutine
diff --git a/extras/installer/README.txt b/extras/installer/README.txt
index b516098..6167410 100644
--- a/extras/installer/README.txt
+++ b/extras/installer/README.txt
@@ -25,7 +25,8 @@ properly. If this behaviour is not wanted, set the "download" variable
 to "no" in the setup script.
 
 It is possible to specify her/his own Python executable through the "python"
-variable, as well as BLAS libraries through the "blas" variable.
+variable, as well as BLAS libraries through the "blas" variable, or Metis and
+Scotch through similar variables.
 
 SYRTHES installation path (for coupling with the thermal code SYRTHES) will be
 provided with the "syrthes" variable.
@@ -45,7 +46,6 @@ the build directory, ...)
   order of install should be the following:
   - libxml2 (it is advised to use the distrib own package)
   - swig (it is advised to use the distrib own package)
-  - Metis
   - MPI
   - CGNS
   - HDF5
@@ -59,6 +59,8 @@ the build directory, ...)
   The following packages cannot be installed
   - Zlib
   - BLAS
+  - Metis
+  - Scotch
   - PyQT
   - Python
 
diff --git a/extras/installer/install_saturne.py b/extras/installer/install_saturne.py
index fd94da3..674f33f 100755
--- a/extras/installer/install_saturne.py
+++ b/extras/installer/install_saturne.py
@@ -22,7 +22,7 @@ import subprocess
 # Global variable
 #-------------------------------------------------------------------------------
 
-verbose = 'no'
+verbose = 'yes'
 
 #-------------------------------------------------------------------------------
 # Global methods
@@ -209,50 +209,6 @@ class Package:
         os.chdir(current_dir)
 
 #-------------------------------------------------------------------------------
-# Class definition for Metis library (to circumvent a difficult installation)
-#-------------------------------------------------------------------------------
-
-class MetisPackage(Package):
-
-    def install(self):
-
-        current_dir = os.getcwd()
-
-        if self.install_dir is not None: install_dir = self.install_dir
-        else: install_dir = '/usr'
-
-        os.chdir(self.source_dir)
-
-        run_command("make", "Compile", self.name, self.log_file)
-
-        # Install the package
-        incdir = os.path.join(install_dir, 'include')
-        bindir = os.path.join(install_dir, 'bin')
-        libdir = os.path.join(install_dir, 'lib')
-
-        if not os.path.isdir(incdir): os.makedirs(incdir)
-        if not os.path.isdir(bindir): os.makedirs(bindir)
-        if not os.path.isdir(libdir): os.makedirs(libdir)
-
-        for file in os.listdir(os.path.join(self.source_dir, "Lib")):
-            if file.find('.h') >= 0:
-                shutil.copy(os.path.join(self.source_dir, "Lib", file),
-                            os.path.join(incdir, file))
-
-        for file in ['graphchk','kmetis','mesh2dual','mesh2nodal','oemetis',
-                     'onmetis','partdmesh','partnmesh','pmetis']:
-            shutil.copy(os.path.join(self.source_dir, file),
-                        os.path.join(bindir, file))
-
-        for file in ['libmetis.a']:
-            shutil.copy(os.path.join(self.source_dir, file),
-                        os.path.join(libdir, file))
-
-        run_command("make clean", "Clean", self.name, self.log_file)
-
-        os.chdir(current_dir)
-
-#-------------------------------------------------------------------------------
 # Class definition for Code_Saturne setup
 #-------------------------------------------------------------------------------
 
@@ -264,12 +220,12 @@ class Setup:
         self.satlibs = ['bft', 'fvm', 'mei', 'ecs', 'ncs']
 
         # Optional libraries
-        self.optlibs = ['cgns', 'hdf5', 'med', 'metis', 'mpi', 'libxml2', 'swig']
+        self.optlibs = ['cgns', 'hdf5', 'med', 'mpi', 'libxml2', 'swig']
 
         self.libs = self.optlibs + self.satlibs
 
         # Code_Saturne version 
-        self.version='2.0-beta2'
+        self.version = '2.0'
 
         # Logging file
         self.log_file = sys.stdout
@@ -278,10 +234,10 @@ class Setup:
         self.download = 'yes'
 
         # Code_Saturne language (may be en/fr)
-        self.language='en'
+        self.language = 'en'
 
         # Code_Saturne installation with debugging symbols
-        self.debug='no'
+        self.debug = 'no'
 
         # Default compilers
         self.cc = None
@@ -297,6 +253,12 @@ class Setup:
         # BLAS library path
         self.blas = None
 
+        # Metis library path
+        self.metis = None
+
+        # Scotch library path
+        self.scotch = None
+
         # SYRTHES path
         self.syrthes = None
 
@@ -314,8 +276,7 @@ class Setup:
         # Packages definition
         self.packages = {}
 
-        url_cs = "http://research.edf.com/fichiers/fckeditor/Commun/Innovation/logiciels/%s"
-        url_cs = "https://code-saturne.info/products/code-saturne/forums/announces/918391265/724961558/%s"
+        url_cs = "https://code-saturne.info/products/code-saturne/releases/" + self.version + "/%s"
 
         # BFT library
 
@@ -323,8 +284,8 @@ class Setup:
             Package(name="BFT",
                     description="Basic Functions and Tools",
                     package="bft",
-                    version="1.1.2",
-                    archive="bft-112.tgz",
+                    version="1.1.3",
+                    archive="bft-113.tgz",
                     url=url_cs)
 
         # FVM library
@@ -333,8 +294,8 @@ class Setup:
             Package(name="FVM",
                     description="Finite Volume Mesh",
                     package="fvm",
-                    version="0.15.0",
-                    archive="fvm-0150.tgz",
+                    version="0.15.1",
+                    archive="fvm-0151.tgz",
                     url=url_cs)
 
         p = self.packages['fvm']
@@ -346,8 +307,8 @@ class Setup:
             Package(name="MEI",
                     description="Mathematical Expressions Interpreter",
                     package="mei",
-                    version="1.0.1",
-                    archive="mei-101.tgz",
+                    version="1.0.2",
+                    archive="mei-102.tgz",
                     url=url_cs)
 
         # Code_Saturne Preprocessor
@@ -356,8 +317,8 @@ class Setup:
             Package(name="ECS",
                     description="Code_Saturne Preprocessor",
                     package="ecs",
-                    version="2.0-rc1",
-                    archive="ecs-200rc1.tgz",
+                    version="2.0",
+                    archive="ecs-200.tgz",
                     url=url_cs)
 
         # Code_Saturne Kernel
@@ -366,8 +327,8 @@ class Setup:
             Package(name="NCS",
                     description="Code_Saturne Kernel",
                     package="ncs",
-                    version="2.0-rc1",
-                    archive="ncs-200rc1.tgz",
+                    version="2.0",
+                    archive="ncs-200.tgz",
                     url=url_cs)
 
         p = self.packages['ncs']
@@ -385,8 +346,8 @@ class Setup:
 
         p = self.packages['cgns']
         p.config_opts = "--enable-64bit --enable-lfs"
-        p.vpath_support=False
-        p.create_install_dirs=True
+        p.vpath_support = False
+        p.create_install_dirs = True
 
         # HDF5 library
 
@@ -414,34 +375,14 @@ class Setup:
         p = self.packages['med']
         p.config_opts = "--with-med_int=int"
 
-        # CCMIO library
-
-        self.packages['ccmio'] = \
-            Package(name="CCMIO",
-                    description="I/O library for Star-CCM files",
-                    package="libccmio",
-                    version="2.6.1",
-                    archive="libccmio-2.6.1.tar.gz",
-                    url="https://wci.llnl.gov/codes/visit/3rd_party/%s")
-
-        # Metis library
-
-        self.packages['metis'] = \
-            MetisPackage(name="Metis",
-                         description="Graph partitioner",
-                         package="metis",
-                         version="4.0.1",
-                         archive="metis-4.0.tar.gz",
-                         url="http://glaros.dtc.umn.edu/gkhome/fetch/sw/metis/%s")
-
         # MPI library
 
         self.packages['mpi'] = \
             Package(name="MPI",
                     description="Message Passing Interface",
                     package="openmpi",
-                    version="1.4.1",
-                    archive="openmpi-1.4.1.tar.gz",
+                    version="1.4.2",
+                    archive="openmpi-1.4.2.tar.gz",
                     url="http://www.open-mpi.org/software/ompi/v1.4/downloads/%s")
 
         # Libxml2 library (official url "ftp://xmlsoft.org/libxml2/%s")
@@ -480,7 +421,7 @@ class Setup:
         try:
             setupFile = file('setup', mode='r')
         except IOError:
-            sys.stderr.write('Error : opening setup file\n')
+            sys.stderr.write('Error: opening setup file\n')
             sys.exit(1)
 
         shutil.copy('setup','setup_ini')
@@ -489,11 +430,14 @@ class Setup:
 
             line = setupFile.readline()
             if line == '': break
-            if line[0] == '#': continue
 
+            # skip comments
+            if line[0] == '#': continue
             # splitlines necessary to get rid of carriage return on IRIX64
             line = line.splitlines()
             list = line[0].split()
+            # skip blank lines
+            if len(list) == 0: continue
 
             key = list[0]
             
@@ -510,6 +454,8 @@ class Setup:
                 elif key == 'disable_gui': self.disable_gui = list[1]
                 elif key == 'python': self.python = list[1]
                 elif key == 'blas': self.blas = list[1]
+                elif key == 'metis': self.metis = list[1]
+                elif key == 'scotch': self.scotch = list[1]
                 elif key == 'syrthes': self.syrthes = list[1]
                 else:
                     p = self.packages[key]
@@ -540,6 +486,16 @@ class Setup:
             self.blas = os.path.expandvars(self.blas)
             self.blas = os.path.abspath(self.blas)
 
+        if self.metis is not None:
+            self.metis = os.path.expanduser(self.metis)
+            self.metis = os.path.expandvars(self.metis)
+            self.metis = os.path.abspath(self.metis)
+
+        if self.scotch is not None:
+            self.scotch = os.path.expanduser(self.scotch)
+            self.scotch = os.path.expandvars(self.scotch)
+            self.scotch = os.path.abspath(self.scotch)
+
         if self.syrthes is not None:
             self.syrthes = os.path.expanduser(self.syrthes)
             self.syrthes = os.path.expandvars(self.syrthes)
@@ -690,6 +646,24 @@ Check the setup file and some utilities presence.
                              % self.blas)
             sys.exit(1)
             
+        # Looking for Metis path probided by the user
+        if self.metis is not None and not os.path.isdir(self.metis):
+            sys.stderr.write("\n*** Aborting installation:\n"
+                             "\'%s\' Metis directory is provided in the setup "
+                             "file but is not a directory.\n"
+                             "Please check your setup file.\n\n"
+                             % self.metis)
+            sys.exit(1)
+            
+        # Looking for Scotch path probided by the user
+        if self.scotch is not None and not os.path.isdir(self.scotch):
+            sys.stderr.write("\n*** Aborting installation:\n"
+                             "\'%s\' Scotch directory is provided in the setup "
+                             "file but is not a directory.\n"
+                             "Please check your setup file.\n\n"
+                             % self.scotch)
+            sys.exit(1)
+            
         # Looking for SYRTHES path probided by the user
         if self.syrthes is not None and not os.path.isdir(self.syrthes):
             sys.stderr.write("\n*** Aborting installation:\n"
@@ -711,6 +685,7 @@ Check the setup file and some utilities presence.
         # Looking for pdflatex for potential documentation compilation
         ret = run_test("pdflatex")
         if ret != 0:
+            self.packages['ncs'].installation_pdf = 'no'
             sys.stderr.write("\n*** Warning: "
                              "pdflatex utility cannot be found\n"
                              "Code_Saturne documentation will not be "
@@ -718,6 +693,17 @@ Check the setup file and some utilities presence.
         else:
             self.packages['ncs'].installation_pdf = 'yes'
 
+        # Looking for fig2dev for potential documentation compilation
+        ret = run_test("fig2dev")
+        if ret != 0:
+            self.packages['ncs'].installation_pdf = 'no'
+            sys.stderr.write("\n*** Warning: "
+                             "fig2dev utility cannot be found\n"
+                             "Code_Saturne documentation will not be "
+                             "installed\n")
+        else:
+            self.packages['ncs'].installation_pdf = 'yes'
+
         if verbose == 'yes':
             sys.stdout.write("\n")
 
@@ -743,7 +729,7 @@ Check the setup file and some utilities presence.
                 p.cc = self.mpicc
             else:
                 p.cc = self.cc
-            if lib in ['med', 'lib']:
+            if lib in ['med', 'ncs']:
                 p.fc = self.fc
 
         # Update configuration options
@@ -763,15 +749,13 @@ Check the setup file and some utilities presence.
         hdf5 = self.packages['hdf5']
         med= self.packages['med']
         mpi = self.packages['mpi']
-        metis = self.packages['metis']
         libxml2 = self.packages['libxml2']
         swig = self.packages['swig']
 
-        # Disable GUI
+        # Disable GUI (and MEI Python bindings too)
 
         if self.disable_gui == 'yes':
-            mei.installation = 'no'
-            mei.use = 'no'
+            swig.use = 'no'
             ncs.config_opts = ncs.config_opts + " --disable-gui"
 
         # BFT
@@ -840,12 +824,13 @@ Check the setup file and some utilities presence.
 
         # Metis
 
-        if metis.use == 'no':
-            ecs.config_opts = ecs.config_opts + " --without-metis"
-        else:
-            if metis.install_dir is not None:
-                ecs.config_opts = ecs.config_opts + \
-                    " --with-metis=" + metis.install_dir
+        if self.metis is not None:
+            ecs.config_opts = ecs.config_opts + " --with-metis=" + self.metis
+
+        # Scotch
+
+        if self.scotch is not None:
+            ecs.config_opts = ecs.config_opts + " --with-scotch=" + self.scotch
 
         # Libxml2
 
@@ -1001,6 +986,24 @@ python    %(python)s
 blas      %(blas)s
 #
 #--------------------------------------------------------
+# Metis is more rarely found in Linux distributions,
+# but may already be installed on massively parallel
+# machines and on clusters. For good parallel
+# performance, it is highly recommended.
+# For meshes larger than 15 million cells, Metis 5.0
+# beta is recommended, as Metis 4 may fail above
+# the 20-35 million cells.
+#
+# Scotch can be use as an alternative.
+#
+# If both are present, Metis will be the default.
+# If none are present, a space-filling-curve algorithm
+# will be used.
+#--------------------------------------------------------
+metis     %(metis)s
+scotch    %(scotch)s
+#
+#--------------------------------------------------------
 # SYRTHES installation path for an optional coupling.
 #
 # Only coupling with the SYRTHES thermal code version 3
@@ -1035,7 +1038,7 @@ syrthes   %(syrthes)s
 # CGNS        For CGNS file support
 #             (used by many meshers)
 #
-# Open MPI (or MPICH2) + Metis
+# Open MPI (or MPICH2)
 #
 #   For Linux workstations, MPI, HDF5, and even MED
 # packages may be available through the package manager.
@@ -1045,15 +1048,6 @@ syrthes   %(syrthes)s
 #   For massively parallel architectures, it is
 # recommended to use the system's default MPI library.
 #
-#   Metis is more rarely found in Linux distributions,
-# but may already be installed on massively parallel
-# machines and on clusters. For good parallel
-# performance, it is highly recommended.
-# For meshes larger than 15 million cells, Metis 5.0
-# beta is recommended, as Metis 4 may fail above
-# the 20-35 million cells. But if Metis 5.0 is chosen,
-# its installation must be done manually.
-#
 #   Libxml2 is needed to read xml files output by the
 # Graphical User Interface, and swig is needed by the
 # Graphical User Interface to handle mathematical
@@ -1078,6 +1072,8 @@ syrthes   %(syrthes)s
         if self.mpicc is None: self.mpicc = ''
         if self.python is None: self.python = ''
         if self.blas is None: self.blas = ''
+        if self.metis is None: self.metis = ''
+        if self.scotch is None: self.scotch = ''
         if self.syrthes is None: self.syrthes = ''
 
         sf.write(setupMain
@@ -1087,6 +1083,7 @@ syrthes   %(syrthes)s
                      'cc':self.cc, 'fc':self.fc, 'mpicc':self.mpicc,
                      'disable_gui':self.disable_gui,
                      'python':self.python, 'blas':self.blas,
+                     'metis':self.metis, 'scotch': self.scotch,
                      'syrthes':self.syrthes })
 
         sf.write(setupLibSat)
diff --git a/extras/installer/setup b/extras/installer/setup
index 51e72bb..99cc77c 100644
--- a/extras/installer/setup
+++ b/extras/installer/setup
@@ -33,17 +33,17 @@ arch
 #--------------------------------------------------------
 # C compiler
 #--------------------------------------------------------
-compC     
+compC
 #
 #--------------------------------------------------------
 # Fortran compiler
 #--------------------------------------------------------
-compF     
+compF
 #
 #--------------------------------------------------------
 # MPI wrapper for C compiler
 #--------------------------------------------------------
-mpiCompC  
+mpiCompC
 #
 #--------------------------------------------------------
 # Disable Graphical user Interface
@@ -77,7 +77,25 @@ python
 # For a fine-tuning of BLAS library support, it may
 # be necessary to install Code_Saturne Kernel manually.
 #--------------------------------------------------------
-blas      
+blas
+#
+#--------------------------------------------------------
+# Metis is more rarely found in Linux distributions,
+# but may already be installed on massively parallel
+# machines and on clusters. For good parallel
+# performance, it is highly recommended.
+# For meshes larger than 15 million cells, Metis 5.0
+# beta is recommended, as Metis 4 may fail above
+# the 20-35 million cells.
+#
+# Scotch can be use as an alternative.
+#
+# If both are present, Metis will be the default.
+# If none are present, a space-filling-curve algorithm
+# will be used.
+#--------------------------------------------------------
+metis
+scotch
 #
 #--------------------------------------------------------
 # SYRTHES installation path for an optional coupling.
@@ -115,7 +133,7 @@ ncs    None    yes  yes
 # CGNS        For CGNS file support
 #             (used by many meshers)
 #
-# Open MPI (or MPICH2) + Metis
+# Open MPI (or MPICH2)
 #
 #   For Linux workstations, MPI, HDF5, and even MED
 # packages may be available through the package manager.
@@ -125,15 +143,6 @@ ncs    None    yes  yes
 #   For massively parallel architectures, it is
 # recommended to use the system's default MPI library.
 #
-#   Metis is more rarely found in Linux distributions,
-# but may already be installed on massively parallel
-# machines and on clusters. For good parallel
-# performance, it is highly recommended.
-# For meshes larger than 15 million cells, Metis 5.0
-# beta is recommended, as Metis 4 may fail above
-# the 20-35 million cells. But if Metis 5.0 is chosen,
-# its installation must be done manually.
-#
 #   Libxml2 is needed to read xml files output by the
 # Graphical User Interface, and swig is needed by the
 # Graphical User Interface to handle mathematical
@@ -144,7 +153,6 @@ ncs    None    yes  yes
 cgns       None    yes   yes
 hdf5       None    yes   yes
 med        None    yes   yes
-metis      None    yes   yes
 mpi        None    yes   yes
 libxml2    None    auto  no
 swig       None    auto  no
diff --git a/gui/Base/Makefile.in b/gui/Base/Makefile.in
index 9c8c229..0931196 100644
--- a/gui/Base/Makefile.in
+++ b/gui/Base/Makefile.in
@@ -73,15 +73,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -110,6 +121,7 @@ py_compile = $(top_srcdir)/config/py-compile
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -133,6 +145,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -184,6 +197,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -240,6 +254,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -277,7 +292,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/gui/Makefile.in b/gui/Makefile.in
index 55ab6ce..bbbb86e 100644
--- a/gui/Makefile.in
+++ b/gui/Makefile.in
@@ -72,15 +72,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -151,6 +162,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -174,6 +186,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -225,6 +238,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -281,6 +295,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -318,7 +333,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/gui/Pages/BatchRunningModel.py b/gui/Pages/BatchRunningModel.py
index 8203a74..b30785e 100644
--- a/gui/Pages/BatchRunningModel.py
+++ b/gui/Pages/BatchRunningModel.py
@@ -130,7 +130,6 @@ class BatchRunningModel(Model):
         self.dicoValues['PBS_nodes'] = '1'
         self.dicoValues['PBS_ppn'] = '2'
         self.dicoValues['PBS_walltime'] = '1:00:00'
-        self.dicoValues['PBS_mem'] = '320'
         self.dicoValues['EXEC_PREPROCESS'] = "yes"
         self.dicoValues['EXEC_PARTITION'] = "yes"
         self.dicoValues['EXEC_KERNEL'] = "yes"
@@ -243,7 +242,7 @@ class BatchRunningModel(Model):
         """
         lines = self.lines
 
-        list = ['PBS_JOB_NAME','PBS_nodes','PBS_ppn','PBS_walltime','PBS_mem']
+        list = ['PBS_JOB_NAME','PBS_nodes','PBS_ppn','PBS_walltime']
 
         for k in self.dicoValues.keys():
             if k not in list and k not in ('THERMOCHEMISTRY_DATA', 'METEO_DATA'):
@@ -264,24 +263,39 @@ class BatchRunningModel(Model):
                                 #
                                 pass
 
+        # TODO: specialize for PBS Professional and TORQUE (OpenPBS has not been
+        # maintained since 2004, so we do not expect to encounter it).
+        # We use the "-l nodes=N:ppn=P" syntax here, which common to all PBS
+        # variants, but PBS Pro considers the syntax depecated, and prefers its
+        # own "-l select=N:ncpus=P:mpiprocs=P" syntax.
+        # We do not have access to a PBS Professional system, but according to
+        # its documentation, it has commands such as "pbs-report" or "pbs_probe"
+        # which are not part of TORQUE, while the latter has "pbsnodelist" or
+        # #pbs-config". The presence of either could help determine which
+        # system is available.
+
         if self.case['computer'] == "pbs":
-            for (word, ind, lab) in [('#PBS -j eo -N ', 0, 'PBS_JOB_NAME')]:
-                for i in range(len(lines)):
-                    index = string.rfind(lines[i], word)
-                    if index == ind:
-                        self.dicoValues[lab] = self._removeQuotes(lines[i], ind, word)
-
-            for (word, next, lab) in [('#PBS -l nodes', ':ppn'    , 'PBS_nodes'),
-                                      (':ppn'         ,',walltime', 'PBS_ppn'),
-                                      (',walltime'    ,',mem'    , 'PBS_walltime'),
-                                      (',mem'        , 'mb'     , 'PBS_mem')]:
-                word = word + "="
-                for i in range(len(lines)):
-                    ind1 = string.rfind(lines[i], word)
-                    ind2 = string.rfind(lines[i], next)
-                    if ind1 != -1 and ind2 != -1:
-                        ch = lines[i][ind1+len(word):ind2]
-                        self.dicoValues[lab] = ch
+            for i in range(len(lines)):
+                if lines[i][0:4] == "#PBS":
+                    try:
+                        batch_args = lines[i][4:]
+                        index = string.rfind(batch_args, '\n')
+                        batch_args = batch_args[0:index]
+                        index = string.rfind(batch_args, ' -')
+                        while index > -1:
+                            arg = batch_args[index+1:]
+                            batch_args = batch_args[0:index]
+                            if arg[0:2] == "-N":
+                                self.dicoValues['PBS_JOB_NAME'] = arg.split()[1]
+                            elif arg[0:9] == "-l nodes=":
+                                arg_tmp = arg[9:].split(':')
+                                self.dicoValues['PBS_nodes'] = arg_tmp[0]
+                                self.dicoValues['PBS_ppn'] = arg_tmp[1].split('=')[1]
+                            elif arg[0:12] == "-l walltime=":
+                                self.dicoValues['PBS_walltime'] = arg.split('=')[1]
+                            index = string.rfind(batch_args, ' -')
+                    except Exception:
+                        pass
 
         self.initializeBatchScriptFile()
 
@@ -367,27 +381,28 @@ class BatchRunningModel(Model):
 
         #  keywords only for the PBS Cluster
         if self.case['computer'] == "pbs":
-            for (word, ind, var) in [('#PBS -j eo -N ', 0, self.dicoValues['PBS_JOB_NAME'])]:
-                for i in range(len(lines)):
-                    index = string.rfind(lines[i], word)
-                    if index == ind:
-                        if type(var) != types.StringType :
-                            var = str(var)
-                            if var == "0" : var=""
-                        lines[i] = word + var + '\n'
-
-            for (word, ind, next) in [('#PBS -l nodes', 0, ':ppn')]:
-                for i in range(len(lines)):
-                    ind1 = string.rfind(lines[i], word)
-                    ind2 = string.rfind(lines[i], next)
-                    if ind1 == ind and ind2 != -1:
-                        ch = ""
-                        for (w, dic) in [('#PBS -l nodes=', self.dicoValues['PBS_nodes']),
-                                         (':ppn=',          self.dicoValues['PBS_ppn']),
-                                         (',walltime=',     self.dicoValues['PBS_walltime']),
-                                         (',mem=',          self.dicoValues['PBS_mem'])]:
-                            ch = ch + w + str(dic)
-                        lines[i] = ch + "mb\n"
+            for i in range(len(lines)):
+                if lines[i][0:4] == "#PBS":
+                    ch = "\n"
+                    batch_args = lines[i][4:]
+                    index = string.rfind(batch_args, '\n')
+                    batch_args = batch_args[0:index]
+                    index = string.rfind(batch_args, ' -')
+                    while index > -1:
+                        arg = batch_args[index+1:]
+                        batch_args = batch_args[0:index]
+                        if arg[0:2] == "-N":
+                            ch = " -N " + self.dicoValues['PBS_JOB_NAME'] + ch
+                        elif arg[0:9] == "-l nodes=":
+                            ch = " -l nodes=" + self.dicoValues['PBS_nodes'] \
+                                +  ":ppn=" + self.dicoValues['PBS_ppn'] + ch
+                        elif arg[0:12] == "-l walltime=":
+                            ch = " -l walltime=" + self.dicoValues['PBS_walltime'] + ch
+                        else:
+                            ch = ' ' + arg + ch
+                        index = string.rfind(batch_args, ' -')
+                    ch = "#PBS" + ch
+                    lines[i] = ch
 
         f = open(self.script1, 'w')
         f.writelines(lines)
@@ -454,7 +469,7 @@ class BatchRunningModelTestCase(unittest.TestCase):
         '#\n'\
         '#                  CARTES BATCH POUR CLUSTERS sous PBS\n'\
         '#\n'\
-        '#PBS -l nodes=16:ppn=1,walltime=34:77:22,mem=832mb\n'\
+        '#PBS -l nodes=16:ppn=1,walltime=34:77:22\n'\
         '#PBS -j eo -N super_toto\n'
 
         lance_LSF = '# test \n'\
@@ -591,7 +606,6 @@ class BatchRunningModelTestCase(unittest.TestCase):
         'CS_TMP_PREFIX': '/home/toto',
         'PBS_ppn': '2',
         'PBS_walltime': '1:00:00',
-        'PBS_mem': '320',
         'COMMAND_PERIO': '',
         'EXEC_PREPROCESS':'yes',
         'EXEC_PARTITION':'yes',
@@ -639,7 +653,6 @@ class BatchRunningModelTestCase(unittest.TestCase):
         'CS_TMP_PREFIX': '',
         'PBS_ppn': '1',
         'PBS_walltime': '34:77:22',
-        'PBS_mem': '832',
         'COMMAND_PERIO': ''}
 
         for k in dico_PBS.keys():
@@ -667,7 +680,6 @@ class BatchRunningModelTestCase(unittest.TestCase):
         """ Check whether the BatchRunningModel class could update file"""
         mdl = BatchRunningModel(self.case)
         mdl.readBatchScriptFile()
-        mdl.dicoValues['PBS_mem']='512'
         mdl.dicoValues['PBS_walltime']='12:42:52'
         dicoPBS_updated = mdl.dicoValues
         mdl.updateBatchScriptFile()
diff --git a/gui/Pages/BatchRunningPBSJobManagementDialogForm.ui b/gui/Pages/BatchRunningPBSJobManagementDialogForm.ui
index 43cd8b3..c48e112 100644
--- a/gui/Pages/BatchRunningPBSJobManagementDialogForm.ui
+++ b/gui/Pages/BatchRunningPBSJobManagementDialogForm.ui
@@ -5,8 +5,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>290</width>
-    <height>214</height>
+    <width>385</width>
+    <height>190</height>
    </rect>
   </property>
   <property name="windowTitle" >
@@ -42,13 +42,6 @@
           </property>
          </widget>
         </item>
-        <item>
-         <widget class="QLabel" name="label_8" >
-          <property name="text" >
-           <string>Memory (Mb)</string>
-          </property>
-         </widget>
-        </item>
        </layout>
       </item>
       <item>
@@ -181,9 +174,6 @@
           </item>
          </layout>
         </item>
-        <item>
-         <widget class="QLineEdit" name="lineEditMemory" />
-        </item>
        </layout>
       </item>
      </layout>
diff --git a/gui/Pages/BatchRunningView.py b/gui/Pages/BatchRunningView.py
index 58b9cb1..877174c 100644
--- a/gui/Pages/BatchRunningView.py
+++ b/gui/Pages/BatchRunningView.py
@@ -379,13 +379,12 @@ class BatchRunningPBSJobManagementDialogView(QDialog, Ui_BatchRunningPBSJobManag
         self.result  = self.default.copy()
 
         # Validators
-        validatorJobName  = RegExpValidator(rx, self.lineEditJobName, QRegExp("[_A-Za-z0-9]*"))
+        validatorJobName  = RegExpValidator(self.lineEditJobName, QRegExp("[_A-Za-z0-9]*"))
         validatorNodes    = IntValidator(self.lineEditNodes, min=1)
-        validatorCPUNodes = IntValidator(self.lineEditCPUNodes, min=1, max=2)
+        validatorCPUNodes = IntValidator(self.lineEditCPUNodes, min=1, max=32)
         validatorHours    = IntValidator(self.lineEditHours, min=0, max=999)
         validatorMinutes  = IntValidator(self.lineEditMinutes, min=0, max=59)
         validatorSeconds  = IntValidator(self.lineEditSeconds, min=0, max=59)
-        validatorMemory   = IntValidator(self.lineEditMemory, min=1, max=9999999)
 
         self.lineEditJobName.setValidator(validatorJobName)
         self.lineEditNodes.setValidator(validatorNodes)
@@ -394,13 +393,11 @@ class BatchRunningPBSJobManagementDialogView(QDialog, Ui_BatchRunningPBSJobManag
         self.lineEditHours.setValidator(validatorHours)
         self.lineEditMinutes.setValidator(validatorMinutes)
         self.lineEditSeconds.setValidator(validatorSeconds)
-        self.lineEditMemory.setValidator(validatorMemory)
 
         # Previous values
         self.job_name     = self.default['PBS_JOB_NAME']
         self.cluster_node = self.default['PBS_nodes']
         self.cluster_ppn  = self.default['PBS_ppn']
-        self.job_mem      = self.default['PBS_mem']
         L = string.split(self.default['PBS_walltime'], ":")
         self.h_cput = L[0]
         self.m_cput = L[1]
@@ -413,7 +410,6 @@ class BatchRunningPBSJobManagementDialogView(QDialog, Ui_BatchRunningPBSJobManag
         self.lineEditHours.setText(QString(str(self.h_cput)))
         self.lineEditMinutes.setText(QString(str(self.m_cput)))
         self.lineEditSeconds.setText(QString(str(self.s_cput)))
-        self.lineEditMemory.setText(QString(str(self.job_mem)))
 
 
     def get_result(self):
@@ -439,8 +435,6 @@ class BatchRunningPBSJobManagementDialogView(QDialog, Ui_BatchRunningPBSJobManag
             m_cput = str(self.lineEditMinutes.text())
             s_cput = str(self.lineEditSeconds.text())
             self.result['PBS_walltime'] = h_cput + ":" + m_cput + ":" + s_cput
-        if self.lineEditMemory.validator().state == QValidator.Acceptable:
-            self.result['PBS_mem']  = str(self.lineEditMemory.text())
 
         QDialog.accept(self)
 
@@ -862,7 +856,7 @@ class BatchRunningView(QWidget, Ui_BatchRunningForm):
         Get PBS card informations.
         """
         default = {}
-        list = ['PBS_JOB_NAME', 'PBS_nodes', 'PBS_ppn', 'PBS_walltime', 'PBS_mem']
+        list = ['PBS_JOB_NAME', 'PBS_nodes', 'PBS_ppn', 'PBS_walltime']
         for opt in list:
             default[opt] = self.mdl.dicoValues[opt]
         log.debug("pbsJobManagement -> %s" % str(default))
@@ -887,14 +881,12 @@ class BatchRunningView(QWidget, Ui_BatchRunningForm):
 ##        default['job_name'] = self.mdl.dicoValues['PBS_JOB_NAME']
 ##        default['NQS_cput'] =
 ##        default['NQS_cpuT'] =
-##        default['NQS_mem'] =
 ##        windowTitle = self.tr("CaThy")
 ##        dialog = LSFJobManagementDialog(self.myPage, title=t.CATHY, default=default)
 ##
 ##        self.job_name = dialog.result['job_name']
 ##        self.NQS_cpult = dialog.result['NQS_cput']
 ##        self.NQS_cpulT = dialog.result['NQS_cpuT'] + dialog.result['NQS_cput']
-##        self.job_memory = dialog.result['NQS_mem']
 ##
 ##        self.mdl.updateBatchScriptFile()
 
diff --git a/gui/Pages/Boundary.py b/gui/Pages/Boundary.py
index b78437a..92bb4e2 100644
--- a/gui/Pages/Boundary.py
+++ b/gui/Pages/Boundary.py
@@ -1180,7 +1180,7 @@ class WallBoundary(Boundary) :
         scalarNode = self.boundNode.xmlInitNode('scalar', label=label)
 
         if tag == 'exchange_coefficient':
-            scalarNode.xmlRemoveChild('dirichlet')
+            scalarNode.xmlRemoveChild('neumann')
         else:
             for tt in ('dirichlet', 'neumann'):
                 if tt != tag:
@@ -1386,7 +1386,7 @@ class WallBoundary(Boundary) :
             self.getScalarImposedFlux(label)
             self.__deleteScalarNodes(label, 'neumann')
         elif choice == 'exchange_coefficient':
-            self.getScalarImposedFlux(label)
+            self.getScalarImposedValue(label)
             self.getScalarExchangeCoefficient(label)
             self.__deleteScalarNodes(label, 'exchange_coefficient')
 
@@ -1405,7 +1405,7 @@ class WallBoundary(Boundary) :
 
         choice = self.getScalarChoice(label)
         if choice == 'exchange_coefficient':
-            choice = 'neumann'
+            choice = 'dirichlet'
 
         value = scalarNode.xmlGetChildDouble(choice)
         if value == None :
@@ -1428,7 +1428,7 @@ class WallBoundary(Boundary) :
 
         choice = self.getScalarChoice(label)
         if choice == 'exchange_coefficient':
-            choice = 'neumann'
+            choice = 'dirichlet'
 
         scalarNode.xmlSetData(choice, value)
 
@@ -1438,7 +1438,7 @@ class WallBoundary(Boundary) :
         Get scalar dirichlet value
         """
         Model().isInList(label, self.sca_model.getScalarLabelsList())
-        Model().isInList(self.getScalarChoice(label), ('dirichlet',))
+        Model().isInList(self.getScalarChoice(label), ('dirichlet', 'exchange_coefficient'))
 
         scalarNode = self.boundNode.xmlInitNode('scalar', label=label)
 
@@ -1459,7 +1459,7 @@ class WallBoundary(Boundary) :
         """
         Model().isFloat(value)
         Model().isInList(label, self.sca_model.getScalarLabelsList())
-        Model().isInList(self.getScalarChoice(label), ('dirichlet',))
+        Model().isInList(self.getScalarChoice(label), ('dirichlet', 'exchange_coefficient'))
 
         scalarNode = self.boundNode.xmlInitNode('scalar', label=label)
 
@@ -1474,7 +1474,7 @@ class WallBoundary(Boundary) :
         Get scalar neumann value
         """
         Model().isInList(label, self.sca_model.getScalarLabelsList())
-        Model().isInList(self.getScalarChoice(label), ('neumann', 'exchange_coefficient'))
+        Model().isInList(self.getScalarChoice(label), ('neumann',))
 
         scalarNode = self.boundNode.xmlInitNode('scalar', label=label)
 
@@ -1495,7 +1495,7 @@ class WallBoundary(Boundary) :
         """
         Model().isFloat(value)
         Model().isInList(label, self.sca_model.getScalarLabelsList())
-        Model().isInList(self.getScalarChoice(label), ('neumann', 'exchange_coefficient'))
+        Model().isInList(self.getScalarChoice(label), ('neumann',))
 
         scalarNode = self.boundNode.xmlInitNode('scalar', label=label)
 
@@ -3018,7 +3018,7 @@ class WallBoundaryTestCase(ModelTest):
                     <wall label="mur">
                         <velocity_pressure choice="off"/>
                         <scalar choice="exchange_coefficient" label="sca1" name="scalar1" type="user">
-                            <neumann>0.0</neumann>
+                            <dirichlet>0.0</dirichlet>
                             <exchange_coefficient>0.0</exchange_coefficient>
                         </scalar>
                         <scalar choice="dirichlet" label="sca2" name="scalar2" type="user">
@@ -3034,14 +3034,14 @@ class WallBoundaryTestCase(ModelTest):
            'Could not get scalar choice for wall boundary'
 
 
-    def checkSetAndGetScalarImposedValueFluxAndExchangeCoefficient(self):
+    def checkSetAndGetScalarImposedValueAndExchangeCoefficient(self):
         """Check whether the scalar values could be set and get for wall boundary."""
         model = Boundary("wall", "mur", self.case)
         model.sca_model.addUserScalar('1', 'sca1')
         model.sca_model.addUserScalar('1', 'sca2')
         model.setScalarChoice('sca1', 'exchange_coefficient')
         model.setScalarChoice('sca2', 'dirichlet')
-        model.setScalarImposedFlux('sca1', 130.)
+        model.setScalarImposedValue('sca1', 130.)
         model.setScalarExchangeCoefficient('sca1', 0.130)
         model.setScalarImposedValue('sca2', 55.)
         node =  model._XMLBoundaryConditionsNode
@@ -3050,7 +3050,7 @@ class WallBoundaryTestCase(ModelTest):
                     <wall label="mur">
                         <velocity_pressure choice="off"/>
                         <scalar choice="exchange_coefficient" label="sca1" name="scalar1" type="user">
-                            <neumann>130.0</neumann>
+                            <dirichlet>130.0</dirichlet>
                             <exchange_coefficient>0.130</exchange_coefficient>
                         </scalar>
                         <scalar choice="dirichlet" label="sca2" name="scalar2" type="user">
@@ -3065,7 +3065,7 @@ class WallBoundaryTestCase(ModelTest):
         assert model.getScalarImposedValue('sca2') == 55.,\
            'Could not get scalar imposed value for wall boundary'
 
-        assert model.getScalarImposedFlux('sca1') == 130.,\
+        assert model.getScalarImposedValue('sca1') == 130.,\
             'Could not get scalar imposed value for wall boundary'
 
         assert model.getScalarExchangeCoefficient('sca1') == 0.130,\
diff --git a/gui/Pages/BoundaryConditionsScalarsView.py b/gui/Pages/BoundaryConditionsScalarsView.py
index 077066c..3a6a3a8 100644
--- a/gui/Pages/BoundaryConditionsScalarsView.py
+++ b/gui/Pages/BoundaryConditionsScalarsView.py
@@ -198,7 +198,7 @@ class StandardItemModelScalars(QStandardItemModel):
                 line[2] = self.boundary.getScalarImposedFlux(s_label)
                 if (row,3) not in self._disabled: self._disabled.append((row,3))
             elif choice == 'exchange_coefficient':
-                line[2] = self.boundary.getScalarImposedFlux(s_label)
+                line[2] = self.boundary.getScalarImposedValue(s_label)
                 line[3] = self.boundary.getScalarExchangeCoefficient(s_label)
                 if (row,3) in self._disabled: self._disabled.remove((row,3))
 
@@ -290,7 +290,7 @@ class StandardItemModelScalars(QStandardItemModel):
 
             elif type == 'exchange_coefficient':
                 if (row,3) in self._disabled: self._disabled.remove((row,3))
-                self._data[row][2] = self.boundary.getScalarImposedFlux(s_label)
+                self._data[row][2] = self.boundary.getScalarImposedValue(s_label)
                 self._data[row][3] = self.boundary.getScalarExchangeCoefficient(s_label)
 
         # value(s) associated to the choice
@@ -302,9 +302,9 @@ class StandardItemModelScalars(QStandardItemModel):
             if self.nature == 'inlet':
                 self.boundary.setScalar(s_label, val)
             elif self.nature == 'wall':
-                if choice == 'dirichlet':
+                if choice == 'dirichlet' or choice == 'exchange_coefficient':
                     self.boundary.setScalarImposedValue(s_label, val)
-                elif choice == 'neumann' or choice == 'exchange_coefficient':
+                elif choice == 'neumann':
                     self.boundary.setScalarImposedFlux(s_label, val)
             elif self.nature == 'outlet':
                 self.boundary.setScalar(s_label, val)
diff --git a/gui/Pages/Makefile.am b/gui/Pages/Makefile.am
index 9c1b56c..c0e22c6 100644
--- a/gui/Pages/Makefile.am
+++ b/gui/Pages/Makefile.am
@@ -210,7 +210,7 @@ WelcomeForm.ui
 # PyQt Resources files
 
 QRCFILES = \
-resources_pages_rc.py
+resources_pages.qrc
 
 # Generated files
 
diff --git a/gui/Pages/Makefile.in b/gui/Pages/Makefile.in
index ffcc612..ad18692 100644
--- a/gui/Pages/Makefile.in
+++ b/gui/Pages/Makefile.in
@@ -73,15 +73,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -110,6 +121,7 @@ py_compile = $(top_srcdir)/config/py-compile
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -133,6 +145,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -184,6 +197,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -240,6 +254,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -277,7 +292,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -494,7 +508,7 @@ WelcomeForm.ui
 
 # PyQt Resources files
 QRCFILES = \
-resources_pages_rc.py
+resources_pages.qrc
 
 
 # Generated files
diff --git a/include/base/cplsat.h b/include/base/cplsat.h
index 7a284ba..0e1daa6 100644
--- a/include/base/cplsat.h
+++ b/include/base/cplsat.h
@@ -45,11 +45,12 @@ parameter(nbcpmx=10)
 
 ! ITURCP(NBCPMX,NPHSMX) : MODELE DE TURBULENCE DE L'INSTANCE DISTANTE
 ! IMAJCP(NBCPMX)        : INDICE DE MISE A JOUR DE LA LOCALISATION DU COUPLAGE
+! ICORMX(NBCPMX)        : INDICE DE PRESENCE DE CALCUL EN REPERE RELATIF
 ! NVARCP(NBCPMX)        : NOMBRE DE VARIABLE A ENVOYER/RECEVOIR
 ! NVARTO(NBCPMX)        : TAILLE DES TABLEAUX D'ECHANGE
 
 
-integer           iturcp(nbcpmx,nphsmx), imajcp(nbcpmx)
+integer           iturcp(nbcpmx,nphsmx), imajcp(nbcpmx), icormx(nbcpmx)
 integer           nvarcp(nbcpmx), nvarto(nbcpmx)
-common / icplcs / iturcp, imajcp, nvarcp, nvarto
+common / icplcs / iturcp, imajcp, icormx, nvarcp, nvarto
 
diff --git a/include/base/cs_join.h b/include/base/cs_join.h
index 3935cf4..5ce3fb0 100644
--- a/include/base/cs_join.h
+++ b/include/base/cs_join.h
@@ -55,23 +55,10 @@ BEGIN_C_DECLS
  * Type definition
  *===========================================================================*/
 
-typedef struct {
-
-  cs_join_param_t   param;      /* Set of parameters used to control
-                                   the joining operations */
-
-  char             *criteria;   /* Criteria used to select border faces
-                                   implied in the joining operation */
-
-} cs_join_t;
-
 /*=============================================================================
  * Global variables
  *===========================================================================*/
 
-extern cs_int_t  cs_glob_n_joinings;
-extern cs_join_t  **cs_glob_join_array;
-
 /*============================================================================
  *  Public function prototypes for Fortran API
  *============================================================================*/
@@ -152,7 +139,6 @@ void CS_PROCF(setajp, SETAJP)
  cs_int_t    *tml,
  cs_int_t    *tmb,
  cs_real_t   *tmr
- CS_ARGF_SUPP_CHAINE
 );
 
 /*=============================================================================
@@ -160,14 +146,15 @@ void CS_PROCF(setajp, SETAJP)
  *===========================================================================*/
 
 /*----------------------------------------------------------------------------
- * Create and initialize a cs_join_t structure.
+ * Add a cs_join_t structure to the list of pending joinings.
  *
  * parameters:
- *   join_number   <-- number related to the joining operation
- *   sel_criteria  <-- boundary face selection criteria
- *   fraction      <-- value of the fraction parameter
- *   plane         <-- value of the plane parameter
- *   verbosity     <-- level of verbosity required
+ *   join_number  <-- number related to the joining operation
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   perio_num    <-- periodicity number (0 if not a periodic joining)
+ *   verbosity    <-- level of verbosity required
  *---------------------------------------------------------------------------*/
 
 void
@@ -178,34 +165,6 @@ cs_join_add(int     join_number,
             int     verbosity);
 
 /*----------------------------------------------------------------------------
- * Set advanced parameters to user-defined values.
- *
- * parameters:
- *   join           <-> pointer a to cs_join_t struct. to update
- *   mtf            <-- merge tolerance coefficient
- *   pmf            <-- pre-merge factor
- *   tcm            <-- tolerance computation mode
- *   icm            <-- intersection computation mode
- *   maxbrk         <-- max number of equivalences to break (merge step)
- *   max_sub_faces  <-- max. possible number of sub-faces by splitting a face
- *   tml            <-- tree max level
- *   tmb            <-- tree max boxes
- *   tmr            <-- tree max ratio
- *---------------------------------------------------------------------------*/
-
-void
-cs_join_set_advanced_param(cs_join_t   *join,
-                           cs_real_t    mtf,
-                           cs_real_t    pmf,
-                           cs_int_t     tcm,
-                           cs_int_t     icm,
-                           cs_int_t     maxbrk,
-                           cs_int_t     max_sub_faces,
-                           cs_int_t     tml,
-                           cs_int_t     tmb,
-                           cs_real_t    tmr);
-
-/*----------------------------------------------------------------------------
  * Apply all the defined joining operations.
  *---------------------------------------------------------------------------*/
 
diff --git a/include/base/cs_join_intersect.h b/include/base/cs_join_intersect.h
index 60fe6c3..8c3ac25 100644
--- a/include/base/cs_join_intersect.h
+++ b/include/base/cs_join_intersect.h
@@ -3,7 +3,7 @@
   This file is part of the "Finite Volume Mesh" library, intended to provide
   finite volume mesh and associated fields I/O and manipulation services.
 
-  Copyright (C) 2008-2009  EDF
+  Copyright (C) 2008-2010  EDF
 
   This library is free software; you can redistribute it and/or
   modify it under the terms of the GNU Lesser General Public
@@ -253,13 +253,15 @@ cs_join_inter_edges_block_to_part(fvm_gnum_t                    n_g_edges,
  * Add future new vertices for the face definition in cs_join_mesh_t
  *
  * parameters:
+ *   verbosity   <-- verbosity level
  *   edges       <-- cs_join_edges_t structure
  *   mesh        <-> cs_join_mesh_t structure
  *   inter_edges <-> current cs_join_inter_edges_t struct. to work with
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_intersect_update_struct(const cs_join_edges_t   *edges,
+cs_join_intersect_update_struct(int                      verbosity,
+                                const cs_join_edges_t   *edges,
                                 cs_join_mesh_t          *mesh,
                                 cs_join_inter_edges_t  **inter_edges);
 
diff --git a/include/base/cs_join_merge.h b/include/base/cs_join_merge.h
index 6e2c48b..0e4b794 100644
--- a/include/base/cs_join_merge.h
+++ b/include/base/cs_join_merge.h
@@ -76,7 +76,7 @@ BEGIN_C_DECLS
  *   work               <-> joining mesh maintaining initial vertex data
  *   inter_set          <-> cs_join_inter_set_t structure including
  *                          data on edge-edge  intersections
- *   n_g_vertices       <-- global number of vertices (initial parent mesh)
+ *   init_max_vtx_gnum  <-- initial max. global number for vertices
  *   p_n_g_new_vertices <-> pointer to the global number of new vertices
  *   p_vtx_eset         <-> pointer to a structure dealing with vertex
  *                          equivalences
@@ -87,7 +87,7 @@ cs_join_create_new_vertices(int                     verbosity,
                             const cs_join_edges_t  *edges,
                             cs_join_mesh_t         *work,
                             cs_join_inter_set_t    *inter_set,
-                            fvm_gnum_t              n_g_vertices,
+                            fvm_gnum_t              init_max_vtx_gnum,
                             fvm_gnum_t             *p_n_g_new_vertices,
                             cs_join_eset_t        **p_vtx_eset);
 
@@ -121,8 +121,8 @@ cs_join_merge_vertices(cs_join_param_t        param,
  * parameters:
  *   param                <-- set of user-defined parameters for the joining
  *   n_iwm_vertices       <-- initial number of vertices (work mesh struct.)
- *   n_g_ifm_vertices     <-- initial global number of vertices (full mesh)
  *   iwm_vtx_gnum         <-- initial global vertex num. (work mesh struct)
+ *   init_max_vtx_gnum    <-- initial max. global number for vertices
  *   rank_face_gnum_index <-- index on face global numbering to determine
  *                            the related rank
  *   p_mesh               <-> pointer to cs_join_mesh_t structure
@@ -136,8 +136,8 @@ cs_join_merge_vertices(cs_join_param_t        param,
 void
 cs_join_merge_update_struct(cs_join_param_t          param,
                             cs_int_t                 n_iwm_vertices,
-                            fvm_gnum_t               n_g_ifm_vertices,
                             const fvm_gnum_t         iwm_vtx_gnum[],
+                            fvm_gnum_t               init_max_vtx_gnum,
                             const fvm_gnum_t         rank_face_gnum_index[],
                             cs_join_mesh_t         **p_mesh,
                             cs_join_edges_t        **p_edges,
diff --git a/include/base/cs_join_mesh.h b/include/base/cs_join_mesh.h
index d1ee844..f3d7d8d 100644
--- a/include/base/cs_join_mesh.h
+++ b/include/base/cs_join_mesh.h
@@ -74,10 +74,11 @@ typedef enum {
 
 typedef struct {
 
-  double       tolerance;  /* Tolerance = radius of the sphere in which
-                              intersection and merge is possible. */
-  cs_real_t    coord[3];   /* Coordinates of the vertex */
-  fvm_gnum_t   gnum;       /* Global vertex number */
+  cs_join_state_t  state;      /* State of the vertices (perio/origin/...) */
+  fvm_gnum_t       gnum;       /* Global vertex number */
+  double           tolerance;  /* Tolerance = radius of the sphere in which
+                                  intersection and merge is possible. */
+  double           coord[3];   /* Coordinates of the vertex */
 
 } cs_join_vertex_t;
 
@@ -158,10 +159,11 @@ cs_join_mesh_create_vtx_datatype(void);
  *   datatype  <--  MPI_datatype associated to cs_join_vertex_t
  *---------------------------------------------------------------------------*/
 
-void  cs_join_mesh_mpi_vertex_min(cs_join_vertex_t   *in,
-                                  cs_join_vertex_t   *inout,
-                                  int                *len,
-                                  MPI_Datatype       *datatype);
+void
+cs_join_mesh_mpi_vertex_min(cs_join_vertex_t   *in,
+                            cs_join_vertex_t   *inout,
+                            int                *len,
+                            MPI_Datatype       *datatype);
 
 /*----------------------------------------------------------------------------
  * Create a function to define an operator for MPI reduction operation
@@ -173,10 +175,11 @@ void  cs_join_mesh_mpi_vertex_min(cs_join_vertex_t   *in,
  *   datatype  <--  MPI_datatype associated to cs_join_vertex_t
  *---------------------------------------------------------------------------*/
 
-void  cs_join_mesh_mpi_vertex_max(cs_join_vertex_t   *in,
-                                  cs_join_vertex_t   *inout,
-                                  int                *len,
-                                  MPI_Datatype       *datatype);
+void
+cs_join_mesh_mpi_vertex_max(cs_join_vertex_t   *in,
+                            cs_join_vertex_t   *inout,
+                            int                *len,
+                            MPI_Datatype       *datatype);
 
 #endif /* HAVE_MPI */
 
@@ -241,38 +244,36 @@ cs_join_mesh_create_from_subset(const char            *mesh_name,
                                 const cs_join_mesh_t  *parent_mesh);
 
 /*----------------------------------------------------------------------------
- * Allocate and define a cs_join_mesh_t structure relative to an extraction
- * of selected faces.
+ * Define a cs_join_mesh_t structure from a selection of faces and its
+ * related vertices.
  *
  * parameters:
- *   mesh_name           <-- name of the mesh to create
- *   n_faces             <-- number of selected faces
- *   n_g_faces           <-- global number of selected faces
- *   selected_faces      <-- list of selected faces (based on parent mesh)
- *   face_gnum           <-- global face numbers
- *   face_vtx_idx        <-- "face -> vertex" connectivity index
- *   face_vtx_lst        <-- "face -> vertex" connectivity
- *   n_select_vertices   <-- number of vertices used in joining operation
- *   n_g_select_vertices <-- global number of vertices used in joining
- *   select_vertices     <-- list of selected vertices (based on parent mesh)
- *   vtx_data            <-- array on data associated to selected vertices
+ *   name       <-- mesh name of the resulting cs_join_mesh_t structure
+ *   param      <-- set of user-defined parameters for the joining
+ *   selection  <-> selected entities
+ *   b_f2v_idx  <-- border "face -> vertex" connectivity index
+ *   b_f2v_lst  <-- border "face -> vertex" connectivity
+ *   i_f2v_idx  <-- interior "face -> vertex" connectivity index
+ *   i_f2v_lst  <-- interior "face -> vertex" connectivity
+ *   n_vertices <-- number of vertices in the parent mesh
+ *   vtx_coord  <-- vertex coordinates in parent mesh
+ *   vtx_gnum   <-- global numbering of vertices
  *
  * returns:
  *   a pointer to a cs_join_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 cs_join_mesh_t *
-cs_join_mesh_create_from_extract(const char              *mesh_name,
-                                 cs_int_t                 n_faces,
-                                 fvm_gnum_t               n_g_faces,
-                                 const cs_int_t           selected_faces[],
-                                 const fvm_gnum_t         face_gnum[],
-                                 const cs_int_t           face_vtx_idx[],
-                                 const cs_int_t           face_vtx_lst[],
-                                 cs_int_t                 n_select_vertices,
-                                 fvm_gnum_t               n_g_select_vertices,
-                                 const cs_int_t           selected_vertices[],
-                                 const cs_join_vertex_t  *vtx_data);
+cs_join_mesh_create_from_select(const char              *name,
+                                const cs_join_param_t    param,
+                                cs_join_select_t        *selection,
+                                const cs_int_t           b_f2v_idx[],
+                                const cs_int_t           b_f2v_lst[],
+                                const cs_int_t           i_f2v_idx[],
+                                const cs_int_t           i_f2v_lst[],
+                                const cs_int_t           n_vertices,
+                                const cs_real_t          vtx_coord[],
+                                const fvm_gnum_t         vtx_gnum[]);
 
 /*----------------------------------------------------------------------------
  * Destroy a cs_join_mesh_t structure.
@@ -341,6 +342,19 @@ cs_join_mesh_exchange(int                    n_ranks,
                       cs_join_mesh_t        *recv_mesh,
                       MPI_Comm               comm);
 
+/*----------------------------------------------------------------------------
+ * Synchronize vertices definition over the ranks.
+ *
+ * For vertices with the same global number but a different tolerance,
+ * we keep the smallest tolerance.
+ *
+ * parameters:
+ *  mesh <->  pointer to the cs_join_mesh_t structure to synchronize
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_mesh_sync_vertices(cs_join_mesh_t  *mesh);
+
 #endif /* defined(HAVE_MPI) */
 
 /*----------------------------------------------------------------------------
@@ -354,7 +368,7 @@ void
 cs_join_mesh_destroy_edges(cs_join_edges_t  **edges);
 
 /*----------------------------------------------------------------------------
- * Order a cs_join_mesh_t structure according to the global face numbering
+ * Order a cs_join_mesh_t structure according to its global face numbering
  *
  * Delete redundancies.
  *
diff --git a/include/base/cs_join_perio.h b/include/base/cs_join_perio.h
new file mode 100644
index 0000000..c8ee260
--- /dev/null
+++ b/include/base/cs_join_perio.h
@@ -0,0 +1,416 @@
+/*============================================================================
+ *
+ *     This file is part of the Code_Saturne Kernel, element of the
+ *     Code_Saturne CFD tool.
+ *
+ *     Copyright (C) 2008-2010 EDF S.A., France
+ *
+ *     contact: saturne-support at edf.fr
+ *
+ *     The Code_Saturne Kernel is free software; you can redistribute it
+ *     and/or modify it under the terms of the GNU General Public License
+ *     as published by the Free Software Foundation; either version 2 of
+ *     the License, or (at your option) any later version.
+ *
+ *     The Code_Saturne Kernel 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 General Public License for more details.
+ *
+ *     You should have received a copy of the GNU General Public License
+ *     along with the Code_Saturne Kernel; if not, write to the
+ *     Free Software Foundation, Inc.,
+ *     51 Franklin St, Fifth Floor,
+ *     Boston, MA  02110-1301  USA
+ *
+ *============================================================================*/
+
+#ifndef __CS_JOIN_PERIO_H__
+#define __CS_JOIN_PERIO_H__
+
+/*============================================================================
+ * Structure and function headers handling with periodicity for joining
+ * operations
+ *===========================================================================*/
+
+/*----------------------------------------------------------------------------
+ * FVM library headers
+ *---------------------------------------------------------------------------*/
+
+/*----------------------------------------------------------------------------
+ *  Local headers
+ *---------------------------------------------------------------------------*/
+
+#include "cs_base.h"
+#include "cs_mesh.h"
+#include "cs_join_set.h"
+#include "cs_join_util.h"
+#include "cs_join_mesh.h"
+
+/*---------------------------------------------------------------------------*/
+
+BEGIN_C_DECLS
+
+/*============================================================================
+ * Local Macro definitions
+ *===========================================================================*/
+
+/*=============================================================================
+ * Global variables
+ *===========================================================================*/
+
+extern int  cs_glob_n_join_perio;   /* Number of periodicity defined through
+                                       a joining operation */
+
+/*============================================================================
+ *  Public function prototypes for Fortran API
+ *============================================================================*/
+
+/*----------------------------------------------------------------------------
+ * Get the number of periodic transformations already defined
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE NUMPER
+ * *****************
+ *
+ * INTEGER   numper      : --> : number of periodicities  op. already defined
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(numper, NUMPER)
+(
+ cs_int_t    *numper
+);
+
+/*----------------------------------------------------------------------------
+ * Define a translation
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE DEFPT1
+ * *****************
+ *
+ * INTEGER        numper    : <-- : number related to the periodic op.
+ * CHARACTER*     criteria  : <-- : boundary face selection criteria
+ * REAL           fraction  : <-- : parameter for merging vertices
+ * REAL           plane     : <-- : parameter for splitting faces
+ * INTEGER        verbosity : <-- : verbosity level
+ * REAL           tx        : <-- : X coordinate of the translation vector
+ * REAL           ty        : <-- : Y coordinate of the translation vector
+ * REAL           tz        : <-- : Z coordinate of the translation vector
+ * INTEGER        crit_len  : <-- : length of criteria
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(defpt1, DEFPT1)
+(
+ cs_int_t    *numper,
+ const char  *criteria,
+ cs_real_t   *fraction,
+ cs_real_t   *plane,
+ cs_int_t    *verbosity,
+ cs_real_t   *tx,
+ cs_real_t   *ty,
+ cs_real_t   *tz,
+ cs_int_t    *crit_len
+ CS_ARGF_SUPP_CHAINE
+);
+
+/*----------------------------------------------------------------------------
+ * Define a rotation
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE DEFPR1
+ * *****************
+ *
+ * INTEGER        numper    : <-- : number related to the periodic op.
+ * CHARACTER*     criteria : <-- : boundary face selection criteria
+ * REAL           fraction  : <-- : parameter for merging vertices
+ * REAL           plane     : <-- : parameter for splitting faces
+ * INTEGER        verbosity : <-- : verbosity level
+ * REAL           ax       : <-- : X coordinate of the rotation axis
+ * REAL           ay       : <-- : Y coordinate of the rotation axis
+ * REAL           az       : <-- : Z coordinate of the rotation axis
+ * REAL           theta    : <-- : angle of the rotation (radian)
+ * REAL           ix       : <-- : X coordinate of the invariant point
+ * REAL           iy       : <-- : Y coordinate of the invariant point
+ * REAL           iz       : <-- : Z coordinate of the invariant point
+ * INTEGER        crit_len : <-- : length of criteria string
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(defpr1, DEFPR1)
+(
+ cs_int_t    *numper,
+ const char  *criteria,
+ cs_real_t   *fraction,
+ cs_real_t   *plane,
+ cs_int_t    *verbosity,
+ cs_real_t   *ax,
+ cs_real_t   *ay,
+ cs_real_t   *az,
+ cs_real_t   *theta,
+ cs_real_t   *ix,
+ cs_real_t   *iy,
+ cs_real_t   *iz,
+ cs_int_t    *crit_len
+ CS_ARGF_SUPP_CHAINE
+);
+
+/*----------------------------------------------------------------------------
+ * Define a general transformation through a homogeneous matrix (4x4)
+ *     _               _
+ *    | r11 r12 r13 tx  |  t(x,y,z) : translation vector
+ *    | r21 r22 r23 ty  |  r(i,j)   : rotation matrix
+ *    | r31 r32 r33 tz  |
+ *    |_  0   0   0  1 _|
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE DEFPG1
+ * *****************
+ *
+ * INTEGER        numper    : <-- : number related to the periodic op.
+ * CHARACTER*     criteria  : <-- : boundary face selection criteria
+ * REAL           fraction  : <-- : parameter for merging vertices
+ * REAL           plane     : <-- : parameter for splitting faces
+ * INTEGER        verbosity : <-- : verbosity level
+ * REAL           r11       : <-- : coef. (1,1) of the homogeneous matrix
+ * REAL           r12       : <-- : coef. (1,2) of the homogeneous matrix
+ * REAL           r13       : <-- : coef. (1,3) of the homogeneous matrix
+ * REAL           tx        : <-- : coef. (1,4) of the homogeneous matrix
+ * REAL           r21       : <-- : coef. (2,1) of the homogeneous matrix
+ * REAL           r22       : <-- : coef. (2,2) of the homogeneous matrix
+ * REAL           r23       : <-- : coef. (2,3) of the homogeneous matrix
+ * REAL           ty        : <-- : coef. (2,4) of the homogeneous matrix
+ * REAL           r31       : <-- : coef. (3,1) of the homogeneous matrix
+ * REAL           r32       : <-- : coef. (3,2) of the homogeneous matrix
+ * REAL           r33       : <-- : coef. (3,3) of the homogeneous matrix
+ * REAL           tz        : <-- : coef. (3,4) of the homogeneous matrix
+ * INTEGER        crit_len  : <-- : length of criteria string
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(defpg1, DEFPG1)
+(
+ cs_int_t    *numper,
+ const char  *criteria,
+ cs_real_t   *fraction,
+ cs_real_t   *plane,
+ cs_int_t    *verbosity,
+ cs_real_t   *r11,
+ cs_real_t   *r12,
+ cs_real_t   *r13,
+ cs_real_t   *tx,
+ cs_real_t   *r21,
+ cs_real_t   *r22,
+ cs_real_t   *r23,
+ cs_real_t   *ty,
+ cs_real_t   *r31,
+ cs_real_t   *r32,
+ cs_real_t   *r33,
+ cs_real_t   *tz,
+ cs_int_t    *crit_len
+ CS_ARGF_SUPP_CHAINE
+);
+
+/*----------------------------------------------------------------------------
+ * Set advanced parameters for the joining algorithm in case of periodicity
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE SETAPP
+ * *****************
+ *
+ * INTEGER      perio_num         : <-- : perio number
+ * REAL         mtf               : <-- : merge tolerance coefficient
+ * REAL         pmf               : <-- : pre-merge factor
+ * INTEGER      tcm               : <-- : tolerance computation mode
+ * INTEGER      icm               : <-- : intersection computation mode
+ * INTEGER      maxbrk            : <-- : max number of equiv. breaks
+ * INTEGER      max_sub_faces     : <-- : max. possible number of sub-faces
+ *                                        by splitting a selected face
+ * INTEGER      tml               : <-- : tree max level
+ * INTEGER      tmb               : <-- : tree max boxes
+ * REAL         tmr               : <-- : tree max ratio
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(setapp, SETAPP)
+(
+ cs_int_t    *perio_num,
+ cs_real_t   *mtf,
+ cs_real_t   *pmf,
+ cs_int_t    *tcm,
+ cs_int_t    *icm,
+ cs_int_t    *maxbrk,
+ cs_int_t    *max_sub_faces,
+ cs_int_t    *tml,
+ cs_int_t    *tmb,
+ cs_real_t   *tmr
+);
+
+/*=============================================================================
+ * Public function prototypes
+ *===========================================================================*/
+
+/*----------------------------------------------------------------------------
+ * Define a translational periodicity
+ *
+ * parameters:
+ *   perio_num    <-- number related to the periodicity
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   verbosity    <-- level of verbosity required
+ *   trans        <-- translation vector
+ *----------------------------------------------------------------------------*/
+
+void
+cs_join_perio_add_translation(int            perio_num,
+                              const char    *sel_criteria,
+                              double         fraction,
+                              double         plane,
+                              int            verbosity,
+                              const double   trans[3]);
+
+/*----------------------------------------------------------------------------
+ * Define a rotational periodicity
+ *
+ * parameters:
+ *   perio_num    <-- number related to the periodicity
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   verbosity    <-- level of verbosity required
+ *   theta        <-- rotation angle (in degrees)
+ *   axis         <-- axis vector
+ *   invariant    <-- invariant point coordinates
+ *----------------------------------------------------------------------------*/
+
+void
+cs_join_perio_add_rotation(int            perio_num,
+                           const char    *sel_criteria,
+                           double         fraction,
+                           double         plane,
+                           int            verbosity,
+                           double         theta,
+                           const double   axis[3],
+                           const double   invariant[3]);
+
+/*----------------------------------------------------------------------------
+ * Define a periodicity using a matrix
+ *
+ * parameters:
+ *   perio_num    <-- number related to the periodicity
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   verbosity    <-- level of verbosity required
+ *   matrix       <-- transformation matrix
+ *----------------------------------------------------------------------------*/
+
+void
+cs_join_perio_add_mixed(int            perio_num,
+                        const char    *sel_criteria,
+                        double         fraction,
+                        double         plane,
+                        int            verbosity,
+                        double         matrix[3][4]);
+
+/*----------------------------------------------------------------------------
+ * Duplicate and apply transformation to the selected faces and also to
+ * their related vertices. Modify compact_face_gnum to take into account
+ * new periodic faces and create a periodic vertex couple list.
+ *
+ * parameters:
+ *   this_join    <--  high level join structure
+ *   jmesh        <->  local join mesh struct. to duplicate and transform
+ *   mesh         <--  pointer to a cs_mesh_t struct.
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_apply(cs_join_t          *this_join,
+                    cs_join_mesh_t     *jmesh,
+                    const cs_mesh_t    *mesh);
+
+/*----------------------------------------------------------------------------
+ * Duplicate and apply transformation to the selected faces and also to
+ * their related vertices. Modify compact_face_gnum to take into account
+ * new periodic faces and create a periodic vertex couple list.
+ *
+ * parameters:
+ *   this_join          <-- pointer to a high level join structure
+ *   jmesh              <-> local join mesh struct. to duplicate and transform
+ *   p_work_jmesh       <-> distributed join mesh struct. on which operations
+ *                          take place
+ *   p_work_edges       <-> join edges struct. related to work_jmesh
+ *   init_max_vtx_gnum  <-- initial max. global numbering for vertices
+ *   n_g_new_vertices   <-- global number of vertices created during the
+ *                          intersection of edges
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_merge_back(cs_join_t          *this_join,
+                         cs_join_mesh_t     *jmesh,
+                         cs_join_mesh_t    **p_work_jmesh,
+                         cs_join_edges_t   **p_work_edges,
+                         fvm_gnum_t          init_max_vtx_gnum,
+                         fvm_gnum_t          n_g_new_vertices);
+
+/*----------------------------------------------------------------------------
+ * Duplicate and apply transformation to the selected faces and also to
+ * their related vertices. Update jmesh structure.
+ * Define a new n2o_hist.
+ *
+ * parameters:
+ *   this_join     <-- pointer to a high level join structure
+ *   jmesh         <-> local join mesh struct. to duplicate and transform
+ *   mesh          <-- pointer to a cs_mesh_t structure
+ *   o2n_hist      <-- old global face -> new local face numbering
+ *   p_n2o_hist    <-- new global face -> old local face numbering
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_split_back(cs_join_t          *this_join,
+                         cs_join_mesh_t     *jmesh,
+                         cs_mesh_t          *mesh,
+                         cs_join_gset_t     *o2n_hist,
+                         cs_join_gset_t    **p_n2o_hist);
+
+/*----------------------------------------------------------------------------
+ * Define a list of coupled faces by periodicty in global numbering.
+ *
+ * For parallel runs:
+ *  - remove isolated periodic faces in the mesh definition
+ *  - define a consistent face connectivity in order to prepare the building
+ *    of periodic vertex couples
+ *
+ *
+ * parameters:
+ *   param        <-- set of parameters for the joining operation
+ *   n_ii_faces   <-- initial local number of interior faces
+ *   face_type    <-- type of faces in join mesh (interior or border ...)
+ *   jmesh        <-- pointer on a cs_join_mesh_t struct.
+ *   mesh         <-> pointer on a cs_mesh_t struct.
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_split_update(cs_join_param_t             param,
+                           cs_int_t                    n_ii_faces,
+                           const cs_join_face_type_t   face_type[],
+                           const cs_join_mesh_t       *jmesh,
+                           cs_mesh_t                  *mesh);
+
+/*----------------------------------------------------------------------------
+ * Use periodic face couples in cs_glob_join_perio_builder to define
+ * cs_glob_mesh_builder
+ * Free all elements which can be freed.
+ * Transfer data to cs_glob_mesh and cs_glob_mesh_builder.
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_transfer_builder(void);
+
+/*---------------------------------------------------------------------------*/
+
+END_C_DECLS
+
+#endif /* __CS_JOIN_PERIO_H__ */
diff --git a/include/base/cs_join_post.h b/include/base/cs_join_post.h
index 9f523d5..f7338b5 100644
--- a/include/base/cs_join_post.h
+++ b/include/base/cs_join_post.h
@@ -116,9 +116,7 @@ cs_join_post_after_merge(cs_join_param_t          join_param,
  *
  * parameters:
  *  n_old_i_faces   <--  initial number of interior faces
- *  n_new_i_faces   <--  number of interior faces added to the mesh definition
  *  n_old_b_faces   <--  initial number of border faces
- *  n_new_b_faces   <--  number of border faces added to the mesh definition
  *  n_g_new_b_faces <--  global number of new border faces
  *  n_select_faces  <--  number of selected faces
  *  mesh            <--  pointer to a cs_mesh_t structure
@@ -127,9 +125,7 @@ cs_join_post_after_merge(cs_join_param_t          join_param,
 
 void
 cs_join_post_after_split(cs_int_t          n_old_i_faces,
-                         cs_int_t          n_new_i_faces,
                          cs_int_t          n_old_b_faces,
-                         cs_int_t          n_new_b_faces,
                          fvm_gnum_t        n_g_new_b_faces,
                          cs_int_t          n_select_faces,
                          const cs_mesh_t  *mesh,
diff --git a/include/base/cs_join_set.h b/include/base/cs_join_set.h
index e6d9f89..da8c8e4 100644
--- a/include/base/cs_join_set.h
+++ b/include/base/cs_join_set.h
@@ -289,6 +289,8 @@ cs_join_gset_invert(const cs_join_gset_t  *set);
 /*----------------------------------------------------------------------------
  * Delete redudancies in a cs_join_gset_t structure.
  *
+ * The output set has an ordered sub-list for each element in the set.
+ *
  * parameters:
  *   set <-> pointer to the structure to clean
  *---------------------------------------------------------------------------*/
@@ -328,7 +330,10 @@ cs_join_gset_single_order(const cs_join_gset_t  *set,
 /*----------------------------------------------------------------------------
  * Compress a g_list such as for each element "e" in g_elts:
  *  - there is no redundancy for the linked elements of set->g_list
- *  - there is no element in set->g_list < e
+ *  - there is no element in set->g_list < e except if this element is not
+ *    present in g_elts
+ *
+ * g_list and g_elts need to be ordered before calling this function.
  *
  * parameters:
  *   set <-> pointer to the structure to work with
@@ -355,10 +360,44 @@ cs_join_gset_merge_elts(cs_join_gset_t  *set,
 
 /*----------------------------------------------------------------------------
  * Synchronize a cs_join_gset_t structure and distribute the resulting set
+ * over the rank thanks to a round-robin distribution. Elements in sync_set
+ * are ordered and there is no redundancy but list may have redundancies.
+ * Use cs_join_gset_clean() to remove redundancies in g_list.
+ *
+ * parameters:
+ *   loc_set  <-> pointer to the local structure to work with
+ *   comm     <-- mpi_comm on which synchro. and distribution take place
+ *
+ * returns:
+ *   a synchronized and distributed cs_join_gset_t structure.
+ *---------------------------------------------------------------------------*/
+
+cs_join_gset_t *
+cs_join_gset_robin_sync(cs_join_gset_t   *loc_set,
+                        MPI_Comm          comm);
+
+/*----------------------------------------------------------------------------
+ * Update a local cs_join_gset_t structure from a distributed and
+ * synchronized cs_join_gset_t structure. Round-robin distribution is used
+ * to store synchronized elements.
+ *
+ * parameters:
+ *   sync_set <-- pointer to the structure which holds a synchronized block
+ *   loc_set  <-> pointer to a local structure holding elements to update
+ *   comm     <-- comm on which synchronization and distribution take place
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_gset_robin_update(const cs_join_gset_t   *sync_set,
+                          cs_join_gset_t         *loc_set,
+                          MPI_Comm                comm);
+
+/*----------------------------------------------------------------------------
+ * Synchronize a cs_join_gset_t structure and distribute the resulting set
  * over the rank by block
  *
  * parameters:
- *   n_g_elts <-- global number of elements
+ *   max_gnum <-- max global number in global element numbering
  *   loc_set  <-> pointer to the local structure to work with
  *   comm     <-- mpi_comm on which synchro. and distribution take place
  *
@@ -367,26 +406,28 @@ cs_join_gset_merge_elts(cs_join_gset_t  *set,
  *---------------------------------------------------------------------------*/
 
 cs_join_gset_t *
-cs_join_gset_sync_by_block(fvm_gnum_t       n_g_elts,
-                           cs_join_gset_t  *loc_set,
-                           MPI_Comm         comm);
+cs_join_gset_block_sync(fvm_gnum_t       max_gnum,
+                        cs_join_gset_t  *loc_set,
+                        MPI_Comm         comm);
 
 /*----------------------------------------------------------------------------
  * Update a local cs_join_gset_t structure from a distributed and
  * synchronized cs_join_gset_t structure.
  *
+ * loc_set should not have redundant elements.
+ *
  * parameters:
- *   n_g_elts <-- global number of elements
+ *   max_gnum <-- max global number in global element numbering
  *   sync_set <-- pointer to the structure which holds a synchronized block
  *   loc_set  <-> pointer to a local structure holding elements to update
  *   comm     <-- comm on which synchronization and distribution take place
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_gset_update_from_block(fvm_gnum_t             n_g_elts,
-                               const cs_join_gset_t  *sync_set,
-                               cs_join_gset_t        *loc_set,
-                               MPI_Comm               comm);
+cs_join_gset_block_update(fvm_gnum_t             max_gnum,
+                          const cs_join_gset_t  *sync_set,
+                          cs_join_gset_t        *loc_set,
+                          MPI_Comm               comm);
 
 #endif /* HAVE_MPI */
 
diff --git a/include/base/cs_join_split.h b/include/base/cs_join_split.h
index 09bd409..6285565 100644
--- a/include/base/cs_join_split.h
+++ b/include/base/cs_join_split.h
@@ -78,6 +78,7 @@ cs_join_split_faces(cs_join_param_t          param,
  * Send back to the original rank the new face description.
  *
  * parameters:
+ *   param           <-- set of user-defined parameters
  *   work_mesh       <-- distributed mesh on faces to join
  *   gnum_rank_index <-- index on ranks for the old global face numbering
  *   o2n_hist        <-> old global face -> new local face numbering
@@ -85,7 +86,8 @@ cs_join_split_faces(cs_join_param_t          param,
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_split_update_struct(const cs_join_mesh_t   *work_mesh,
+cs_join_split_update_struct(const cs_join_param_t   param,
+                            const cs_join_mesh_t   *work_mesh,
                             const fvm_gnum_t        gnum_rank_index[],
                             cs_join_gset_t        **o2n_hist,
                             cs_join_mesh_t        **local_mesh);
diff --git a/include/base/cs_join_update.h b/include/base/cs_join_update.h
index 98d10f3..1bf7d4a 100644
--- a/include/base/cs_join_update.h
+++ b/include/base/cs_join_update.h
@@ -75,16 +75,16 @@ BEGIN_C_DECLS
  *   join_select  <--  list of all implied entities in the joining op.
  *   o2n_vtx_gnum <->  in : array on blocks on the new global vertex
  *                     out: local array on the new global vertex
- *   join_mesh    <--  pointer to the local cs_join_mesh_t structure
+ *   join_mesh    <->  pointer to the local cs_join_mesh_t structure
  *   mesh         <->  pointer of pointer to cs_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_update_mesh_after_merge(cs_join_param_t          join_param,
-                                const cs_join_select_t  *join_select,
-                                fvm_gnum_t               o2n_vtx_gnum[],
-                                cs_join_mesh_t          *join_mesh,
-                                cs_mesh_t               *mesh);
+cs_join_update_mesh_after_merge(cs_join_param_t    join_param,
+                                cs_join_select_t  *join_select,
+                                fvm_gnum_t         o2n_vtx_gnum[],
+                                cs_join_mesh_t    *join_mesh,
+                                cs_mesh_t         *mesh);
 
 /*----------------------------------------------------------------------------
  * Update mesh structure (vertices + faces) after the face split step.
@@ -93,7 +93,7 @@ cs_join_update_mesh_after_merge(cs_join_param_t          join_param,
  *   join_param      <-- set of parameters for the joining operation
  *   join_select     <-- list of all implied entities in the joining op.
  *   o2n_face_hist   <-- relation between faces before/after the joining
- *   join_mesh       <-- pointer to the local cs_join_mesh_t structure
+ *   join_mesh       <-> pointer to the local cs_join_mesh_t structure
  *   mesh            <-> pointer of pointer to cs_mesh_t structure
  *---------------------------------------------------------------------------*/
 
@@ -101,7 +101,7 @@ void
 cs_join_update_mesh_after_split(cs_join_param_t          join_param,
                                 const cs_join_select_t  *join_select,
                                 const cs_join_gset_t    *o2n_face_hist,
-                                const cs_join_mesh_t    *join_mesh,
+                                cs_join_mesh_t          *join_mesh,
                                 cs_mesh_t               *mesh);
 
 /*----------------------------------------------------------------------------
diff --git a/include/base/cs_join_util.h b/include/base/cs_join_util.h
index 370cb65..b25f484 100644
--- a/include/base/cs_join_util.h
+++ b/include/base/cs_join_util.h
@@ -70,6 +70,18 @@ typedef enum {
 
 } cs_join_type_t;
 
+typedef enum {
+
+  CS_JOIN_STATE_UNDEF,
+  CS_JOIN_STATE_NEW,
+  CS_JOIN_STATE_ORIGIN,
+  CS_JOIN_STATE_PERIO,
+  CS_JOIN_STATE_MERGE,
+  CS_JOIN_STATE_PERIO_MERGE,
+  CS_JOIN_STATE_SPLIT
+
+} cs_join_state_t;
+
 /*----------------------------------------------------------------------------
  * Set of user parameters to control the join operation
  *----------------------------------------------------------------------------*/
@@ -77,6 +89,7 @@ typedef enum {
 typedef struct {
 
   int  num;        /* number associated to the current join operation */
+  int  perio_num;  /* periodicity number associated to the joining op. */
 
   /* Octree - Quadtree search algorithm */
   /* ---------------------------------- */
@@ -99,7 +112,8 @@ typedef struct {
   /* maximum angle between normals of two faces considered to
      be in the same plane (for face split) */
 
-  float  plane;
+  float  plane; /* in degree */
+  double plane_criteria; /* cos(plane in rad)*cos(plane in rad) */
 
   /* Coef. used to modify the tolerance associated to each vertex before the
      merge operation.
@@ -151,7 +165,11 @@ typedef struct {
 
 } cs_join_param_t;
 
-typedef struct { /* Structure used to synchronize single elements */
+/*----------------------------------------------------------------------------
+ * Set of variables to synchronize single elements
+ *---------------------------------------------------------------------------*/
+
+typedef struct {
 
   int      n_elts;
   int      n_ranks;
@@ -168,6 +186,10 @@ typedef struct { /* Structure used to synchronize single elements */
 
 typedef struct {
 
+  cs_int_t      n_init_b_faces;  /* Number of border faces before joining */
+  cs_int_t      n_init_i_faces;  /* Number of interior faces before joining */
+  cs_int_t      n_init_vertices; /* Number of vertices before joining */
+
   cs_int_t      n_faces;     /* Number of border faces selected
                                 for the joining operation */
   fvm_gnum_t    n_g_faces;   /* Global number of border faces selected
@@ -179,13 +201,8 @@ typedef struct {
   fvm_gnum_t   *compact_rank_index;   /* Distribution of the selected faces
                                          over the ranks */
 
-  cs_int_t     *cell_filter;     /* Size: n_cells
-                                    value = -1 if not implied
-                                    value >= 0 else */
-
-  cs_real_t    *cell_cen;        /* Cell center for cells implied */
   fvm_gnum_t   *cell_gnum;       /* Global cell numbering of the cells
-                                         holding the selected face */
+                                    bearing the selected face */
 
   cs_int_t      n_vertices;      /* Number of vertices selected
                                     for the joining operation */
@@ -200,6 +217,16 @@ typedef struct {
   cs_int_t     *b_adj_faces;
   cs_int_t     *i_adj_faces;
 
+  /* Keep the status of all faces of the related cs_mesh_t */
+
+  cs_join_state_t   *b_face_state;
+  cs_join_state_t   *i_face_state;
+
+  /* For periodicity handling: list of periodic vertex couples */
+
+  cs_int_t     n_couples;
+  fvm_gnum_t  *per_v_couples;
+
   /*
      Single elements (Only possible in parallel). It appears
      when the domain splitting has a poor quality and elements
@@ -217,6 +244,23 @@ typedef struct {
 } cs_join_select_t;
 
 /*----------------------------------------------------------------------------
+ * Highest level structure to manage the joining algorithm
+ *---------------------------------------------------------------------------*/
+
+typedef struct {
+
+  cs_join_param_t   param;       /* Set of parameters used to control
+                                    the joining operations */
+
+  cs_join_select_t  *selection;  /* Store entities implied in the joining
+                                    operation */
+
+  char              *criteria;   /* Criteria used to select border faces
+                                    implied in the joining operation */
+
+} cs_join_t;
+
+/*----------------------------------------------------------------------------
  * Structure used to store information about a block distribution
  *---------------------------------------------------------------------------*/
 
@@ -236,47 +280,78 @@ typedef struct {
 
 } cs_join_block_info_t;
 
+/*=============================================================================
+ * Global variables
+ *===========================================================================*/
+
+extern int  cs_glob_join_count;
+extern int  cs_glob_n_joinings;
+extern cs_join_t  **cs_glob_join_array;
+
 /*============================================================================
  * Public function definitions
  *===========================================================================*/
 
 /*----------------------------------------------------------------------------
- * Define a set of parameters to control a contiguous distribution by block.
+ * Create and initialize a cs_join_t structure.
  *
  * parameters:
- *   n_g_elts   <-- global number of elements to treat
- *   n_ranks    <-- number of ranks in the MPI communicator related to the
- *                  cs_join_block_info_t structure to create
- *   local_rank <-- rank in the MPI communicator related to the
- *                  cs_join_block_info_t structure to create
+ *   join_number  <-- number related to the joining operation
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- edge fraction tolerance parameter
+ *   plane        <-- plane normal angle tolerance
+ *   perio_num    <-- periodicity number (0 if not a periodic joining)
+ *   verbosity    <-- verbosity level
  *
  * returns:
- *   a new defined cs_join_block_info_t structure
+ *   pointer to a newly allocated cs_join_t structure
  *---------------------------------------------------------------------------*/
 
-cs_join_block_info_t
-cs_join_get_block_info(fvm_gnum_t  n_g_elts,
-                       int         n_ranks,
-                       int         local_rank);
+cs_join_t *
+cs_join_create(int          join_number,
+               const char  *sel_criteria,
+               float        fraction,
+               float        plane,
+               int          perio_num,
+               int          verbosity);
 
 /*----------------------------------------------------------------------------
- * Initialize a cs_join_param_t structure.
+ * Destroy a cs_join_t structure.
  *
  * parameters:
- *   join_num      <-- num of the current joining operation
- *   fraction      <-- value of the fraction parameter
- *   plane         <-- value of the plane parameter
- *   verbosity     <-- level of verbosity required
+ *  join <-> pointer to the cs_join_t structure to destroy
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_destroy(cs_join_t  **join);
+
+/*----------------------------------------------------------------------------
+ * Set advanced parameters to user-defined values.
  *
- * returns:
- *   a pointer to a cs_join_param_t structure
+ * parameters:
+ *   join           <-> pointer a to cs_join_t struct. to update
+ *   mtf            <-- merge tolerance coefficient
+ *   pmf            <-- pre-merge factor
+ *   tcm            <-- tolerance computation mode
+ *   icm            <-- intersection computation mode
+ *   maxbrk         <-- max number of equivalences to break (merge step)
+ *   max_sub_faces  <-- max. possible number of sub-faces by splitting a face
+ *   tml            <-- tree max level
+ *   tmb            <-- tree max boxes
+ *   tmr            <-- tree max ratio
  *---------------------------------------------------------------------------*/
 
-cs_join_param_t
-cs_join_param_define(int      join_num,
-                     float    fraction,
-                     float    plane,
-                     int      verbosity);
+void
+cs_join_set_advanced_param(cs_join_t   *join,
+                           cs_real_t    mtf,
+                           cs_real_t    pmf,
+                           cs_int_t     tcm,
+                           cs_int_t     icm,
+                           cs_int_t     maxbrk,
+                           cs_int_t     max_sub_faces,
+                           cs_int_t     tml,
+                           cs_int_t     tmb,
+                           cs_real_t    tmr);
 
 /*----------------------------------------------------------------------------
  * Create and initialize a cs_join_select_t structure.
@@ -294,14 +369,62 @@ cs_join_select_create(const char  *selection_criteria,
                       int          verbosity);
 
 /*----------------------------------------------------------------------------
- * Destroy a cs_join_select_t structure.
+ * Define a set of parameters to control a contiguous distribution by block.
+ *
+ * parameters:
+ *   n_g_elts   <-- global number of elements to treat
+ *   n_ranks    <-- number of ranks in the MPI communicator related to the
+ *                  cs_join_block_info_t structure to create
+ *   local_rank <-- rank in the MPI communicator related to the
+ *                  cs_join_block_info_t structure to create
+ *
+ * returns:
+ *   a newly defined cs_join_block_info_t structure
+ *---------------------------------------------------------------------------*/
+
+cs_join_block_info_t
+cs_join_get_block_info(fvm_gnum_t  n_g_elts,
+                       int         n_ranks,
+                       int         local_rank);
+
+/*----------------------------------------------------------------------------
+ * Extract vertices from a selection of faces.
+ *
+ * parameters:
+ *   n_select_faces <-- number of selected faces
+ *   select_faces   <-- list of faces selected
+ *   f2v_idx        <-- "face -> vertex" connect. index
+ *   f2v_lst        <-- "face -> vertex" connect. list
+ *   n_vertices     <-- number of vertices
+ *   n_sel_vertices <-> pointer to the number of selected vertices
+ *   sel_vertices   <-> pointer to the list of selected vertices
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_extract_vertices(cs_int_t         n_select_faces,
+                         const cs_int_t  *select_faces,
+                         const cs_int_t  *f2v_idx,
+                         const cs_int_t  *f2v_lst,
+                         cs_int_t         n_vertices,
+                         cs_int_t        *n_select_vertices,
+                         cs_int_t        *select_vertices[]);
+
+/*----------------------------------------------------------------------------
+ * Eliminate redundancies found between two lists of elements.
+ * Delete elements in elts[] and keep elements in the reference list.
  *
  * parameters:
- *   join_select <-- pointer to pointer to structure to destroy
+ *  n_elts     <-> number of elements in the list to clean
+ *  elts       <-> list of elements in the list to clean
+ *  n_ref_elts <-- number of elements in the reference list
+ *  ref_elts   <-- list of reference elements
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_select_destroy(cs_join_select_t  **join_select);
+cs_join_clean_selection(cs_int_t  *n_elts,
+                        cs_int_t  *elts[],
+                        cs_int_t   n_ref_elts,
+                        cs_int_t   ref_elts[]);
 
 /*----------------------------------------------------------------------------
  * Build vertex -> vertex index for a selection of faces.
diff --git a/include/base/cs_mesh.h b/include/base/cs_mesh.h
index f875a7d..4784d8b 100644
--- a/include/base/cs_mesh.h
+++ b/include/base/cs_mesh.h
@@ -39,6 +39,7 @@
 #include <fvm_defs.h>
 #include <fvm_group.h>
 #include <fvm_selector.h>
+#include <fvm_interface.h>
 #include <fvm_periodicity.h>
 
 /*----------------------------------------------------------------------------
@@ -185,6 +186,11 @@ typedef struct {
                                   we have the distant rank number. Exist
                                   only in case of parallelism. */
 
+  fvm_interface_set_t   *face_ifs;  /* Build while reading the
+                                       preprocessor_data or while joining
+                                       periodic faces in parallel.
+                                       Otherwise NULL */
+
 } cs_mesh_builder_t ;
 
 /*============================================================================
diff --git a/include/base/cs_prototypes.h b/include/base/cs_prototypes.h
index 88a2433..5aa3435 100644
--- a/include/base/cs_prototypes.h
+++ b/include/base/cs_prototypes.h
@@ -540,6 +540,12 @@ extern void CS_PROCF (usmodg, USMODG)
 );
 
 /*----------------------------------------------------------------------------
+ * User function for mesh periodicity definition
+ *----------------------------------------------------------------------------*/
+
+extern void CS_PROCF (usperi, USPERI) (void);
+
+/*----------------------------------------------------------------------------
  * User function for modification of a post-processing mesh
  *----------------------------------------------------------------------------*/
 
diff --git a/libsyrcs/Makefile.in b/libsyrcs/Makefile.in
index fb4960e..9f61759 100644
--- a/libsyrcs/Makefile.in
+++ b/libsyrcs/Makefile.in
@@ -73,9 +73,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -109,7 +114,10 @@ libsyrcs_la_DEPENDENCIES =
 am_libsyrcs_la_OBJECTS = syr_comm.lo syr_coupling.lo syr_cs.lo \
 	syr_defs.lo
 libsyrcs_la_OBJECTS = $(am_libsyrcs_la_OBJECTS)
-libsyrcs_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libsyrcs_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
 	$(libsyrcs_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
@@ -118,13 +126,26 @@ am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_$(V))
+am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
+am__v_CC_0 = @echo "  CC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_$(V))
+am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_CCLD_0 = @echo "  CCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libsyrcs_la_SOURCES)
 DIST_SOURCES = $(libsyrcs_la_SOURCES)
 ETAGS = etags
@@ -132,6 +153,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -155,6 +177,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -206,6 +229,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -262,6 +286,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -299,7 +324,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -408,7 +432,7 @@ clean-libLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libsyrcs.la: $(libsyrcs_la_OBJECTS) $(libsyrcs_la_DEPENDENCIES) 
-	$(libsyrcs_la_LINK) -rpath $(libdir) $(libsyrcs_la_OBJECTS) $(libsyrcs_la_LIBADD) $(LIBS)
+	$(AM_V_CCLD)$(libsyrcs_la_LINK) -rpath $(libdir) $(libsyrcs_la_OBJECTS) $(libsyrcs_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -422,22 +446,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/syr_defs.Plo at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
diff --git a/patches/README b/patches/README
index 2eb4088..3e93f8c 100644
--- a/patches/README
+++ b/patches/README
@@ -5,3 +5,11 @@ This directory contains files fixing potential problems that could arise
 in some particular situations. These patches have not been fully validated
 and therefore are NOT SUPPORTED.
 
+* Problem of consistency between two runs with different number of processors
+  ---------------------------------------------------------------------------
+Due to the way the code rescale the pressure at the outlet (in the standard
+formulation), there can be some differences between two runs with different
+number of processors. This is caused by the face number chosen by the code to
+rescale the pressure profile.
+
+patch: typecl.90
diff --git a/patches/typecl.f90 b/patches/typecl.f90
new file mode 100644
index 0000000..e528d85
--- /dev/null
+++ b/patches/typecl.f90
@@ -0,0 +1,1990 @@
+!-------------------------------------------------------------------------------
+
+!     This file is part of the Code_Saturne Kernel, element of the
+!     Code_Saturne CFD tool.
+
+!     Copyright (C) 1998-2009 EDF S.A., France
+
+!     contact: saturne-support at edf.fr
+
+!     The Code_Saturne Kernel is free software; you can redistribute it
+!     and/or modify it under the terms of the GNU General Public License
+!     as published by the Free Software Foundation; either version 2 of
+!     the License, or (at your option) any later version.
+
+!     The Code_Saturne Kernel 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 General Public License for more details.
+
+!     You should have received a copy of the GNU General Public License
+!     along with the Code_Saturne Kernel; if not, write to the
+!     Free Software Foundation, Inc.,
+!     51 Franklin St, Fifth Floor,
+!     Boston, MA  02110-1301  USA
+
+!-------------------------------------------------------------------------------
+
+subroutine typecl &
+!================
+
+ ( idbia0 , idbra0 ,                                              &
+   ndim   , ncelet , ncel   , nfac   , nfabor , nfml   , nprfml , &
+   nnod   , lndfac , lndfbr , ncelbr ,                            &
+   nvar   , nscal  , nphas  ,                                     &
+   nideve , nrdeve , nituse , nrtuse ,                            &
+   ifacel , ifabor , ifmfbr , ifmcel , iprfml ,                   &
+   ipnfac , nodfac , ipnfbr , nodfbr ,                            &
+   itypfb , itrifb , icodcl , isostd ,                            &
+   idevel , ituser , ia     ,                                     &
+   xyzcen , surfac , surfbo , cdgfac , cdgfbo , xyznod , volume , &
+   dt     , rtp    , rtpa   , propce , propfa , propfb ,          &
+   coefa  , coefb  , rcodcl , frcxt  ,                            &
+   w1     , w2     , w3     , w4     , w5     , w6     , coefu  , &
+   rdevel , rtuser , ra     )
+
+!===============================================================================
+! Function :
+! --------
+
+! Handle boundary condition type code (itypfb)
+
+!-------------------------------------------------------------------------------
+! Arguments
+!__________________.____._____.________________________________________________.
+! name             !type!mode ! role                                           !
+!__________________!____!_____!________________________________________________!
+! idbia0           ! i  ! <-- ! number of first free position in ia            !
+! idbra0           ! i  ! <-- ! number of first free position in ra            !
+! ndim             ! i  ! <-- ! spatial dimension                              !
+! ncelet           ! i  ! <-- ! number of extended (real + ghost) cells        !
+! ncel             ! i  ! <-- ! number of cells                                !
+! nfac             ! i  ! <-- ! number of interior faces                       !
+! nfabor           ! i  ! <-- ! number of boundary faces                       !
+! nfml             ! i  ! <-- ! number of families (group classes)             !
+! nprfml           ! i  ! <-- ! number of properties per family (group class)  !
+! nnod             ! i  ! <-- ! number of vertices                             !
+! lndfac           ! i  ! <-- ! size of nodfac indexed array                   !
+! lndfbr           ! i  ! <-- ! size of nodfbr indexed array                   !
+! ncelbr           ! i  ! <-- ! number of cells with faces on boundary         !
+! nvar             ! i  ! <-- ! total number of variables                      !
+! nscal            ! i  ! <-- ! total number of scalars                        !
+! nphas            ! i  ! <-- ! number of phases                               !
+! nideve, nrdeve   ! i  ! <-- ! sizes of idevel and rdevel arrays              !
+! nituse, nrtuse   ! i  ! <-- ! sizes of ituser and rtuser arrays              !
+! ifacel(2, nfac)  ! ia ! <-- ! interior faces -> cells connectivity           !
+! ifabor(nfabor)   ! ia ! <-- ! boundary faces -> cells connectivity           !
+! ifmfbr(nfabor)   ! ia ! <-- ! boundary face family numbers                   !
+! ifmcel(ncelet)   ! ia ! <-- ! cell family numbers                            !
+! iprfml           ! ia ! <-- ! property numbers per family                    !
+!  (nfml, nprfml)  !    !     !                                                !
+! ipnfac(nfac+1)   ! ia ! <-- ! interior faces -> vertices index (optional)    !
+! nodfac(lndfac)   ! ia ! <-- ! interior faces -> vertices list (optional)     !
+! ipnfbr(nfabor+1) ! ia ! <-- ! boundary faces -> vertices index (optional)    !
+! nodfbr(lndfbr)   ! ia ! <-- ! boundary faces -> vertices list (optional)     !
+! itypfb           ! ia ! <-- ! boundary face types                            !
+!  (nfabor, nphas) !    !     !                                                !
+! itrifb(nfabor    ! te ! --> ! tab d'indirection pour tri des faces           !
+!  nphas)          !    !     !                                                !
+! icodcl           ! te ! <-- ! code de condition limites aux faces            !
+!  (nfabor,nvar    !    !     !  de bord                                       !
+!                  !    !     ! = 1   -> dirichlet                             !
+!                  !    !     ! = 3   -> densite de flux                       !
+!                  !    !     ! = 4   -> glissemt et u.n=0 (vitesse)           !
+!                  !    !     ! = 5   -> frottemt et u.n=0 (vitesse)           !
+!                  !    !     ! = 6   -> rugosite et u.n=0 (vitesse)           !
+!                  !    !     ! = 9   -> entree/sortie libre (vitesse          !
+!                  !    !     !  entrante eventuelle     bloquee               !
+! isostd           ! te ! --> ! indicateur de sortie standard                  !
+!    (nfabor+1)    !    !     !  +numero de la face de reference               !
+! idevel(nideve)   ! ia ! <-> ! integer work array for temporary development   !
+! ituser(nituse)   ! ia ! <-> ! user-reserved integer work array               !
+! ia(*)            ! ia ! --- ! main integer work array                        !
+! xyzcen           ! ra ! <-- ! cell centers                                   !
+!  (ndim, ncelet)  !    !     !                                                !
+! surfac           ! ra ! <-- ! interior faces surface vectors                 !
+!  (ndim, nfac)    !    !     !                                                !
+! surfbo           ! ra ! <-- ! boundary faces surface vectors                 !
+!  (ndim, nfabor)  !    !     !                                                !
+! cdgfac           ! ra ! <-- ! interior faces centers of gravity              !
+!  (ndim, nfac)    !    !     !                                                !
+! cdgfbo           ! ra ! <-- ! boundary faces centers of gravity              !
+!  (ndim, nfabor)  !    !     !                                                !
+! xyznod           ! ra ! <-- ! vertex coordinates (optional)                  !
+!  (ndim, nnod)    !    !     !                                                !
+! volume(ncelet)   ! ra ! <-- ! cell volumes                                   !
+! dt(ncelet)       ! ra ! <-- ! time step (per cell)                           !
+! rtp, rtpa        ! ra ! <-- ! calculated variables at cell centers           !
+!  (ncelet, *)     !    !     !  (at current and previous time steps)          !
+! propce(ncelet, *)! ra ! <-- ! physical properties at cell centers            !
+! propfa(nfac, *)  ! ra ! <-- ! physical properties at interior face centers   !
+! propfb(nfabor, *)! ra ! <-- ! physical properties at boundary face centers   !
+! coefa, coefb     ! ra ! <-- ! boundary conditions                            !
+!  (nfabor, *)     !    !     !                                                !
+! rcodcl           ! tr ! --> ! valeur des conditions aux limites              !
+!  (nfabor,nvar    !    !     !  aux faces de bord                             !
+!                  !    !     ! rcodcl(1) = valeur du dirichlet                !
+!                  !    !     ! rcodcl(2) = valeur du coef. d'echange          !
+!                  !    !     !  ext. (infinie si pas d'echange)               !
+!                  !    !     ! rcodcl(3) = valeur de la densite de            !
+!                  !    !     !  flux (negatif si gain) w/m2 ou                !
+!                  !    !     !  hauteur de rugosite (m) si icodcl=6           !
+!                  !    !     ! pour les vitesses (vistl+visct)*gradu          !
+!                  !    !     ! pour la pression             dt*gradp          !
+!                  !    !     ! pour les scalaires                             !
+!                  !    !     !        cp*(viscls+visct/sigmas)*gradt          !
+! frcxt(ncelet,    ! tr ! <-- ! force exterieure generant la pression          !
+!   3,nphas)       !    !     !  hydrostatique                                 !
+! w1,2,3,4,5,6     ! ra ! --- ! work arrays                                    !
+!  (ncelet)        !    !     !  (computation of pressure gradient)            !
+! rijipb           ! tr ! --- ! tab de trav pour valeurs en iprime             !
+! (nfabor,6   )    !    !     !  des rij au bord                               !
+! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
+! rtuser(nrtuse)   ! ra ! <-> ! user-reserved real work array                  !
+! ra(*)            ! ra ! --- ! main real work array                           !
+!__________________!____!_____!________________________________________________!
+
+!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
+!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
+!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
+!            --- tableau de travail
+!===============================================================================
+
+implicit none
+
+!===============================================================================
+! Fortran common blocks
+!===============================================================================
+
+include "dimfbr.h"
+include "paramx.h"
+include "numvar.h"
+include "optcal.h"
+include "cstnum.h"
+include "cstphy.h"
+include "entsor.h"
+include "pointe.h"
+include "parall.h"
+include "ppppar.h"
+include "ppthch.h"
+include "ppincl.h"
+include "cplsat.h"
+
+!===============================================================================
+
+! Arguments
+
+integer          idbia0 , idbra0
+integer          ndim   , ncelet , ncel   , nfac   , nfabor
+integer          nfml   , nprfml
+integer          nnod   , lndfac , lndfbr , ncelbr
+integer          nvar   , nscal  , nphas
+integer          nideve , nrdeve , nituse , nrtuse
+
+integer          ifacel(2,nfac) , ifabor(nfabor)
+integer          ifmfbr(nfabor) , ifmcel(ncelet)
+integer          iprfml(nfml,nprfml)
+integer          ipnfac(nfac+1), nodfac(lndfac)
+integer          ipnfbr(nfabor+1), nodfbr(lndfbr)
+integer          icodcl(nfabor,nvar)
+integer          itypfb(nfabor,nphas) , itrifb(nfabor,nphas)
+integer          isostd(nfabor+1,nphas)
+integer          idevel(nideve), ituser(nituse)
+integer          ia(*)
+
+double precision xyzcen(ndim,ncelet)
+double precision surfac(ndim,nfac), surfbo(ndim,nfabor)
+double precision cdgfac(ndim,nfac), cdgfbo(ndim,nfabor)
+double precision xyznod(ndim,nnod), volume(ncelet)
+double precision dt(ncelet), rtp(ncelet,*), rtpa(ncelet,*)
+double precision propce(ncelet,*)
+double precision propfa(nfac,*), propfb(ndimfb,*)
+double precision coefa(ndimfb,*), coefb(ndimfb,*)
+double precision rcodcl(nfabor,nvar,3)
+double precision frcxt(ncelet,3,nphas)
+double precision w1(ncelet),w2(ncelet),w3(ncelet)
+double precision w4(ncelet),w5(ncelet),w6(ncelet)
+double precision coefu(nfabor,3)
+double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
+
+! Local variables
+
+character        chaine*80
+integer          idebia, idebra
+integer          ifac, ivar, iel
+integer          iok, inc, iccocg, ideb, ifin, inb, isum, iwrnp
+integer          ifrslb(nphsmx), itbslb(nphsmx)
+integer          ityp, ii, jj, iphas, iwaru, iflmab
+integer          nswrgp, imligp, iwarnp
+integer          ipriph, iuiph, iviph, iwiph
+integer          ir11ip, ir22ip, ir33ip, ir12ip, ir13ip,ir23ip
+integer          ikiph , iepiph, iphiph, ifbiph, iomgip
+integer          iprnew, kphas, iii
+integer          irangd, iclipr, iiptot
+integer          ifadir, nfadir
+double precision pref, epsrgp, climgp, extrap, coefup
+double precision diipbx, diipby, diipbz
+double precision flumbf, flumty(ntypmx)
+double precision ro0iph, p0iph, pr0iph, xxp0, xyp0, xzp0, d0, d0min
+double precision xyzref(4) ! xyzref(3) + coefup for broadcast
+
+integer          ipass
+data             ipass /0/
+save             ipass
+
+
+!===============================================================================
+
+!===============================================================================
+! 1.  Initialization
+!===============================================================================
+
+idebia = idbia0
+idebra = idbra0
+
+!===============================================================================
+! 2.  Check consistency of types given in usclim
+!===============================================================================
+
+iok = 0
+
+do iphas = 1, nphas
+  do ifac = 1, nfabor
+    ityp = itypfb(ifac,iphas)
+    if(ityp.le.0.or.ityp.gt.ntypmx) then
+      itypfb(ifac,iphas) = 0
+      iok = iok + 1
+    endif
+  enddo
+enddo
+
+if (irangp.ge.0) call parcmx(iok)
+if(iok.ne.0) then
+  call bcderr(nphas, itypfb)
+endif
+
+!===============================================================================
+! 3.  Sort boundary faces
+!===============================================================================
+
+
+! Count faces of each type (temporarily in ifinty)
+
+do iphas = 1, nphas
+  do ii = 1, ntypmx
+   ifinty(ii,iphas) = 0
+ enddo
+enddo
+
+do iphas = 1, nphas
+  do ifac = 1, nfabor
+    ityp = itypfb(ifac,iphas)
+    ifinty(ityp,iphas) = ifinty(ityp,iphas) + 1
+  enddo
+enddo
+
+
+! Set start of each group of faces in itrifb (sorted by type): idebty
+
+do iphas = 1, nphas
+  do ii = 1, ntypmx
+    idebty(ii,iphas) = 1
+  enddo
+enddo
+
+do iphas = 1, nphas
+  do ii = 1, ntypmx-1
+    do jj = ii+1, ntypmx
+      idebty(jj,iphas) = idebty(jj,iphas) + ifinty(ii,iphas)
+    enddo
+  enddo
+enddo
+
+! Sort faces in itrifb and use the opportunity to correctly set ifinty
+
+do iphas = 1, nphas
+  do ii = 1, ntypmx
+    ifinty(ii,iphas) = idebty(ii,iphas)-1
+  enddo
+enddo
+
+do iphas = 1, nphas
+  do ifac = 1, nfabor
+    ityp = itypfb(ifac,iphas)
+    ifin = ifinty(ityp,iphas)+1
+    itrifb(ifin,iphas) = ifac
+    ifinty(ityp,iphas) = ifin
+  enddo
+enddo
+
+! Basic check
+
+iok = 0
+do iphas = 1, nphas
+  do ii = 1, ntypmx-1
+    if(ifinty(ii,iphas).ge.idebty(ii+1,iphas)) then
+      if (iok.eq.0) iok = ii
+    endif
+  enddo
+  if (irangp.ge.0) call parcmx(iok)
+  if (iok.gt.0) then
+    ii = iok
+    write(nfecra,2010) iphas
+    if(ifinty(ii,iphas).ge.idebty(ii+1,iphas)) then
+      write(nfecra,2020) (ifinty(jj,iphas),jj=1,ntypmx)
+      write(nfecra,2030) (idebty(jj,iphas),jj=1,ntypmx)
+      write(nfecra,2040) (itypfb(jj,iphas),jj=1,nfabor)
+      write(nfecra,2098) ii,ifinty(ii,iphas),ii+1,idebty(ii+1,iphas)
+    else
+      write(nfecra,2099) ii,ii+1
+    endif
+    call csexit (1)
+  endif
+enddo
+
+iok = 0
+do iphas = 1, nphas
+  isum = 0
+  do ii = 1, ntypmx
+    isum = isum + ifinty(ii,iphas) - idebty(ii,iphas) + 1
+  enddo
+  if (irangp.ge.0) call parcpt (isum)
+  if(isum.ne.nfbrgb) then
+    write(nfecra,3099) iphas, isum, nfbrgb
+    iok = iok + 1
+  endif
+enddo
+if (iok.ne.0) then
+  call csexit (1)
+  !==========
+endif
+
+
+! ---> On ecrit les types de faces avec la borne inf et sup et le nb
+!       pour chaque type de face trouve (tjrs pour les types par defaut)
+
+if(ipass.eq.0.or.iwarni(iu(1)).ge.2) then
+
+  ipass = 1
+
+  write(nfecra,6010)
+
+  do iphas = 1, nphas
+
+    write(nfecra,6011)iphas
+
+    if ( ippmod(icompf).lt.0 ) then
+
+      ii = ientre
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Entree           ', ii, inb
+#else
+      write(nfecra,6020) 'Inlet            ', ii, inb
+#endif
+      ii = iparoi
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Paroi lisse      ', ii, inb
+#else
+      write(nfecra,6020) 'Smooth wall      ', ii, inb
+#endif
+      ii = iparug
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Paroi rugueuse   ', ii, inb
+#else
+      write(nfecra,6020) 'Rough wall       ', ii, inb
+#endif
+      ii = isymet
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Symetrie         ', ii, inb
+#else
+      write(nfecra,6020) 'Symmetry         ', ii, inb
+#endif
+      ii = isolib
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Sortie libre     ', ii, inb
+#else
+      write(nfecra,6020) 'Free outlet      ', ii, inb
+#endif
+
+      if (nbrcpl.ge.1) then
+        ii = icscpl
+        inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+        if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+        write(nfecra,6020) 'Couplage sat/sat ', ii, inb
+#else
+        write(nfecra,6020) 'Sat/Sat coupling ', ii, inb
+#endif
+      endif
+
+      ii = iindef
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Indefini         ', ii, inb
+#else
+      write(nfecra,6020) 'Undefined        ', ii, inb
+#endif
+
+      do ii = 1, ntypmx
+        if (ii.ne.ientre .and. &
+            ii.ne.iparoi .and. &
+            ii.ne.iparug .and. &
+            ii.ne.isymet .and. &
+            ii.ne.isolib .and. &
+            ii.ne.icscpl .and. &
+            ii.ne.iindef ) then
+          inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+          if (irangp.ge.0) call parcpt (inb)
+          if(inb.gt.0) then
+#if defined(_CS_LANG_FR)
+            write(nfecra,6020) 'Type utilisateur ', ii, inb
+#else
+            write(nfecra,6020) 'User type        ', ii, inb
+#endif
+          endif
+        endif
+      enddo
+
+    else
+
+      ii = ieqhcf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Entree sub. enth.', ii, inb
+#else
+      write(nfecra,6020) 'Sub. enth. inlet ', ii, inb
+#endif
+
+      ii = ierucf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Entree subsonique', ii, inb
+#else
+      write(nfecra,6020) 'Subsonic inlet   ', ii, inb
+#endif
+
+      ii = iesicf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Entree/Sortie imp', ii, inb
+#else
+      write(nfecra,6020) 'Imp inlet/outlet ', ii, inb
+#endif
+
+      ii = isopcf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Sortie subsonique', ii, inb
+#else
+      write(nfecra,6020) 'Subsonic outlet  ', ii, inb
+#endif
+
+      ii = isspcf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Sortie supersoniq', ii, inb
+#else
+      write(nfecra,6020) 'Supersonic outlet', ii, inb
+#endif
+
+      ii = iparoi
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Paroi lisse      ', ii, inb
+#else
+      write(nfecra,6020) 'Smooth wall      ', ii, inb
+#endif
+
+      ii = iparug
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Paroi rugueuse   ', ii, inb
+#else
+      write(nfecra,6020) 'Rough wall       ', ii, inb
+#endif
+
+      ii = isymet
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Symetrie         ', ii, inb
+#else
+      write(nfecra,6020) 'Symmetry         ', ii, inb
+#endif
+
+      ii = iindef
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) call parcpt (inb)
+#if defined(_CS_LANG_FR)
+      write(nfecra,6020) 'Indefini         ', ii, inb
+#else
+      write(nfecra,6020) 'Undefined        ', ii, inb
+#endif
+
+      do ii = 1, ntypmx
+        if (ii.ne.iesicf .and. &
+            ii.ne.isspcf .and. &
+            ii.ne.ieqhcf .and. &
+            ii.ne.ierucf .and. &
+            ii.ne.isopcf .and. &
+            ii.ne.iparoi .and. &
+            ii.ne.iparug .and. &
+            ii.ne.isymet .and. &
+            ii.ne.iindef ) then
+          inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+          if (irangp.ge.0) call parcpt (inb)
+          if(inb.gt.0) then
+#if defined(_CS_LANG_FR)
+            write(nfecra,6020) 'Type utilisateur ',ii, inb
+#else
+            write(nfecra,6020) 'User type        ',ii, inb
+#endif
+          endif
+        endif
+      enddo
+
+    endif
+
+    write(nfecra,6030)
+
+  enddo
+
+endif
+
+!================================================================================
+! 4.  rcodcl(.,    .,1) has been initialized as rinfin so as to check what
+!     the user has modified. Those not modified are reset to zero here.
+!     isolib and ientre are handled later.
+!================================================================================
+
+do iphas = 1, nphas
+  do ivar=1, nvar
+     do ifac = 1, nfabor
+        if((itypfb(ifac,iphas) .ne. isolib) .and. &
+           (itypfb(ifac,iphas) .ne. ientre) .and. &
+           (rcodcl(ifac,ivar,1) .gt. rinfin*0.5d0)) then
+           rcodcl(ifac,ivar,1) = 0.d0
+       endif
+      enddo
+   enddo
+enddo
+
+
+!===============================================================================
+! 5.  Compute pressure at boundary (in coefu(*,1))
+!     (if we need it, that is if there are outlet boudary faces).
+
+!     The loop on phases starts here and ends at the end of the next block.
+!===============================================================================
+
+! --- Boucle sur les phases : debut
+do iphas = 1, nphas
+
+  ro0iph = ro0  (iphas)
+  p0iph  = p0   (iphas)
+  pr0iph = pred0(iphas)
+  xxp0   = xyzp0(1,iphas)
+  xyp0   = xyzp0(2,iphas)
+  xzp0   = xyzp0(3,iphas)
+  ipriph = ipr (iphas)
+  iuiph  = iu  (iphas)
+  iviph  = iv  (iphas)
+  iwiph  = iw  (iphas)
+  if(itytur(iphas).eq.2) then
+    ikiph  = ik(iphas)
+    iepiph = iep(iphas)
+  elseif(itytur(iphas).eq.3) then
+    ir11ip = ir11(iphas)
+    ir22ip = ir22(iphas)
+    ir33ip = ir33(iphas)
+    ir12ip = ir12(iphas)
+    ir13ip = ir13(iphas)
+    ir23ip = ir23(iphas)
+    iepiph = iep(iphas)
+  elseif(iturb(iphas).eq.50) then
+    ikiph  = ik(iphas)
+    iepiph = iep(iphas)
+    iphiph = iphi(iphas)
+    ifbiph = ifb(iphas)
+  elseif(iturb(iphas).eq.60) then
+    ikiph  = ik (iphas)
+    iomgip = iomg(iphas)
+  endif
+
+! Check if the pressure (unique) has not been handled already
+
+  iprnew = 1
+  if(iphas.gt.1) then
+    do kphas = 1, iphas-1
+      if(ipr(iphas).eq.ipr(kphas)) then
+        iprnew = 0
+      endif
+    enddo
+  endif
+
+! ifrslb = free standard outlet face closest to xyzp0 (icodcl not modified)
+! itbslb = max of ifrslb on all ranks, standard outlet face presence indicator
+
+! Even when the user has not chosen xyzp0 (and it is thus at the
+! origin), we choose the face whose center is closest to it, so
+! as to be mesh numbering (and partitioning) independent.
+
+  d0min = rinfin
+
+  ifrslb(iphas) = 0
+
+  ideb = idebty(isolib,iphas)
+  ifin = ifinty(isolib,iphas)
+
+  do ii = ideb, ifin
+    ifac = itrifb(ii,iphas)
+    if (icodcl(ifac,ipriph).eq.0) then
+      d0 =   (cdgfbo(1,ifac)-xxp0)**2  &
+           + (cdgfbo(2,ifac)-xyp0)**2  &
+           + (cdgfbo(3,ifac)-xzp0)**2
+      if (d0.lt.d0min) then
+        ifrslb(iphas) = ifac
+        d0min = d0
+      endif
+    endif
+  enddo
+
+  ! If we have free outlet faces, irangd and itbslb(iphas) will
+  ! contain respectively the rank having the boundary face whose
+  ! center is closest to xyzp0, and the local number of that face
+  ! on that rank (also equal to ifrslb(iphas) on that rank).
+  ! If we do not have free outlet faces, than itbslb(iphas) = 0
+  ! (as it was initialized that way on all ranks).
+
+  itbslb(iphas) = ifrslb(iphas)
+  irangd = irangp
+  if (irangp.ge.0) then
+    call parfpt(itbslb(iphas), irangd, d0min)
+  endif
+
+  if ((itbslb(iphas).gt.0) .and. (iprnew.eq.1)) then
+
+    inc = 1
+    iccocg = 1
+    nswrgp = nswrgr(ipriph)
+    imligp = imligr(ipriph)
+    iwarnp = iwarni(ipriph)
+    epsrgp = epsrgr(ipriph)
+    climgp = climgr(ipriph)
+    extrap = extrag(ipriph)
+    iclipr = iclrtp(ipriph,icoef)
+
+    call grdcel                                                   &
+    !==========
+ ( idebia , idebra ,                                              &
+   ndim   , ncelet , ncel   , nfac   , nfabor , nfml   , nprfml , &
+   nnod   , lndfac , lndfbr , ncelbr , nphas  ,                   &
+   nideve , nrdeve , nituse , nrtuse ,                            &
+   ipriph , imrgra , inc    , iccocg , nswrgp , imligp , iphydr , &
+   iwarnp , nfecra , epsrgp , climgp , extrap ,                   &
+   ifacel , ifabor , ifmfbr , ifmcel , iprfml ,                   &
+   ipnfac , nodfac , ipnfbr , nodfbr ,                            &
+   idevel , ituser , ia     ,                                     &
+   xyzcen , surfac , surfbo , cdgfac , cdgfbo , xyznod , volume , &
+   frcxt(1,1,iphas), frcxt(1,2,iphas), frcxt(1,3,iphas),          &
+   rtpa(1,ipriph)  , coefa(1,iclipr) , coefb(1,iclipr) ,          &
+   w1     , w2     , w3     ,                                     &
+!        ------   ------   ------
+   w4     , w5     , w6     ,                                     &
+   rdevel , rtuser , ra     )
+
+
+!  Put in coefu the value at I' or F (depending on iphydr) of the
+!  total pressure, computed from P*
+
+    if (iphydr.eq.0) then
+      do ifac = 1, nfabor
+        ii = ifabor(ifac)
+        iii = idiipb-1+3*(ifac-1)
+        diipbx = ra(iii+1)
+        diipby = ra(iii+2)
+        diipbz = ra(iii+3)
+        coefu(ifac,1) = rtpa(ii,ipriph)                           &
+             + diipbx*w1(ii)+ diipby*w2(ii) + diipbz*w3(ii)       &
+             + ro0iph*( gx*(cdgfbo(1,ifac)-xxp0)                  &
+                      + gy*(cdgfbo(2,ifac)-xyp0)                  &
+                      + gz*(cdgfbo(3,ifac)-xzp0))                 &
+             + p0iph - pr0iph
+      enddo
+    else
+      do ifac = 1, nfabor
+        ii = ifabor(ifac)
+        coefu(ifac,1) = rtpa(ii,ipriph)                           &
+             + (cdgfbo(1,ifac)-xyzcen(1,ii))*w1(ii)               &
+             + (cdgfbo(2,ifac)-xyzcen(2,ii))*w2(ii)               &
+             + (cdgfbo(3,ifac)-xyzcen(3,ii))*w3(ii)               &
+             + ro0iph*(  gx*(cdgfbo(1,ifac)-xxp0)                 &
+                       + gy*(cdgfbo(2,ifac)-xyp0)                 &
+                       + gz*(cdgfbo(3,ifac)-xzp0))                &
+             + p0iph - pr0iph
+      enddo
+    endif
+
+  endif
+
+
+!===============================================================================
+! 6.  Convert to rcodcl and icodcl
+!     (if this has not already been set by the user)
+
+!     First, process variables for which a specific treatement is done
+!     (pressure, velocity, ...)
+!===============================================================================
+
+! 6.1 ENTREE
+! ===========
+
+! ---> La pression a un traitement Neumann, le reste Dirichlet
+!                                           sera traite plus tard.
+
+  ideb = idebty(ientre,iphas)
+  ifin = ifinty(ientre,iphas)
+
+  do ivar = 1, nvar
+    if (ivar.eq.ipriph) then
+      if(iprnew.eq.1) then
+        do ii = ideb, ifin
+          ifac = itrifb(ii,iphas)
+          if(icodcl(ifac,ivar).eq.0) then
+            icodcl(ifac,ivar)   = 3
+            rcodcl(ifac,ivar,1) = 0.d0
+            rcodcl(ifac,ivar,2) = rinfin
+            rcodcl(ifac,ivar,3) = 0.d0
+          endif
+        enddo
+      endif
+    endif
+  enddo
+
+
+! 6.2 SORTIE (entr�e-sortie libre) (ISOLIB)
+! ===================
+
+! ---> La pression a un traitement Dirichlet, les vitesses 9
+!        (le reste Neumann, ou Dirichlet si donn�e utilisateur,
+!        sera traite plus tard)
+
+  if (iphydr.eq.1) then
+
+!     En cas de prise en compte de la pression hydrostatique,
+!     on remplit le tableau ISOSTD
+!     0 -> pas une face de sortie standard (i.e. pas sortie ou sortie avec CL
+!                                                de pression modifiee)
+!     1 -> face de sortie libre avec CL de pression automatique.
+!     le numero de la face de reference est stocke dans ISOSTD(NFABOR+1,IPHAS)
+!     qui est d'abord initialise a -1 (i.e. pas de face de sortie std)
+    isostd(nfabor+1,iphas) = -1
+    do ifac = 1,nfabor
+      isostd(ifac,iphas) = 0
+      if ((itypfb(ifac,iphas).eq.isolib).and.                     &
+           (icodcl(ifac,ipriph).eq.0)) then
+        isostd(ifac,iphas) = 1
+      endif
+    enddo
+  endif
+
+! ---> Reference pressure (unique, even if there are multiple outlets)
+!     In case we account for the hydrostatic pressure, we search for the
+!     reference face.
+
+!   Determine a unique P I' pressure in parallel
+!     if there are free outlet faces, we have determined that the rank
+!     with the outlet face closest to xyzp0 is irangd.
+
+!     We also retrieve the coordinates of the reference point, so as to
+!     calculate pref later on.
+
+  if (itbslb(iphas).gt.0) then
+
+    ! If irangd is the local rank, we assign PI' to coefup
+    ! (this is always the case in serial mode)
+
+    if (irangp.eq.irangd) then
+      xyzref(1) = cdgfbo(1,ifrslb(iphas))
+      xyzref(2) = cdgfbo(2,ifrslb(iphas))
+      xyzref(3) = cdgfbo(3,ifrslb(iphas))
+      xyzref(4) = coefu(ifrslb(iphas),1) ! coefup
+      if (iphydr.eq.1) isostd(nfabor+1,iphas) = ifrslb(iphas)
+    endif
+
+    ! Broadcast coefup and pressure reference
+    ! from irangd to all other ranks.
+    if (irangp.ge.0) then
+      inb = 4
+      call parbcr(irangd, inb, xyzref)
+    endif
+
+    coefup = xyzref(4)
+    xyzref(4) = 0.d0
+
+    ! If the user has not specified anything, we set ixyzp0 to 2 so as
+    ! to update the reference point.
+
+    if (ixyzp0(iphas).eq.-1) ixyzp0(iphas) = 2
+
+  elseif (ixyzp0(iphas).lt.0) then
+
+    ! If there are no outlet faces, we search for possible Dirichlets
+    ! specified by the user so as to locate the reference point.
+    ! As before, we chose the face closest to xyzp0 so as to
+    ! be mesh numbering (and partitioning) independent.
+
+    d0min = rinfin
+
+    ifadir = -1
+    do ifac = 1, nfabor
+      if (icodcl(ifac,ipriph).eq.1) then
+        d0 =   (cdgfbo(1,ifac)-xxp0)**2  &
+             + (cdgfbo(2,ifac)-xyp0)**2  &
+             + (cdgfbo(3,ifac)-xzp0)**2
+        if (d0.lt.d0min) then
+          ifadir = ifac
+          d0min = d0
+        endif
+      endif
+    enddo
+
+    irangd = irangp
+    if (irangp.ge.0) call parfpt(ifadir, irangd, d0min)
+
+    if (ifadir.gt.0) then
+
+      ! on met ixyzp0 a 2 pour mettre a jour le point de reference
+      ixyzp0(iphas) = 2
+
+      if (irangp.eq.irangd) then
+        xyzref(1) = cdgfbo(1,ifadir)
+        xyzref(2) = cdgfbo(2,ifadir)
+        xyzref(3) = cdgfbo(3,ifadir)
+      endif
+
+      ! Broadcast xyzref from irangd to all other ranks.
+      if (irangp.ge.0) then
+         inb = 3
+         call parbcr(irangd, inb, xyzref)
+      endif
+
+    endif
+
+  endif
+
+
+!   Si le point de reference n'a pas ete specifie par l'utilisateur
+!   on le change et on decale alors COEFU s'il y a des sorties.
+!   La pression totale dans PROPCE est aussi decalee (c'est a priori
+!   inutile sauf si l'utilisateur l'utilise dans ustsns par exemple)
+
+  if (ixyzp0(iphas).eq.2) then
+    ixyzp0(iphas) = 1
+    iiptot = ipproc(iprtot(iphas))
+    xxp0 = xyzref(1) - xyzp0(1,iphas)
+    xyp0 = xyzref(2) - xyzp0(2,iphas)
+    xzp0 = xyzref(3) - xyzp0(3,iphas)
+    xyzp0(1,iphas) = xyzref(1)
+    xyzp0(2,iphas) = xyzref(2)
+    xyzp0(3,iphas) = xyzref(3)
+    do iel = 1, ncelet
+      propce(iel,iiptot) = propce(iel,iiptot)                     &
+           - ro0iph*( gx*xxp0 + gy*xyp0 + gz*xzp0 )
+    enddo
+    if (itbslb(iphas).gt.0) then
+      write(nfecra,8000)iphas,xxp0,xyp0,xzp0
+      do ifac = 1, nfabor
+        coefu(ifac,1) = coefu(ifac,1)                             &
+             - ro0iph*( gx*xxp0 + gy*xyp0 + gz*xzp0 )
+      enddo
+      coefup = coefup - ro0iph*( gx*xxp0 + gy*xyp0 + gz*xzp0 )
+    else
+      write(nfecra,8001)iphas,xxp0,xyp0,xzp0
+    endif
+  elseif (ixyzp0(iphas).eq.-1) then
+!     Il n'y a pas de sorties ni de Dirichlet et l'utilisateur n'a
+!     rien specifie -> on met IXYZP0 a 0 pour ne plus y toucher, tout
+!     en differenciant du cas =1 qui necessitera une ecriture en suite
+    ixyzp0(iphas) = 0
+  endif
+
+!     La pression totale doit etre recalee en Xref a la valeur
+!     Po + rho_0*g.(Xref-X0)
+  if (itbslb(iphas).gt.0) then
+    xxp0 = xyzp0(1,iphas)
+    xyp0 = xyzp0(2,iphas)
+    xzp0 = xyzp0(3,iphas)
+    pref = p0(iphas)                                              &
+         + ro0iph*( gx*(xyzref(1)-xxp0)                           &
+                  + gy*(xyzref(2)-xyp0)                           &
+                  + gz*(xyzref(3)-xzp0) )                         &
+         - coefup
+  endif
+
+
+! ---> Entree/Sortie libre
+
+  ideb = idebty(isolib,iphas)
+  ifin = ifinty(isolib,iphas)
+
+  do ivar = 1, nvar
+    if (ivar.eq.ipriph) then
+      if(iprnew.eq.1) then
+        do ii = ideb, ifin
+          ifac = itrifb(ii,iphas)
+          if(icodcl(ifac,ivar).eq.0) then
+            icodcl(ifac,ivar)   = 1
+            rcodcl(ifac,ivar,1) = coefu(ifac,1) + pref
+            rcodcl(ifac,ivar,2) = rinfin
+            rcodcl(ifac,ivar,3) = 0.d0
+          endif
+        enddo
+      endif
+    elseif(ivar.eq.iuiph.or.ivar.eq.iviph.or.ivar.eq.iwiph) then
+      do ii = ideb, ifin
+        ifac = itrifb(ii,iphas)
+        if(icodcl(ifac,ivar).eq.0) then
+          icodcl(ifac,ivar)   = 9
+          rcodcl(ifac,ivar,1) = 0.d0
+          rcodcl(ifac,ivar,2) = rinfin
+          rcodcl(ifac,ivar,3) = 0.d0
+        endif
+      enddo
+    endif
+  enddo
+
+
+! 6.3 SYMETRIE
+! =============
+
+! ---> Les vecteurs et tenseurs ont un traitement particulier
+!        le reste Neumann sera traite plus tard
+
+  ideb = idebty(isymet,iphas)
+  ifin = ifinty(isymet,iphas)
+
+  do ivar = 1, nvar
+    if ( ivar.eq.iuiph.or.ivar.eq.iviph.or.ivar.eq.iwiph.or.      &
+       ( itytur(iphas).eq.3.and.                                  &
+          (ivar.eq.ir11ip.or.ivar.eq.ir22ip.or.ivar.eq.ir33ip.or. &
+           ivar.eq.ir12ip.or.ivar.eq.ir13ip.or.ivar.eq.ir23ip)    &
+                                                          ) ) then
+      do ii = ideb, ifin
+        ifac = itrifb(ii,iphas)
+        if(icodcl(ifac,ivar).eq.0) then
+          icodcl(ifac,ivar)   = 4
+!         rcodcl(ifac,ivar,1) = Modifie eventuellement par l'ALE
+          rcodcl(ifac,ivar,2) = rinfin
+          rcodcl(ifac,ivar,3) = 0.d0
+        endif
+      enddo
+    elseif(ivar.eq.ipriph) then
+      if(iprnew.eq.1) then
+        do ii = ideb, ifin
+          ifac = itrifb(ii,iphas)
+          if(icodcl(ifac,ivar).eq.0) then
+            icodcl(ifac,ivar)   = 3
+            rcodcl(ifac,ivar,1) = 0.d0
+            rcodcl(ifac,ivar,2) = rinfin
+            rcodcl(ifac,ivar,3) = 0.d0
+          endif
+        enddo
+      endif
+    endif
+  enddo
+
+! 6.4 PAROI LISSE
+! ===============
+
+! ---> La vitesse et les grandeurs turbulentes ont le code 5
+!        le reste Neumann sera traite plus tard
+
+  ideb = idebty(iparoi,iphas)
+  ifin = ifinty(iparoi,iphas)
+
+  do ivar = 1, nvar
+    if ( ivar.eq.iuiph.or.ivar.eq.iviph.or.ivar.eq.iwiph) then
+      do ii = ideb, ifin
+        ifac = itrifb(ii,iphas)
+        if(icodcl(ifac,ivar).eq.0) then
+          icodcl(ifac,ivar)   = 5
+!         rcodcl(ifac,ivar,1) = Utilisateur
+          rcodcl(ifac,ivar,2) = rinfin
+          rcodcl(ifac,ivar,3) = 0.d0
+        endif
+      enddo
+    elseif (                                                      &
+       ( itytur(iphas).eq.2.and.                                  &
+          (ivar.eq.ikiph  .or.ivar.eq.iepiph) ).or.               &
+       ( itytur(iphas).eq.3.and.                                  &
+          (ivar.eq.ir11ip.or.ivar.eq.ir22ip.or.ivar.eq.ir33ip.or. &
+           ivar.eq.ir12ip.or.ivar.eq.ir13ip.or.ivar.eq.ir23ip.or. &
+           ivar.eq.iepiph)                    ).or.               &
+       ( iturb(iphas).eq.50.and.                                  &
+          (ivar.eq.ikiph.or.ivar.eq.iepiph.or.ivar.eq.iphiph.or.  &
+           ivar.eq.ifbiph)                    ).or.               &
+       ( iturb(iphas).eq.60.and.                                  &
+          (ivar.eq.ikiph.or.ivar.eq.iomgip)   ) ) then
+      do ii = ideb, ifin
+        ifac = itrifb(ii,iphas)
+        if(icodcl(ifac,ivar).eq.0) then
+          icodcl(ifac,ivar)   = 5
+          rcodcl(ifac,ivar,1) = 0.d0
+          rcodcl(ifac,ivar,2) = rinfin
+          rcodcl(ifac,ivar,3) = 0.d0
+        endif
+      enddo
+    elseif(ivar.eq.ipriph) then
+      if(iprnew.eq.1) then
+        do ii = ideb, ifin
+          ifac = itrifb(ii,iphas)
+          if(icodcl(ifac,ivar).eq.0) then
+            icodcl(ifac,ivar)   = 3
+            rcodcl(ifac,ivar,1) = 0.d0
+            rcodcl(ifac,ivar,2) = rinfin
+            rcodcl(ifac,ivar,3) = 0.d0
+          endif
+        enddo
+      endif
+    endif
+  enddo
+
+! 6.5 PAROI RUGUEUSE
+! ==================
+
+! ---> La vitesse et les grandeurs turbulentes ont le code 6
+!      la rugosite est stockee dans rcodcl(..,..,3)
+!      le reste Neumann sera traite plus tard (idem paroi lisse)
+
+  ideb = idebty(iparug,iphas)
+  ifin = ifinty(iparug,iphas)
+
+  do ivar = 1, nvar
+    if ( ivar.eq.iuiph.or.ivar.eq.iviph.or.ivar.eq.iwiph) then
+      do ii = ideb, ifin
+        ifac = itrifb(ii,iphas)
+        if(icodcl(ifac,ivar).eq.0) then
+          icodcl(ifac,ivar)   = 6
+!         rcodcl(ifac,ivar,1) = Utilisateur
+          rcodcl(ifac,ivar,2) = rinfin
+!         rcodcl(ifac,ivar,3) = Utilisateur
+        endif
+      enddo
+    elseif (                                                      &
+       ( itytur(iphas).eq.2.and.                                  &
+          (ivar.eq.ikiph  .or.ivar.eq.iepiph) ).or.               &
+       ( itytur(iphas).eq.3.and.                                  &
+          (ivar.eq.ir11ip.or.ivar.eq.ir22ip.or.ivar.eq.ir33ip.or. &
+           ivar.eq.ir12ip.or.ivar.eq.ir13ip.or.ivar.eq.ir23ip.or. &
+           ivar.eq.iepiph)                    ).or.               &
+       ( iturb(iphas).eq.50.and.                                  &
+          (ivar.eq.ikiph.or.ivar.eq.iepiph.or.ivar.eq.iphiph.or.  &
+           ivar.eq.ifbiph)                    ).or.               &
+       ( iturb(iphas).eq.60.and.                                  &
+          (ivar.eq.ikiph.or.ivar.eq.iomgip)   ) ) then
+      do ii = ideb, ifin
+        ifac = itrifb(ii,iphas)
+        if(icodcl(ifac,ivar).eq.0) then
+          icodcl(ifac,ivar)   = 6
+          rcodcl(ifac,ivar,1) = 0.d0
+          rcodcl(ifac,ivar,2) = rinfin
+          rcodcl(ifac,ivar,3) = 0.d0
+        endif
+      enddo
+    elseif(ivar.eq.ipriph) then
+      if(iprnew.eq.1) then
+        do ii = ideb, ifin
+          ifac = itrifb(ii,iphas)
+          if(icodcl(ifac,ivar).eq.0) then
+            icodcl(ifac,ivar)   = 3
+            rcodcl(ifac,ivar,1) = 0.d0
+            rcodcl(ifac,ivar,2) = rinfin
+            rcodcl(ifac,ivar,3) = 0.d0
+          endif
+        enddo
+      endif
+    endif
+  enddo
+
+
+enddo
+! --- Boucle sur les phases : fin
+
+
+!===============================================================================
+! 6.bis  CONVERSION EN RCODCL ICODCL
+!   (SI CE DERNIER N'A PAS DEJA ETE RENSEIGNE PAR L'UTILISATEUR)
+
+!     MAINTENANT LES VARIABLES POUR LESQUELLES IL N'EXISTE PAS DE
+!    TRAITEMENT PARTICULIER (HORS PRESSION, VITESSE ...)
+!===============================================================================
+
+! --- Boucle sur les phases : debut
+do iphas = 1, nphas
+
+
+! 6.1 ENTREE bis
+! ===========
+
+! ---> La pression a un traitement Neumann (deja traitee plus haut),
+!      La vitesse  Dirichlet. Les scalaires ont un traitement
+!     Dirichlet si l'utilisateur fournit une valeur, sinon on utilise
+!     Neumann homogene si le flux de masse est sortant (erreur sinon).
+
+  ideb = idebty(ientre,iphas)
+  ifin = ifinty(ientre,iphas)
+
+  iok = 0
+  do ivar = 1, nvar
+    do ii = ideb, ifin
+      ifac = itrifb(ii,iphas)
+      if(icodcl(ifac,ivar).eq.0) then
+
+        if (ivar.eq.iuiph.or.ivar.eq.iviph.or.ivar.eq.iwiph)      &
+             then
+          if (rcodcl(ifac,ivar,1).gt.rinfin*0.5d0) then
+            itypfb(ifac,iphas) = - abs(itypfb(ifac,iphas))
+            if (iok.eq.0.or.iok.eq.2) iok = iok + 1
+          else
+            icodcl(ifac,ivar) = 1
+!           rcodcl(ifac,ivar,1) = Utilisateur
+            rcodcl(ifac,ivar,2) = rinfin
+            rcodcl(ifac,ivar,3) = 0.d0
+          endif
+
+        elseif (rcodcl(ifac,ivar,1).gt.rinfin*0.5d0) then
+
+          flumbf = propfb(ifac,ipprob(ifluma(iuiph)))
+          if( flumbf.ge.-epzero) then
+            icodcl(ifac,ivar)   = 3
+            rcodcl(ifac,ivar,1) = 0.d0
+            rcodcl(ifac,ivar,2) = rinfin
+            rcodcl(ifac,ivar,3) = 0.d0
+          else
+            itypfb(ifac,iphas) = - abs(itypfb(ifac,iphas))
+            if (iok.lt.2) iok = iok + 2
+          endif
+        else
+          icodcl(ifac,ivar) = 1
+!         rcodcl(ifac,ivar,1) = Utilisateur
+          rcodcl(ifac,ivar,2) = rinfin
+          rcodcl(ifac,ivar,3) = 0.d0
+        endif
+
+      endif
+    enddo
+  enddo
+
+  if (irangp.ge.0) call parcmx(iok)
+  if (iok.gt.0) then
+    if (iok.eq.1 .or. iok.eq.3) write(nfecra,6060)
+    if (iok.eq.2 .or. iok.eq.3) write(nfecra,6070)
+    call bcderr(nphas, itypfb)
+  endif
+
+
+
+! 6.2 SORTIE (entree sortie libre)
+! ===================
+
+! ---> La pression a un traitement Dirichlet, les vitesses 9 ont ete
+!        traites plus haut.
+!      Le reste Dirichlet si l'utilisateur fournit une donnee
+!        (flux de masse entrant ou sortant).
+!      S'il n'y a pas de donnee utilisateur, on utilise un Neumann homogene
+!        (flux entrant et sortant)
+
+
+! ---> Sortie ISOLIB
+
+  ideb = idebty(isolib,iphas)
+  ifin = ifinty(isolib,iphas)
+
+  do ivar = 1, nvar
+    do ii = ideb, ifin
+      ifac = itrifb(ii,iphas)
+      if(icodcl(ifac,ivar).eq.0) then
+
+         if (rcodcl(ifac,ivar,1).gt.rinfin*0.5d0) then
+              icodcl(ifac,ivar) = 3
+              rcodcl(ifac,ivar,1) = 0.d0
+              rcodcl(ifac,ivar,2) = rinfin
+              rcodcl(ifac,ivar,3) = 0.d0
+          else
+              icodcl(ifac,ivar) = 1
+!             rcodcl(ifac,ivar,1) = Utilisateur
+              rcodcl(ifac,ivar,2) = rinfin
+              rcodcl(ifac,ivar,3) = 0.d0
+         endif
+      endif
+    enddo
+  enddo
+
+
+
+! 6.3 SYMETRIE bis
+! =============
+
+! ---> Les vecteurs et tenseurs ont un traitement particulier
+!        traite plus haut
+!        le reste Neumann
+
+  ideb = idebty(isymet,iphas)
+  ifin = ifinty(isymet,iphas)
+
+  do ivar = 1, nvar
+    do ii = ideb, ifin
+      ifac = itrifb(ii,iphas)
+      if(icodcl(ifac,ivar).eq.0) then
+        icodcl(ifac,ivar)   = 3
+        rcodcl(ifac,ivar,1) = 0.d0
+        rcodcl(ifac,ivar,2) = rinfin
+        rcodcl(ifac,ivar,3) = 0.d0
+      endif
+    enddo
+  enddo
+
+! 6.4 PAROI LISSE bis
+! ===============
+
+! ---> La vitesse et les grandeurs turbulentes ont le code 5
+!        traite plus haut
+!        le reste Neumann
+
+  ideb = idebty(iparoi,iphas)
+  ifin = ifinty(iparoi,iphas)
+
+  do ivar = 1, nvar
+    do ii = ideb, ifin
+      ifac = itrifb(ii,iphas)
+      if(icodcl(ifac,ivar).eq.0) then
+        icodcl(ifac,ivar)   = 3
+        rcodcl(ifac,ivar,1) = 0.d0
+        rcodcl(ifac,ivar,2) = rinfin
+        rcodcl(ifac,ivar,3) = 0.d0
+      endif
+    enddo
+  enddo
+
+! 6.5 PAROI RUGUEUSE bis
+! ==================
+
+! ---> La vitesse et les grandeurs turbulentes ont le code 6
+!        traite plus haut
+!        le reste Neumann
+
+  ideb = idebty(iparug,iphas)
+  ifin = ifinty(iparug,iphas)
+
+  do ivar = 1, nvar
+    do ii = ideb, ifin
+      ifac = itrifb(ii,iphas)
+      if(icodcl(ifac,ivar).eq.0) then
+        icodcl(ifac,ivar)   = 3
+        rcodcl(ifac,ivar,1) = 0.d0
+        rcodcl(ifac,ivar,2) = rinfin
+        rcodcl(ifac,ivar,3) = 0.d0
+      endif
+    enddo
+  enddo
+
+enddo
+! --- Boucle sur les phases : fin
+!===============================================================================
+! 7.  RENFORCEMENT DIAGONALE DE LA MATRICE SI AUCUN POINTS DIRICHLET
+!===============================================================================
+! On renforce si ISTAT=0 et si l'option est activee (IDIRCL=1)
+! Si une de ces conditions est fausse, on force NDIRCL a valoir
+! au moins 1 pour ne pas declaer la diagonale.
+
+do ivar = 1, nvar
+  ndircl(ivar) = 0
+  if ( istat(ivar).gt.0 .or. idircl(ivar).eq.0 ) ndircl(ivar) = 1
+enddo
+
+do ivar = 1, nvar
+  do ifac = 1, nfabor
+    if( icodcl(ifac,ivar).eq.1 .or. icodcl(ifac,ivar).eq.5 ) then
+      ndircl(ivar) = ndircl(ivar) +1
+    endif
+  enddo
+  if (irangp.ge.0) call parcpt (ndircl(ivar))
+enddo
+
+!===============================================================================
+! 8.  ON CALCULE LE FLUX DE MASSE AUX DIFFERENTS TYPES DE FACES
+!       ET ON IMPRIME.
+
+!     Ca serait utile de faire l'impression dans ECRLIS, mais attention,
+!       on imprime le flux de masse du pas de temps precedent
+!       or dans ECRLIS, on imprime a la fin du pas de temps
+!       d'ou une petite incoherence possible.
+!     D'autre part, ca serait utile de sortir d'autres grandeurs
+!       (flux de chaleur par exemple, bilan de scalaires ...)
+
+!===============================================================================
+
+iwaru = -1
+do iphas = 1, nphas
+  iuiph  = iu(iphas)
+  iwaru = max(iwarni(iuiph),iwaru)
+enddo
+if (irangp.ge.0) call parcmx(iwaru)
+
+if(iwaru.ge.1 .or. mod(ntcabs,ntlist).eq.0                        &
+       .or.(ntcabs.le.ntpabs+2).or.(ntcabs.ge.ntmabs-1)) then
+  write(nfecra,7010)
+endif
+
+do iphas = 1, nphas
+
+  iuiph  = iu(iphas)
+  iflmab = ipprob(ifluma(iuiph))
+
+  iwrnp = iwarni(iu(iphas))
+  if (irangp.ge.0) call parcmx (iwrnp)
+                   !==========
+
+!     On ecrit le flux de masse si IWARNI>0, a la periodicite NTLIST
+!     et au deux premiers et deux derniers pas de temps.
+  if(iwrnp.ge.1 .or. mod(ntcabs,ntlist).eq.0                      &
+       .or.(ntcabs.le.ntpabs+2).or.(ntcabs.ge.ntmabs-1)) then
+
+    do ii = 1, ntypmx
+      flumty(ii) = 0.d0
+    enddo
+
+    do ii = 1, ntypmx
+      ideb = idebty(ii,iphas)
+      ifin = ifinty(ii,iphas)
+      do jj = ideb, ifin
+        ifac = itrifb(jj,iphas)
+        flumty(ii) = flumty(ii) + propfb(ifac,iflmab)
+      enddo
+    enddo
+
+
+    write(nfecra,7011) iphas
+
+    if (ippmod(icompf).lt.0 ) then
+
+      ii = ientre
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Entree           ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Inlet            ',ii,inb,flumty(ii)
+#endif
+      ii = iparoi
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Paroi lisse      ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Smooth wall      ',ii,inb,flumty(ii)
+#endif
+      ii = iparug
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Paroi rugueuse   ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Rough wall       ',ii,inb,flumty(ii)
+#endif
+      ii = isymet
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Symetrie         ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Symmetry         ',ii,inb,flumty(ii)
+#endif
+
+      ii = isolib
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Sortie libre     ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Free outlet      ',ii,inb,flumty(ii)
+#endif
+
+      if (nbrcpl.ge.1) then
+        ii = icscpl
+        inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+        if (irangp.ge.0) then
+          call parcpt (inb)
+          call parsom (flumty(ii))
+        endif
+#if defined(_CS_LANG_FR)
+        write(nfecra,7020) 'Couplage sat/sat ',ii,inb,flumty(ii)
+#else
+        write(nfecra,7020) 'Sat/Sat coupling ',ii,inb,flumty(ii)
+#endif
+      endif
+
+      ii = iindef
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Indefini         ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Undefined        ',ii,inb,flumty(ii)
+#endif
+
+      do ii = 1, ntypmx
+        if( ii.ne.ientre .and.                                    &
+            ii.ne.iparoi .and.                                    &
+            ii.ne.iparug .and.                                    &
+            ii.ne.isymet .and.                                    &
+            ii.ne.isolib .and.                                    &
+            ii.ne.icscpl .and.                                    &
+            ii.ne.iindef ) then
+          inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+          if (irangp.ge.0) then
+            call parcpt (inb)
+            call parsom (flumty(ii))
+          endif
+          if(inb.gt.0) then
+#if defined(_CS_LANG_FR)
+            write(nfecra,7020) 'Type utilisateur ',ii,inb,flumty(ii)
+#else
+            write(nfecra,7020) 'User type        ',ii,inb,flumty(ii)
+#endif
+          endif
+        endif
+      enddo
+
+    else
+
+      ii = ieqhcf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Entree sub. enth.',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Sub. enth. inlet ',ii,inb,flumty(ii)
+#endif
+
+      ii = ierucf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Entree subsonique',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Subsonic inlet   ',ii,inb,flumty(ii)
+#endif
+
+      ii = iesicf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Entree/Sortie imp',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Imp inlet/outlet ',ii,inb,flumty(ii)
+#endif
+
+      ii = isopcf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Sortie subsonique',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Subsonic outlet  ',ii,inb,flumty(ii)
+#endif
+
+      ii = isspcf
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Sortie supersoniq',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Supersonic outlet',ii,inb,flumty(ii)
+#endif
+
+      ii = iparoi
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Paroi            ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Wall             ',ii,inb,flumty(ii)
+#endif
+
+      ii = isymet
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Symetrie         ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Symmetry         ',ii,inb,flumty(ii)
+#endif
+
+      ii = iindef
+      inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+      if (irangp.ge.0) then
+        call parcpt (inb)
+        call parsom (flumty(ii))
+      endif
+#if defined(_CS_LANG_FR)
+      write(nfecra,7020) 'Indefini         ',ii,inb,flumty(ii)
+#else
+      write(nfecra,7020) 'Undefined        ',ii,inb,flumty(ii)
+#endif
+
+      do ii = 1, ntypmx
+        if (ii.ne.iesicf .and. &
+            ii.ne.isspcf .and. &
+            ii.ne.ieqhcf .and. &
+            ii.ne.ierucf .and. &
+            ii.ne.isopcf .and. &
+            ii.ne.iparoi .and. &
+            ii.ne.isymet .and. &
+            ii.ne.iindef) then
+          inb = ifinty(ii,iphas)-idebty(ii,iphas)+1
+          if (irangp.ge.0) then
+            call parcpt (inb)
+            call parsom (flumty(ii))
+          endif
+          if(inb.gt.0) then
+#if defined(_CS_LANG_FR)
+            write(nfecra,7020) 'Type utilisateur ',ii,inb,flumty(ii)
+#else
+            write(nfecra,7020) 'User type        ',ii,inb,flumty(ii)
+#endif
+          endif
+        endif
+      enddo
+
+    endif
+
+    write(nfecra,7030)
+
+  endif
+
+enddo
+
+
+!===============================================================================
+! FORMATS
+!===============================================================================
+
+#if defined(_CS_LANG_FR)
+
+ 1099 format(                                                     &
+'@                                                            ',/,&
+'@                                                            ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/,&
+'@ @@ ATTENTION : ARRET LORS DE LA VERIFICATION DES COND. LIM.',/,&
+'@    =========                                               ',/,&
+'@    CONDITIONS AUX LIMITES INCORRECTES OU INCOMPLETES       ',/,&
+'@                                                            ',/,&
+'@    La valeur du type ITYPFB des conditions aux limites doit',/,&
+'@      etre superieure ou egale a          1                 ',/,&
+'@        et inferieure ou egale a ',I10                       ,/,&
+'@    Une ou plusieurs erreurs sont listees ci-dessus.        ',/,&
+'@                                                            ',/,&
+'@    Le calcul ne sera pas execute.                          ',/,&
+'@                                                            ',/,&
+'@    Verifier le codage du sous-programme de definition des  ',/,&
+'@    aux limites.                                            ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+ 2010 format(/,' PHASE  : ',I10)
+ 2020 format(/,'   IFINTY : ',I10)
+ 2030 format(/,'   IDEBTY : ',I10)
+ 2040 format(/,'   ITYPFB : ',I10)
+ 2098 format(/,                                                   &
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/,&
+'@ @@ ATTENTION : ARRET LORS DE LA VERIFICATION DES COND. LIM.',/,&
+'@    =========                                               ',/,&
+'@    PROBLEME DE TRI DES FACES DE BORD                       ',/,&
+'@                                                            ',/,&
+'@    IFINTY(',I10   ,') = ',I10                               ,/,&
+'@      est superieur a                                       ',/,&
+'@    IDEBTY(',I10   ,') = ',I10                               ,/,&
+'@                                                            ',/,&
+'@    Le calcul ne sera pas execute.                          ',/,&
+'@                                                            ',/,&
+'@    Contacter l''assistance.                                ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+ 2099 format(/,                                                   &
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/,&
+'@ @@ ATTENTION : ARRET LORS DE LA VERIFICATION DES COND. LIM.',/,&
+'@    =========                                               ',/,&
+'@    PROBLEME DE TRI DES FACES DE BORD SUR UN RANG DISTANT   ',/,&
+'@                                                            ',/,&
+'@    IFINTY(',I10   ,')                                      ',/,&
+'@      est superieur a                                       ',/,&
+'@    IDEBTY(',I10   ,')                                      ',/,&
+'@                                                            ',/,&
+'@    Le calcul ne sera pas execute.                          ',/,&
+'@                                                            ',/,&
+'@    Contacter l''assistance.                                ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+ 3099 format(                                                           &
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/,&
+'@ @@ ATTENTION : ARRET LORS DE LA VERIFICATION DES COND. LIM.',/,&
+'@    =========                                               ',/,&
+'@    PROBLEME DE TRI DES FACES DE BORD                       ',/,&
+'@                                                            ',/,&
+'@    Phase          ',I10                                     ,/,&
+'@      nombre de faces classees par type = ',I10              ,/,&
+'@      nombre de faces de bord  NFABOR   = ',I10              ,/,&
+'@                                                            ',/,&
+'@    Le calcul ne sera pas execute.                          ',/,&
+'@                                                            ',/,&
+'@    Contacter l''assistance.                                ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+
+ 6010 format ( /,/,                                               &
+ '   ** INFORMATIONS SUR LE TYPE DE FACES DE BORD',/,             &
+ '      -----------------------------------------',/)
+ 6011 format (                                                    &
+'   Phase : ',I4,                                               /,&
+'---------------------------------------------------------------',&
+'----------',                                                     &
+                                                                /,&
+'Type de bord           Code    Nb faces',                        &
+                                                                /,&
+'---------------------------------------------------------------',&
+'----------')
+ 6020 format (                                                    &
+ a17,i10,i12)
+ 6030 format(                                                     &
+'---------------------------------------------------------------',&
+'----------'/)
+
+ 6060 format(                                                     &
+'@                                                            ',/,&
+'@                                                            ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/,&
+'@ @@ ATTENTION : ARRET LORS DE LA VERIFICATION DES COND. LIM.',/,&
+'@    =========                                               ',/,&
+'@    CONDITIONS AUX LIMITES INCORRECTES OU INCOMPLETES       ',/,&
+'@                                                            ',/,&
+'@    Au moins une face de bord declaree en entree            ',/,&
+'@      (ou sortie) a vitesse imposee pour laquelle la valeur ',/,&
+'@      de la vitesse n''a pas ete fournie pour toutes les    ',/,&
+'@      composantes.                                          ',/,&
+'@    Le calcul ne sera pas execute.                          ',/,&
+'@                                                            ',/,&
+'@    Verifier les conditions aux limites dans l''Interface   ',/,&
+'@    ou dans le sous-programme utilisateur correspondant.    ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+ 6070 format(                                                           &
+'@                                                            ',/,&
+'@                                                            ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/,&
+'@ @@ ATTENTION : ARRET LORS DE LA VERIFICATION DES COND. LIM.',/,&
+'@    =========                                               ',/,&
+'@    CONDITIONS AUX LIMITES INCORRECTES OU INCOMPLETES       ',/,&
+'@                                                            ',/,&
+'@    Au moins une face de bord declaree en entree            ',/,&
+'@      (ou sortie) a vitesse imposee avec un flux rentrant   ',/,&
+'@      pour laquelle la valeur d''une variable n''a pas ete  ',/,&
+'@      specifiee (condition de Dirichlet).                   ',/,&
+'@    Le calcul ne sera pas execute                           ',/,&
+'@                                                            ',/,&
+'@    Verifier les conditions aux limites dans l''Interface   ',/,&
+'@    ou dans le sous-programme utilisateur correspondant.    ',/,&
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+
+ 7010 format ( /,/,                                               &
+ '   ** INFORMATIONS SUR LE FLUX DE MASSE AU BORD',/,             &
+ '      -----------------------------------------',/)
+ 7011 format (                                                    &
+'   Phase : ',I4,                                               /,&
+'---------------------------------------------------------------',&
+                                                                /,&
+'Type de bord           Code    Nb faces           Flux de masse',&
+                                                                /,&
+'---------------------------------------------------------------')
+ 7020 format (                                                    &
+ a17,i10,i12,6x,e18.9)
+ 7030 format(                                                     &
+'---------------------------------------------------------------',&
+                                                                /)
+
+ 8000 format(/,                                                   &
+'PHASE ',I4,' :                                               ',/,&
+'Faces de bord d''entree/sortie libre detectees               ',/,&
+'Mise a jour du point de reference pour la pression totale    ',/,&
+' XYZP0 = ',E14.5,E14.5,E14.5                  ,/)
+ 8001 format(/,                                                   &
+'PHASE ',I4,' :                                               ',/,&
+'Faces de bord a Dirichlet de pression impose detectees       ',/,&
+'Mise a jour du point de reference pour la pression totale    ',/,&
+' XYZP0 = ',E14.5,E14.5,E14.5                  ,/)
+
+!-------------------------------------------------------------------------------
+
+#else
+
+ 1099 format(                                                     &
+'@'                                                            ,/,&
+'@'                                                            ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@'                                                            ,/,&
+'@ @@ WARNING: ABORT BY BOUNDARY CONDITION CHECK'              ,/,&
+'@    ========'                                                ,/,&
+'@    INCORRECT OR INCOMPLETE BOUNDARY CONDITIONS'             ,/,&
+'@'                                                            ,/,&
+'@    Value of type ITYPFB for boundary conditions must be'    ,/,&
+'@          greater or equal to          1'                    ,/,&
+'@      and less than or equal to ', I10                       ,/,&
+'@    One or more errors are listed above.'                    ,/,&
+'@'                                                            ,/,&
+'@    The calculation will not be run.'                        ,/,&
+'@'                                                            ,/,&
+'@    Verify the boundary condition definitions in the'        ,/,&
+'@    appropriate user subroutine.'                            ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@'                                                            ,/)
+
+ 2010 format(/,' PHASE  : ',I10)
+ 2020 format(/,'   IFINTY : ',I10)
+ 2030 format(/,'   IDEBTY : ',I10)
+ 2040 format(/,'   ITYPFB : ',I10)
+ 2098 format(/,                                                   &
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@'                                                            ,/,&
+'@ @@ WARNING: ABORT BY BOUNDARY CONDITION CHECK'              ,/,&
+'@    ========'                                                ,/,&
+'@    PROBLEM WITH ORDERING OF BOUNDARY FACES'                 ,/,&
+'@'                                                            ,/,&
+'@    IFINTY(',I10   ,') = ',I10                               ,/,&
+'@      is greater than'                                       ,/,&
+'@    IDEBTY(',I10   ,') = ',I10                               ,/,&
+'@'                                                            ,/,&
+'@    The calculation will not be run.'                        ,/,&
+'@'                                                            ,/,&
+'@    Contact support.'                                        ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+ 2099 format(/,                                                   &
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@'                                                            ,/,&
+'@ @@ WARNING: ABORT BY BOUNDARY CONDITION CHECK'              ,/,&
+'@    ========'                                                ,/,&
+'@    PROBLEM WITH ORDERING OF BOUNDARY FACES'                 ,/,&
+'@    ON A DISTANT RANK.'                                      ,/,&
+'@'                                                            ,/,&
+'@    IFINTY(',I10   ,')                                      ',/,&
+'@      is greater than'                                       ,/,&
+'@    IDEBTY(',I10   ,')                                      ',/,&
+'@'                                                            ,/,&
+'@    The calculation will not be run.'                        ,/,&
+'@'                                                            ,/,&
+'@    Contact support.'                                        ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+ 3099 format(                                                     &
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@'                                                            ,/,&
+'@ @@ WARNING: ABORT BY BOUNDARY CONDITION CHECK'              ,/,&
+'@    ========'                                                ,/,&
+'@    PROBLEM WITH ORDERING OF BOUNDARY FACES'                 ,/,&
+'@'                                                            ,/,&
+'@    Phase          ',I10                                     ,/,&
+'@      number of faces classified by type = ',I10             ,/,&
+'@      number of boundary faces (NFABOR)  = ',I10             ,/,&
+'@'                                                            ,/,&
+'@    The calculation will not be run.'                        ,/,&
+'@'                                                            ,/,&
+'@    Contact support.'                                        ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+
+ 6010 format ( /,/,                                               &
+ '   ** INFORMATION ON BOUNDARY FACES TYPE',/,                    &
+ '      ----------------------------------',/)
+ 6011 format (                                                    &
+'   Phase : ',I4,                                               /,&
+'---------------------------------------------------------------',&
+'----------',                                                     &
+                                                                /,&
+'Boundary type          Code    Nb faces',                        &
+                                                                /,&
+'---------------------------------------------------------------',&
+'----------')
+ 6020 format (                                                    &
+ a17,i10,i12)
+ 6030 format(                                                     &
+'---------------------------------------------------------------',&
+'----------'/)
+
+ 6060 format(                                                     &
+'@'                                                            ,/,&
+'@'                                                            ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@'                                                            ,/,&
+'@ @@ WARNING: ABORT BY BOUNDARY CONDITION CHECK'              ,/,&
+'@    ========'                                                ,/,&
+'@    INCORRECT OR INCOMPLETE BOUNDARY CONDITIONS'             ,/,&
+'@'                                                            ,/,&
+'@    At least one boundary face declared as inlet (or'        ,/,&
+'@      outlet) with prescribed velocity for which the'        ,/,&
+'@      velocity value has not been assigned for all'          ,/,&
+'@      components.'                                           ,/,&
+'@    The calculation will not be run.                        ',/,&
+'@'                                                            ,/,&
+'@    Verify the boundary condition definitions in the GUI'    ,/,&
+'@    or in the appropriate user subroutine.'                  ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+ 6070 format(                                                     &
+'@'                                                            ,/,&
+'@'                                                            ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@'                                                            ,/,&
+'@ @@ WARNING: ABORT BY BOUNDARY CONDITION CHECK'              ,/,&
+'@    ========'                                                ,/,&
+'@    INCORRECT OR INCOMPLETE BOUNDARY CONDITIONS'             ,/,&
+'@'                                                            ,/,&
+'@    At least one boundary face declared as inlet (or'        ,/,&
+'@      outlet) with prescribed velocity with an entering'     ,/,&
+'@      flow for which the value of a variable has not been'   ,/,&
+'@      specified (Dirichlet condition).'                      ,/,&
+'@    The calculation will not be run.                        ',/,&
+'@'                                                            ,/,&
+'@    Verify the boundary condition definitions in the GUI'    ,/,&
+'@    or in the appropriate user subroutine.'                  ,/,&
+'@'                                                            ,/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@                                                            ',/)
+
+
+ 7010 format ( /,/,                                               &
+ '   ** BOUNDARY MASS FLOW INFORMATION',/,                        &
+ '      ------------------------------',/)
+ 7011 format (                                                    &
+'   Phase : ',I4,                                               /,&
+'---------------------------------------------------------------',&
+                                                                /,&
+'Boundary type          Code    Nb faces           Mass flow'   , &
+                                                                /,&
+'---------------------------------------------------------------')
+ 7020 format (                                                    &
+ a17,i10,i12,6x,e18.9)
+ 7030 format(                                                     &
+'---------------------------------------------------------------',&
+                                                                /)
+
+ 8000 format(/,                                                   &
+'PHASE ',I4,' :'                                               ,/,&
+'Boundary faces with free inlet/outlet detected'               ,/,&
+'Update of reference point for total pressure'                 ,/,&
+' XYZP0 = ',E14.5,E14.5,E14.5                  ,/)
+ 8001 format(/,                                                   &
+'PHASE ',I4,' :'                                               ,/,&
+'Boundary faces with pressure Dirichlet condition detected'    ,/,&
+'Update of reference point for total pressure'                 ,/,&
+' XYZP0 = ',E14.5,E14.5,E14.5                  ,/)
+
+#endif
+
+
+return
+end subroutine
diff --git a/po/Makefile.in.in b/po/Makefile.in.in
index fecf500..83d8838 100644
--- a/po/Makefile.in.in
+++ b/po/Makefile.in.in
@@ -1,5 +1,5 @@
 # Makefile for PO directory in any package using GNU gettext.
-# Copyright (C) 1995-1997, 2000-2007 by Ulrich Drepper <drepper at gnu.ai.mit.edu>
+# Copyright (C) 1995-1997, 2000-2007, 2009-2010 by Ulrich Drepper <drepper at gnu.ai.mit.edu>
 #
 # This file can be copied and used freely without restrictions.  It can
 # be used in projects which are not available under the GNU General Public
@@ -8,8 +8,8 @@
 # Please note that the actual code of GNU gettext is covered by the GNU
 # General Public License and is *not* in the public domain.
 #
-# Origin: gettext-0.17
-GETTEXT_MACRO_VERSION = 0.17
+# Origin: gettext-0.18
+GETTEXT_MACRO_VERSION = 0.18
 
 PACKAGE = @PACKAGE@
 VERSION = @VERSION@
@@ -88,8 +88,8 @@ CATALOGS = @CATALOGS@
 .po.gmo:
 	@lang=`echo $* | sed -e 's,.*/,,'`; \
 	test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
-	echo "$${cdcmd}rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o $${lang}.gmo $${lang}.po"; \
-	cd $(srcdir) && rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o t-$${lang}.gmo $${lang}.po && mv t-$${lang}.gmo $${lang}.gmo
+	echo "$${cdcmd}rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics --verbose -o $${lang}.gmo $${lang}.po"; \
+	cd $(srcdir) && rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics --verbose -o t-$${lang}.gmo $${lang}.po && mv t-$${lang}.gmo $${lang}.gmo
 
 .sin.sed:
 	sed -e '/^#/d' $< > t-$@
@@ -193,8 +193,15 @@ $(POFILES): $(srcdir)/$(DOMAIN).pot
 	@lang=`echo $@ | sed -e 's,.*/,,' -e 's/\.po$$//'`; \
 	if test -f "$(srcdir)/$${lang}.po"; then \
 	  test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
-	  echo "$${cdcmd}$(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot"; \
-	  cd $(srcdir) && $(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot; \
+	  echo "$${cdcmd}$(MSGMERGE_UPDATE) $(MSGMERGE_OPTIONS) --lang=$${lang} $${lang}.po $(DOMAIN).pot"; \
+	  cd $(srcdir) \
+	    && { case `$(MSGMERGE_UPDATE) --version | sed 1q | sed -e 's,^[^0-9]*,,'` in \
+	           '' | 0.[0-9] | 0.[0-9].* | 0.1[0-7] | 0.1[0-7].*) \
+	             $(MSGMERGE_UPDATE) $(MSGMERGE_OPTIONS) $${lang}.po $(DOMAIN).pot;; \
+	           *) \
+	             $(MSGMERGE_UPDATE) $(MSGMERGE_OPTIONS) --lang=$${lang} $${lang}.po $(DOMAIN).pot;; \
+	         esac; \
+	       }; \
 	else \
 	  $(MAKE) $${lang}.po-create; \
 	fi
@@ -217,7 +224,6 @@ install-data: install-data- at USE_NLS@
 	fi
 install-data-no: all
 install-data-yes: all
-	$(mkdir_p) $(DESTDIR)$(datadir)
 	@catalogs='$(CATALOGS)'; \
 	for cat in $$catalogs; do \
 	  cat=`basename $$cat`; \
@@ -269,7 +275,6 @@ installdirs-data: installdirs-data- at USE_NLS@
 	fi
 installdirs-data-no:
 installdirs-data-yes:
-	$(mkdir_p) $(DESTDIR)$(datadir)
 	@catalogs='$(CATALOGS)'; \
 	for cat in $$catalogs; do \
 	  cat=`basename $$cat`; \
@@ -395,9 +400,15 @@ update-po: Makefile
 	tmpdir=`pwd`; \
 	echo "$$lang:"; \
 	test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
-	echo "$${cdcmd}$(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$lang.new.po"; \
+	echo "$${cdcmd}$(MSGMERGE) $(MSGMERGE_OPTIONS) --lang=$$lang $$lang.po $(DOMAIN).pot -o $$lang.new.po"; \
 	cd $(srcdir); \
-	if $(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$tmpdir/$$lang.new.po; then \
+	if { case `$(MSGMERGE) --version | sed 1q | sed -e 's,^[^0-9]*,,'` in \
+	       '' | 0.[0-9] | 0.[0-9].* | 0.1[0-7] | 0.1[0-7].*) \
+	         $(MSGMERGE) $(MSGMERGE_OPTIONS) -o $$tmpdir/$$lang.new.po $$lang.po $(DOMAIN).pot;; \
+	       *) \
+	         $(MSGMERGE) $(MSGMERGE_OPTIONS) --lang=$$lang -o $$tmpdir/$$lang.new.po $$lang.po $(DOMAIN).pot;; \
+	     esac; \
+	   }; then \
 	  if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
 	    rm -f $$tmpdir/$$lang.new.po; \
 	  else \
@@ -418,9 +429,13 @@ $(DUMMYPOFILES):
 update-gmo: Makefile $(GMOFILES)
 	@:
 
+# Recreate Makefile by invoking config.status. Explicitly invoke the shell,
+# because execution permission bits may not work on the current file system.
+# Use @SHELL@, which is the shell determined by autoconf for the use by its
+# scripts, not $(SHELL) which is hardwired to /bin/sh and may be deficient.
 Makefile: Makefile.in.in Makevars $(top_builddir)/config.status @POMAKEFILEDEPS@
 	cd $(top_builddir) \
-	  && $(SHELL) ./config.status $(subdir)/$@.in po-directories
+	  && @SHELL@ ./config.status $(subdir)/$@.in po-directories
 
 force:
 
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 1c5f6cc..f2c4f99 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -12,6 +12,7 @@ src/base/cs_gradient.c
 src/base/cs_grid.c
 src/base/cs_gui_boundary_conditions.c
 src/base/cs_gui.c
+src/base/cs_gui_conjugate_heat_transfer.c
 src/base/cs_gui_matisse.c
 src/base/cs_gui_mobile_mesh.c
 src/base/cs_gui_particles.c
@@ -24,6 +25,7 @@ src/base/cs_join.c
 src/base/cs_join_intersect.c
 src/base/cs_join_merge.c
 src/base/cs_join_mesh.c
+src/base/cs_join_perio.c
 src/base/cs_join_post.c
 src/base/cs_join_set.c
 src/base/cs_join_split.c
diff --git a/po/fr.gmo b/po/fr.gmo
new file mode 100644
index 0000000..bb3960d
Binary files /dev/null and b/po/fr.gmo differ
diff --git a/po/fr.po b/po/fr.po
index 50120ef..528261b 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -9,16 +9,17 @@ msgid ""
 msgstr ""
 "Project-Id-Version: ncs 2.0\n"
 "Report-Msgid-Bugs-To: saturne-support at edf.fr\n"
-"POT-Creation-Date: 2010-02-12 19:18+0100\n"
+"POT-Creation-Date: 2010-12-20 12:07+0100\n"
 "PO-Revision-Date: 2010-01-11 12:50+0100\n"
 "Last-Translator: Code_Saturne <saturne-support at edf.fr>\n"
 "Language-Team: French <traduc at traduc.org>\n"
+"Language: fr\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
 "Plural-Forms: nplurals=2; plural=(n > 1);\n"
 
-#: src/apps/cs_solver.c:292
+#: src/apps/cs_solver.c:293
 #, c-format
 msgid ""
 "\n"
@@ -27,7 +28,7 @@ msgstr ""
 "\n"
 " Découpage des faces gauches (%.3g s)\n"
 
-#: src/apps/cs_solver.c:298
+#: src/apps/cs_solver.c:299
 msgid ""
 "\n"
 " Renumbering mesh:\n"
@@ -35,11 +36,11 @@ msgstr ""
 "\n"
 " Renumérotation du maillage:\n"
 
-#: src/apps/cs_solver.c:354
+#: src/apps/cs_solver.c:355
 msgid "Mesh"
 msgstr "Maillage"
 
-#: src/apps/cs_solver.c:368
+#: src/apps/cs_solver.c:369
 #, c-format
 msgid ""
 "\n"
@@ -48,7 +49,7 @@ msgstr ""
 "\n"
 " Calcul des grandeurs géométriques (%.3g s)\n"
 
-#: src/apps/cs_solver.c:384
+#: src/apps/cs_solver.c:385
 msgid ""
 "\n"
 " Computing quality criteria\n"
@@ -56,7 +57,7 @@ msgstr ""
 "\n"
 " Calcul des critères de qualité\n"
 
-#: src/apps/cs_solver.c:406
+#: src/apps/cs_solver.c:407
 #, c-format
 msgid ""
 "\n"
@@ -71,7 +72,7 @@ msgstr ""
 "       longra =   %10d (Nombre de réels)\n"
 "       (%d octets/entier, %d octets/réel)\n"
 
-#: src/apps/cs_solver.c:416
+#: src/apps/cs_solver.c:417
 #, c-format
 msgid ""
 "\n"
@@ -84,7 +85,7 @@ msgstr ""
 "       nideve =   %10d (Nombre d'entiers)\n"
 "       nrdeve =   %10d (Nombre de réels)\n"
 
-#: src/apps/cs_solver.c:422
+#: src/apps/cs_solver.c:423
 #, c-format
 msgid ""
 "\n"
@@ -99,7 +100,7 @@ msgstr ""
 "       nrtuse =   %10d (Nombre de réels)\n"
 "\n"
 
-#: src/apps/cs_solver.c:484
+#: src/apps/cs_solver.c:485
 msgid ""
 "\n"
 " Destroying structures and ending computation\n"
@@ -152,23 +153,23 @@ msgstr ""
 
 #: src/base/cs_base.c:427
 #, c-format
-msgid "Theoretical current allocated memory:   %lu kB\n"
-msgstr "Mémoire dynamique instrumentée théorique : %lu ko\n"
+msgid "Theoretical current allocated memory:   %llu kB\n"
+msgstr "Mémoire dynamique instrumentée théorique : %llu ko\n"
 
 #: src/base/cs_base.c:431
 #, c-format
-msgid "Theoretical maximum allocated memory:   %lu kB\n"
-msgstr "Mémoire dynamique instrumentée théorique : %lu ko\n"
+msgid "Theoretical maximum allocated memory:   %llu kB\n"
+msgstr "Mémoire dynamique instrumentée théorique : %llu ko\n"
 
 #: src/base/cs_base.c:441
 #, c-format
-msgid "Maximum program memory measure:         %lu kB\n"
-msgstr "Mémoire programme mesurée maximale:        %lu ko\n"
+msgid "Maximum program memory measure:         %llu kB\n"
+msgstr "Mémoire programme mesurée maximale:        %llu ko\n"
 
 #: src/base/cs_base.c:449
 #, c-format
-msgid "Current program memory measure:         %lu kB\n"
-msgstr "Mémoire programme mesurée courante:        %lu ko\n"
+msgid "Current program memory measure:         %llu kB\n"
+msgstr "Mémoire programme mesurée courante:        %llu ko\n"
 
 #: src/base/cs_base.c:511
 msgid ""
@@ -317,16 +318,16 @@ msgstr "                             maximum local : %12.3f %co  (rang %d)\n"
 msgid ""
 "\n"
 "  Fortran work arrays memory use:\n"
-"   %-12lu integers needed (maximum reached in %s)\n"
-"   %-12lu reals    needed (maximum reached in %s)\n"
+"   %-12llu integers needed (maximum reached in %s)\n"
+"   %-12llu reals    needed (maximum reached in %s)\n"
 "\n"
 "   Local maximum work memory requested %12.3f %cb\n"
 "                                  used %12.3f %cb\n"
 msgstr ""
 "\n"
 "  Utilisation des tableaux de travail Fortran :\n"
-"   %-12lu entiers nécessaires (maximum atteint dans %s)\n"
-"   %-12lu réels   nécessaires (maximum atteint dans %s)\n"
+"   %-12llu entiers nécessaires (maximum atteint dans %s)\n"
+"   %-12llu réels   nécessaires (maximum atteint dans %s)\n"
 "\n"
 "   Mémoire de travail maximale locale demandée %12.3f %co\n"
 "                                      utilisée %12.3f %co\n"
@@ -804,13 +805,13 @@ msgstr ""
 msgid ""
 "\n"
 "First face with boundary condition definition error\n"
-"  (out of %lu)\n"
+"  (out of %llu)\n"
 "  has boundary condition type %d, center (%g, %g, %g)\n"
 "\n"
 msgstr ""
 "\n"
 "Première face avec une mauvaise définition de conditions aux limites\n"
-"  (sur %lu)\n"
+"  (sur %llu)\n"
 "  a une condition aux limites de type %d, un centre (%g, %g, %g)\n"
 "\n"
 
@@ -952,7 +953,7 @@ msgstr ""
 "     rang racine : %d ; nb_rangs : %d\n"
 "\n"
 
-#: src/base/cs_ext_neighborhood.c:1005
+#: src/base/cs_ext_neighborhood.c:1007
 msgid ""
 "\n"
 "WARNING\n"
@@ -970,24 +971,24 @@ msgstr ""
 "(maillage 1D). Vérifiez que c'est bien votre cas, sinon\n"
 "contactez le support.\n"
 
-#: src/base/cs_ext_neighborhood.c:1162
+#: src/base/cs_ext_neighborhood.c:1163
 #, c-format
 msgid ""
 "\n"
 " Extended neighborhood reduced by non-orthogonality\n"
 " --------------------------------------------------\n"
 "\n"
-" Size of complete cell-cell connectivity: %12lu\n"
-" Size of filtered cell-cell conectivity:  %12lu\n"
-" %lu connections removed, for a ratio of %4.2g %% used\n"
+" Size of complete cell-cell connectivity: %12llu\n"
+" Size of filtered cell-cell conectivity:  %12llu\n"
+" %llu connections removed, for a ratio of %4.2g %% used\n"
 msgstr ""
 "\n"
 " Limitation du voisinage étendu par non-orthogonalité\n"
 " ----------------------------------------------------\n"
 "\n"
-" Taille de la connectivité cellules-cellules complète : %12lu\n"
-" Taille de la connectivité cellules-cellules filtrée :  %12lu\n"
-" %lu connexions supprimées, soit un ratio de %4.2g %% utilisées\n"
+" Taille de la connectivité cellules-cellules complète : %12llu\n"
+" Taille de la connectivité cellules-cellules filtrée :  %12llu\n"
+" %llu connexions supprimées, soit un ratio de %4.2g %% utilisées\n"
 
 #: src/base/cs_gradient.c:598
 #, c-format
@@ -1012,16 +1013,16 @@ msgstr ""
 msgid "Invalid number of coal-> dp_FCP: %i xml: %i\n"
 msgstr ""
 
-#: src/base/cs_gui_boundary_conditions.c:577 src/base/cs_gui.c:4809
-#: src/base/cs_gui.c:4857 src/base/cs_gui.c:4905 src/base/cs_gui.c:4953
-#: src/base/cs_gui.c:5027 src/base/cs_gui_mobile_mesh.c:281
+#: src/base/cs_gui_boundary_conditions.c:577 src/base/cs_gui.c:4812
+#: src/base/cs_gui.c:4860 src/base/cs_gui.c:4908 src/base/cs_gui.c:4956
+#: src/base/cs_gui.c:5030 src/base/cs_gui_mobile_mesh.c:281
 #, c-format
 msgid "Error: can not interprete expression: %s\n"
 msgstr ""
 
-#: src/base/cs_gui_boundary_conditions.c:583 src/base/cs_gui.c:4813
-#: src/base/cs_gui.c:4861 src/base/cs_gui.c:4909 src/base/cs_gui.c:4957
-#: src/base/cs_gui.c:5031 src/base/cs_gui_mobile_mesh.c:291
+#: src/base/cs_gui_boundary_conditions.c:583 src/base/cs_gui.c:4816
+#: src/base/cs_gui.c:4864 src/base/cs_gui.c:4912 src/base/cs_gui.c:4960
+#: src/base/cs_gui.c:5034 src/base/cs_gui_mobile_mesh.c:291
 #, c-format
 msgid "Error: can not find the required symbol: %s\n"
 msgstr ""
@@ -1165,49 +1166,49 @@ msgid ""
 " label not found"
 msgstr ""
 
-#: src/base/cs_gui.c:2630
+#: src/base/cs_gui.c:2633
 #, c-format
 msgid "Invalid turbulence model: %s.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:2740
+#: src/base/cs_gui.c:2743
 #, c-format
 msgid "Scalar: %i and its variance: %i are the same.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3102
+#: src/base/cs_gui.c:3105
 #, c-format
 msgid ""
 "The kernel variables number %i and the calculated one by the GUI %i are not "
 "the same.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3550
+#: src/base/cs_gui.c:3553
 msgid "Specific heat value is zero or not found in the xml file.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3571
+#: src/base/cs_gui.c:3574
 msgid "mass molar value is zero or not found in the xml file.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3579
+#: src/base/cs_gui.c:3582
 msgid "Density value is zero or not found in the xml file.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3835 src/base/cs_gui_radiative_transfer.c:744
+#: src/base/cs_gui.c:3838 src/base/cs_gui_radiative_transfer.c:744
 #: src/base/cs_gui_specific_physics.c:532
 #, c-format
 msgid "number of properties is not correct: %i instead of: %i\n"
 msgstr ""
 
-#: src/base/cs_gui.c:4212 src/base/cs_gui_particles.c:782
+#: src/base/cs_gui.c:4215 src/base/cs_gui_particles.c:782
 #: src/base/cs_gui_particles.c:788 src/base/cs_gui_particles.c:794
 #: src/base/cs_gui_radiative_transfer.c:845
 #, c-format
 msgid "Name of variable %i was never set.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:4293 src/base/cs_selector.c:315
+#: src/base/cs_gui.c:4296 src/base/cs_selector.c:315
 #, c-format
 msgid ""
 "The group or attribute \"%s\" in the selection\n"
@@ -1220,7 +1221,7 @@ msgstr ""
 "\"%s\"\n"
 " ne correspond à aucune cellule.\n"
 
-#: src/base/cs_gui.c:5211 src/base/cs_gui_util.c:159
+#: src/base/cs_gui.c:5214 src/base/cs_gui_util.c:159
 #, c-format
 msgid "Unable to open the file: %s\n"
 msgstr ""
@@ -1482,10 +1483,10 @@ msgstr ""
 #, c-format
 msgid ""
 "    section name:           \"%s\"\n"
-"    number of elements:     %lu\n"
+"    number of elements:     %llu\n"
 msgstr ""
 "    nom de la rubrique :    \"%s\"\n"
-"    nombre d'éléments :     %lu\n"
+"    nombre d'éléments :     %llu\n"
 
 #: src/base/cs_io.c:1194 src/base/cs_syr3_comm.c:849
 #, c-format
@@ -1506,31 +1507,31 @@ msgstr "    %d premiers et derniers éléments%s :\n"
 msgid "    elements%s:\n"
 msgstr "    éléments%s :\n"
 
-#: src/base/cs_io.c:1812 src/base/cs_io.c:1989 src/base/cs_io.c:3001
-#: src/base/cs_io.c:3088
+#: src/base/cs_io.c:1812 src/base/cs_io.c:1989 src/base/cs_io.c:3006
+#: src/base/cs_io.c:3093
 #, c-format
-msgid "Error writing %lu bytes to file \"%s\"."
-msgstr "Erreur à l'écriture de %lu octets dans le fichier \"%s\"."
+msgid "Error writing %llu bytes to file \"%s\"."
+msgstr "Erreur à l'écriture de %llu octets dans le fichier \"%s\"."
 
 #: src/base/cs_io.c:2012
 #, c-format
 msgid ""
-" %lu indexed records:\n"
+" %llu indexed records:\n"
 "   (name, n_vals, location_id, index_id, n_loc_vals, type, embed, file_id, "
 "offset)\n"
 "\n"
 msgstr ""
-" %lu sections indexées :\n"
+" %llu sections indexées :\n"
 "   (nom, n_vals, id_support, id_index, n_vals_loc, type, inclus, id_fichier, "
 "position)\n"
 "\n"
 
-#: src/base/cs_io.c:2025
+#: src/base/cs_io.c:2026
 #, c-format
-msgid " %40s %10lu %2u %2u %2u %6s %c %2u %ld\n"
+msgid " %40s %10llu %2u %2u %2u %6s %c %2u %ld\n"
 msgstr ""
 
-#: src/base/cs_io.c:2034
+#: src/base/cs_io.c:2035
 #, c-format
 msgid ""
 "\n"
@@ -1539,12 +1540,12 @@ msgstr ""
 "\n"
 " %u fichier(s) associé(s):\n"
 
-#: src/base/cs_io.c:2037
+#: src/base/cs_io.c:2038
 #, c-format
 msgid "  \"%s\"\n"
 msgstr "  \"%s\"\n"
 
-#: src/base/cs_io.c:2087 src/base/cs_io.c:2143
+#: src/base/cs_io.c:2088 src/base/cs_io.c:2144
 #, c-format
 msgid ""
 "\n"
@@ -1553,7 +1554,7 @@ msgstr ""
 "\n"
 " Lecture du fichier :  %s\n"
 
-#: src/base/cs_io.c:2089
+#: src/base/cs_io.c:2090
 #, c-format
 msgid ""
 "\n"
@@ -1562,17 +1563,17 @@ msgstr ""
 "\n"
 " Écriture du fichier : %s\n"
 
-#: src/base/cs_io.c:2200
+#: src/base/cs_io.c:2201
 #, c-format
 msgid " Finished reading:    %s\n"
 msgstr " Fin de la lecture :  %s\n"
 
-#: src/base/cs_io.c:2203
+#: src/base/cs_io.c:2204
 #, c-format
 msgid " Finished writing:    %s\n"
 msgstr " Fin de l'écriture :  %s\n"
 
-#: src/base/cs_io.c:2469
+#: src/base/cs_io.c:2470
 #, c-format
 msgid ""
 "Type \"%s\" is not known\n"
@@ -1581,7 +1582,7 @@ msgstr ""
 "Type \"%s\" inconnu\n"
 "Types connus : \"c \", \"i4\", \"i8\", \"u4\", \"u8\", \"r4\", \"r8\"."
 
-#: src/base/cs_io.c:2525
+#: src/base/cs_io.c:2526
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
@@ -1590,7 +1591,7 @@ msgstr ""
 "Erreur à la lecture du fichier : \"%s\".\n"
 "Le type de données \"%s\" n'est pas reconnu."
 
-#: src/base/cs_io.c:2634
+#: src/base/cs_io.c:2639
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
@@ -1602,7 +1603,7 @@ msgstr ""
 "\"%s\" est un entier signé\n"
 "et n'est pas convertible à partir du type lu : \"%s\"."
 
-#: src/base/cs_io.c:2669
+#: src/base/cs_io.c:2674
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
@@ -1614,7 +1615,7 @@ msgstr ""
 "\"%s\" est un entier non signé\n"
 "et n'est pas convertible à partir du type lu : \"%s\"."
 
-#: src/base/cs_io.c:2700
+#: src/base/cs_io.c:2705
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
@@ -1625,29 +1626,29 @@ msgstr ""
 "Le type attendu pour la section : \"%s\"\n"
 "est \"r4\" ou \"r8\" (réel), et non \"%s\"."
 
-#: src/base/cs_io.c:2936
+#: src/base/cs_io.c:2941
 #, c-format
 msgid ""
 "    first element for next rank:\n"
-"    %10lu : %12d\n"
+"    %10llu : %12llu\n"
 msgstr ""
 "    premier élement rang suivant :\n"
-"    %10lu : %12d\n"
+"    %10llu : %12llu\n"
 
-#: src/base/cs_io.c:3106
+#: src/base/cs_io.c:3111
 #, c-format
 msgid "  I/O mode:          %s\n"
 msgstr "  mode E/S :          %s\n"
 
-#: src/base/cs_io.c:3112
+#: src/base/cs_io.c:3117
 msgid "MPI-IO, explicit offsets"
 msgstr "MPI-IO, positions explicites"
 
-#: src/base/cs_io.c:3116
+#: src/base/cs_io.c:3121
 msgid "MPI-IO, individual file pointers"
 msgstr "MPI-IO, pointeurs de fichiers individuels"
 
-#: src/base/cs_io.c:3120
+#: src/base/cs_io.c:3125
 msgid ""
 "serial IO\n"
 "\n"
@@ -1655,7 +1656,7 @@ msgstr ""
 "ES série\n"
 "\n"
 
-#: src/base/cs_io.c:3169
+#: src/base/cs_io.c:3174
 msgid ""
 "\n"
 "\n"
@@ -1667,25 +1668,25 @@ msgstr ""
 " contenu du fichier :\n"
 "\n"
 
-#: src/base/cs_io.c:3172
+#: src/base/cs_io.c:3177
 #, c-format
 msgid "  file: %s\n"
 msgstr "  fichier : %s\n"
 
-#: src/base/cs_io.c:3174
+#: src/base/cs_io.c:3179
 #, c-format
 msgid "  contents: \"%s\"\n"
 msgstr "  contenu : \"%s\"\n"
 
-#: src/base/cs_io.c:3176
+#: src/base/cs_io.c:3181
 msgid "  mode: CS_IO_MODE_READ\n"
 msgstr "  mode : CS_IO_MODE_READ\n"
 
-#: src/base/cs_io.c:3178
+#: src/base/cs_io.c:3183
 msgid "  mode: CS_IO_MODE_WRITE\n"
 msgstr "  mode : CS_IO_MODE_WRITE\n"
 
-#: src/base/cs_io.c:3180
+#: src/base/cs_io.c:3185
 #, c-format
 msgid ""
 "  default header size: %lu\n"
@@ -1700,37 +1701,26 @@ msgstr ""
 "  niveau d'impression :         %ld\n"
 "\n"
 
-#: src/base/cs_join.c:440
-#, c-format
-msgid "  Tolerance computation mode (%d) is not defined\n"
-msgstr ""
-
-#: src/base/cs_join.c:646
-#, c-format
-msgid ""
-"Incompatible value for the \"fraction\" parameter.\n"
-"Value must be lower than 1.0 or greater than 0.0\n"
-"The current value is : %f\n"
-msgstr ""
-
-#: src/base/cs_join.c:731
-#, c-format
+#: src/base/cs_join.c:209
 msgid ""
-"Incompatible value for the \"vertex tolerance\" parameter\n"
-"Value must be lower than DBL_MAX and current value is : %f (global "
-"numbering : %u)\n"
+"\n"
+"  Element selection successfully done.\n"
 msgstr ""
 
-#: src/base/cs_join.c:758
+#: src/base/cs_join.c:288
 #, c-format
 msgid ""
-"  Global number of selected vertices: %11lu\n"
 "\n"
+"  Sorting possible intersections between faces:\n"
+"      wall clock time:            %10.3g\n"
+"      CPU time:                   %10.3g\n"
 msgstr ""
-"  Nombre global de sommets sélectionnés : %11lu\n"
 "\n"
+"  Tri des intersection possibles entre faces:\n"
+"      temps écoulé :              %10.3g\n"
+"      temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:793
+#: src/base/cs_join.c:417
 #, c-format
 msgid ""
 "\n"
@@ -1743,20 +1733,7 @@ msgstr ""
 "        temps écoulé :              %10.3g\n"
 "        temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:879
-#, c-format
-msgid ""
-"\n"
-"  Sorting possible intersections between faces:\n"
-"      wall clock time:            %10.3g\n"
-"      CPU time:                   %10.3g\n"
-msgstr ""
-"\n"
-"  Tri des intersection possibles entre faces:\n"
-"      temps écoulé :              %10.3g\n"
-"      temps CPU :                 %10.3g\n"
-
-#: src/base/cs_join.c:1030
+#: src/base/cs_join.c:459
 #, c-format
 msgid ""
 "\n"
@@ -1769,7 +1746,7 @@ msgstr ""
 "      temps écoulé :              %10.3g\n"
 "      temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1138
+#: src/base/cs_join.c:566
 msgid ""
 "\n"
 "  Joining operation is conforming.\n"
@@ -1777,7 +1754,7 @@ msgstr ""
 "\n"
 "  L'opération de recollement est conforme.\n"
 
-#: src/base/cs_join.c:1148
+#: src/base/cs_join.c:576
 msgid ""
 "\n"
 "  Joining operation is non-conforming.\n"
@@ -1785,7 +1762,7 @@ msgstr ""
 "\n"
 "  L'opération de recollement est non-conforme.\n"
 
-#: src/base/cs_join.c:1220
+#: src/base/cs_join.c:649
 #, c-format
 msgid ""
 "\n"
@@ -1798,7 +1775,7 @@ msgstr ""
 "    temps écoulé :              %10.3g\n"
 "    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1356
+#: src/base/cs_join.c:1089
 #, c-format
 msgid ""
 "\n"
@@ -1811,7 +1788,7 @@ msgstr ""
 "    temps écoulé :              %10.3g\n"
 "    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1431
+#: src/base/cs_join.c:1238
 #, c-format
 msgid ""
 "\n"
@@ -1824,82 +1801,26 @@ msgstr ""
 "    temps écoulé :              %10.3g\n"
 "    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1594
+#: src/base/cs_join.c:1378
 #, c-format
 msgid "  Join number %d is not defined.\n"
 msgstr "  Le recollement numéro %d n'est pas défini.\n"
 
-#: src/base/cs_join.c:1641
+#: src/base/cs_join.c:1421 src/base/cs_join_perio.c:220
 #, c-format
 msgid ""
 "Mesh joining:  Forbidden value for the fraction parameter.\n"
 "  It must be between [0.0, 1.0[ and is here: %f\n"
 msgstr ""
 
-#: src/base/cs_join.c:1648
+#: src/base/cs_join.c:1428 src/base/cs_join_perio.c:227
 #, c-format
 msgid ""
 "Mesh joining:  Forbidden value for the plane parameter.\n"
 "  It must be between [0, 90] and is here: %f\n"
 msgstr ""
 
-#: src/base/cs_join.c:1707
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tml parameter.\n"
-"  It must be between > 0 and is here: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1718
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tmb parameter.\n"
-"  It must be between > 0 and is here: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1729
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tmr parameter.\n"
-"  It must be between > 0.0 and is here: %f\n"
-msgstr ""
-
-#: src/base/cs_join.c:1744
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the merge tolerance factor.\n"
-"  It must be positive or nul and not: %f\n"
-msgstr ""
-
-#: src/base/cs_join.c:1754
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the max. number of tolerance breaks.\n"
-"  It must be between >= 0 and not: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1771
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tcm parameter.\n"
-"  It must be between 1, 2 or 11, 12 and here is: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1781
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for icm parameter.\n"
-"  It must be 1 or 2 and here is: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1791
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the maxsf parameter.\n"
-"  It must be between > 0 and here is: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1839
+#: src/base/cs_join.c:1486
 #, c-format
 msgid ""
 "\n"
@@ -1912,12 +1833,19 @@ msgstr ""
 "  Recollement numéro %d :\n"
 "\n"
 
-#: src/base/cs_join.c:1841
+#: src/base/cs_join.c:1490
+#, c-format
+msgid ""
+"\n"
+"  Joining for periodicity: %d\n"
+msgstr ""
+
+#: src/base/cs_join.c:1492
 #, c-format
 msgid "  Selection criteria: \"%s\"\n"
 msgstr "  Critère de sélection : \"%s\"\n"
 
-#: src/base/cs_join.c:1844
+#: src/base/cs_join.c:1495
 #, c-format
 msgid ""
 "\n"
@@ -1932,10 +1860,11 @@ msgstr ""
 "    Angle maximum entre plans de faces recollées :      %8.5f\n"
 "\n"
 
-#: src/base/cs_join.c:1851
+#: src/base/cs_join.c:1501
 #, c-format
 msgid ""
-"  Advanced join parameters:\n"
+"  Advanced joining parameters:\n"
+"    Verbosity level:                          %8d\n"
 "    Deepest level reachable in tree building: %8d\n"
 "    Max boxes by leaf:                        %8d\n"
 "    Max ratio of linked boxes / init. boxes:  %8.5f\n"
@@ -1948,24 +1877,18 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/base/cs_join.c:1870
+#: src/base/cs_join.c:1522
 msgid " Before joining"
 msgstr " Avant recollement"
 
-#: src/base/cs_join.c:1919
-msgid ""
-"\n"
-"  Element selection successfully done.\n"
-msgstr ""
-
-#: src/base/cs_join.c:1962
+#: src/base/cs_join.c:1559
 #, c-format
 msgid ""
 "\n"
 "  Number of faces to treat locally: %10d\n"
 msgstr ""
 
-#: src/base/cs_join.c:2036
+#: src/base/cs_join.c:1641
 msgid ""
 "\n"
 "Stop joining algorithm: no face selected...\n"
@@ -1973,7 +1896,11 @@ msgstr ""
 "\n"
 "Arrêt du recollement: aucune face sélectionnée...\n"
 
-#: src/base/cs_join.c:2045
+#: src/base/cs_join.c:1649
+msgid " After joining"
+msgstr " Après recollement"
+
+#: src/base/cs_join.c:1656
 #, c-format
 msgid ""
 "\n"
@@ -1986,11 +1913,7 @@ msgstr ""
 "    temps écoulé :              %10.3g\n"
 "    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:2074
-msgid " After joining"
-msgstr " Après recollement"
-
-#: src/base/cs_join.c:2092
+#: src/base/cs_join.c:1684
 #, c-format
 msgid ""
 "\n"
@@ -2009,7 +1932,7 @@ msgstr ""
 "    temps CPU :                 %10.3g\n"
 "\n"
 
-#: src/base/cs_join_intersect.c:399
+#: src/base/cs_join_intersect.c:400
 #, c-format
 msgid ""
 "\n"
@@ -2019,19 +1942,19 @@ msgid ""
 "  Intersection found for curv. abs. %f (e1) - %f (e2) will be ignored.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:414
+#: src/base/cs_join_intersect.c:415
 #, c-format
 msgid ""
 " Failure for edge 1:  Distance [v_inter1, v_inter2]: %e > v_inter1.tol: %e\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:418
+#: src/base/cs_join_intersect.c:419
 #, c-format
 msgid ""
 " Failure for edge 2:  Distance [v_inter1, v_inter2]: %e > v_inter2.tol: %e\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:2177
+#: src/base/cs_join_intersect.c:2186
 #, c-format
 msgid ""
 "  Determination of possible face intersections:\n"
@@ -2042,7 +1965,7 @@ msgstr ""
 "\n"
 "    répartition de l'arbre de boîtes englobantes : %dD\n"
 
-#: src/base/cs_join_intersect.c:2184
+#: src/base/cs_join_intersect.c:2193
 #, c-format
 msgid ""
 "                                   rank mean      minimum      maximum\n"
@@ -2067,7 +1990,7 @@ msgstr ""
 "      structure intermédiaire :       %10lu | %10lu | %10lu\n"
 "\n"
 
-#: src/base/cs_join_intersect.c:2207
+#: src/base/cs_join_intersect.c:2216
 #, c-format
 msgid ""
 "    depth:                        %10d\n"
@@ -2090,7 +2013,7 @@ msgstr ""
 "      structure intermédiaire :       %10lu\n"
 "\n"
 
-#: src/base/cs_join_intersect.c:2219
+#: src/base/cs_join_intersect.c:2228
 #, c-format
 msgid ""
 "    Associated times:           construction        query\n"
@@ -2099,7 +2022,7 @@ msgstr ""
 "    Temsp associés:             construction        requête\n"
 "      wall clock time:            %10.3g   %10.3g\n"
 
-#: src/base/cs_join_intersect.c:2236
+#: src/base/cs_join_intersect.c:2245
 #, c-format
 msgid ""
 "      Min local CPU time:         %10.3g   %10.3g\n"
@@ -2108,12 +2031,12 @@ msgstr ""
 "      temps CPU local min :       %10.3g   %10.3g\n"
 "      temps CPU local max :       %10.3g   %10.3g\n"
 
-#: src/base/cs_join_intersect.c:2244
+#: src/base/cs_join_intersect.c:2253
 #, c-format
 msgid "      CPU time:                   %10.3g   %10.3g\n"
 msgstr "      temps CPU :                 %10.3g   %10.3g\n"
 
-#: src/base/cs_join_intersect.c:2515
+#: src/base/cs_join_intersect.c:2524
 #, c-format
 msgid ""
 "\n"
@@ -2122,7 +2045,7 @@ msgid ""
 "   Vertex %d (%u) of abscissa: %f is before vertex %d (%u) of abscissa: %f\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:2526
+#: src/base/cs_join_intersect.c:2535
 #, c-format
 msgid ""
 "\n"
@@ -2133,38 +2056,43 @@ msgid ""
 "  Vertex %d appears twice.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:2752
+#: src/base/cs_join_intersect.c:2665 src/base/cs_join_intersect.c:2682
+msgid "  Vertex number out of bounds.\n"
+msgstr ""
+
+#: src/base/cs_join_intersect.c:2782
 #, c-format
 msgid ""
 "\n"
-"  Equivalences broken for %lu edges.\n"
+"  Equivalences broken for %llu edges.\n"
 msgstr ""
 "\n"
-"  Equivalences cassées pour %lu éléments.\n"
+"  Equivalences cassées pour %llu éléments.\n"
 
-#: src/base/cs_join_intersect.c:2758
+#: src/base/cs_join_intersect.c:2788
 #, c-format
 msgid ""
 "\n"
-"  Max. number of equiv. breaks: %lu\n"
+"  Max. number of equiv. breaks: %llu\n"
 msgstr ""
 "\n"
-"  Nombre max d'équivalences cassées : %lu\n"
+"  Nombre max d'équivalences cassées : %llu\n"
 
-#: src/base/cs_join_intersect.c:3377
+#: src/base/cs_join_intersect.c:3409
 #, c-format
 msgid ""
 "  The received edge global number (%u) is unknown on the current rank.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:3489
+#: src/base/cs_join_intersect.c:3520
 #, c-format
 msgid ""
 "\n"
-"  Add %d new vertices in the %s mesh definition.\n"
+"  Add %d new vertices in the %s mesh definition during update of the edge "
+"definition.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:3670
+#: src/base/cs_join_intersect.c:3704
 #, c-format
 msgid ""
 "\n"
@@ -2177,14 +2105,14 @@ msgstr ""
 "    Intersections sommet-sommet :     %12lu\n"
 "    Autres intersections :            %12lu\n"
 
-#: src/base/cs_join_intersect.c:3677
+#: src/base/cs_join_intersect.c:3711
 #, c-format
 msgid ""
 "\n"
 "  Local number of edge-edge intersection warnings:%9d\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:3679
+#: src/base/cs_join_intersect.c:3713
 #, c-format
 msgid ""
 "\n"
@@ -2193,7 +2121,7 @@ msgstr ""
 "\n"
 "  Nombre local d'équivalences entre sommets : %9d\n"
 
-#: src/base/cs_join_intersect.c:3689
+#: src/base/cs_join_intersect.c:3723
 #, c-format
 msgid ""
 "\n"
@@ -2206,7 +2134,7 @@ msgstr ""
 "    temps écoulé :              %10.3g\n"
 "    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join_merge.c:352
+#: src/base/cs_join_merge.c:348
 #, c-format
 msgid ""
 "  The number of new vertices to create is not consistent.\n"
@@ -2215,7 +2143,7 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:582
+#: src/base/cs_join_merge.c:580
 #, c-format
 msgid ""
 "\n"
@@ -2225,7 +2153,7 @@ msgid ""
 "  Check the fraction parameter.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:687
+#: src/base/cs_join_merge.c:685
 #, c-format
 msgid ""
 "\n"
@@ -2235,28 +2163,28 @@ msgid ""
 "  Check the fraction parameter.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:980
+#: src/base/cs_join_merge.c:978
 #, c-format
 msgid ""
 "\n"
 "  Number of local iterations to converge on vertex equivalences: %3d\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:983
+#: src/base/cs_join_merge.c:981
 #, c-format
 msgid ""
 "  Number of global iterations to converge on vertex equivalences: %3d\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:1431
+#: src/base/cs_join_merge.c:1437
 #, c-format
 msgid ""
 "\n"
-"  Pre-merge for %lu global couple of elements.\n"
+"  Pre-merge for %llu global couple of elements.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:1435
+#: src/base/cs_join_merge.c:1441
 #, c-format
 msgid ""
 "\n"
@@ -2265,12 +2193,12 @@ msgstr ""
 "\n"
 "  Nombre local de pre-fusion: %d\n"
 
-#: src/base/cs_join_merge.c:1938
+#: src/base/cs_join_merge.c:1944
 #, c-format
 msgid " Number of tolerance reductions:  %4d\n"
 msgstr " Nombre de réductions de tolérance : %4d\n"
 
-#: src/base/cs_join_merge.c:2041
+#: src/base/cs_join_merge.c:2048
 msgid ""
 "\n"
 "  No need to merge vertices.\n"
@@ -2278,53 +2206,53 @@ msgstr ""
 "\n"
 "  Pas besoin de fusionner des sommets.\n"
 
-#: src/base/cs_join_merge.c:2045
+#: src/base/cs_join_merge.c:2052
 #, c-format
 msgid ""
 "\n"
-"  Max size of a merge set of vertices: %lu\n"
+"  Max size of a merge set of vertices: %llu\n"
 msgstr ""
 "\n"
-"  Taille max d'un ensemble de fusion de sommets : %lu\n"
+"  Taille max d'un ensemble de fusion de sommets : %llu\n"
 
-#: src/base/cs_join_merge.c:2113
+#: src/base/cs_join_merge.c:2120
 #, c-format
 msgid ""
 "\n"
 "  %3d loop(s) to get consistent subsets\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:2177
+#: src/base/cs_join_merge.c:2184
 #, c-format
 msgid ""
 "\n"
-"  Excessive transitivity for %lu set(s) of vertices.\n"
+"  Excessive transitivity for %llu set(s) of vertices.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:2183
+#: src/base/cs_join_merge.c:2190
 #, c-format
 msgid ""
 "\n"
-"  Max. number of iterations to solve transitivity excess: %lu\n"
+"  Max. number of iterations to solve transitivity excess: %llu\n"
 msgstr ""
 "\n"
-"  Nombre max d'itérations pour résoudre un excès de transitivité : %lu\n"
+"  Nombre max d'itérations pour résoudre un excès de transitivité : %llu\n"
 
-#: src/base/cs_join_merge.c:2633
+#: src/base/cs_join_merge.c:2637
 #, c-format
 msgid "  Number of sub-elements to add to edge definition: %8d\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:3052
+#: src/base/cs_join_merge.c:3056
 #, c-format
 msgid ""
 "\n"
-"  Global number of new vertices to create: %10lu\n"
+"  Global number of new vertices to create: %10llu\n"
 msgstr ""
 "\n"
-"  Nombre global de nouveaux sommets à créer : %10lu\n"
+"  Nombre global de nouveaux sommets à créer : %10llu\n"
 
-#: src/base/cs_join_merge.c:3161
+#: src/base/cs_join_merge.c:3166
 #, c-format
 msgid ""
 "  Inconsistent value found in cs_join_vertex_t struct.:\n"
@@ -2332,15 +2260,15 @@ msgid ""
 "      %u - [%7.4le, %7.4le, %7.4le] - %lg\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:3220
+#: src/base/cs_join_merge.c:3225
 #, c-format
 msgid ""
 "\n"
 "  Final number of equiv. between vertices; local: %9d\n"
-"                                          global: %9lu\n"
+"                                          global: %9llu\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:3308
+#: src/base/cs_join_merge.c:3313
 #, c-format
 msgid ""
 "\n"
@@ -2353,7 +2281,38 @@ msgstr ""
 "              temps écoulé :         %10.3g\n"
 "              temps CPU :            %10.3g\n"
 
-#: src/base/cs_join_mesh.c:351 src/base/cs_join_mesh.c:520
+#: src/base/cs_join_mesh.c:459
+#, c-format
+msgid "  Tolerance computation mode (%d) is not defined\n"
+msgstr ""
+
+#: src/base/cs_join_mesh.c:738
+#, c-format
+msgid ""
+"Incompatible value for the \"vertex tolerance\" item\n"
+"Value must be lower than DBL_MAX and current value is : %f (global "
+"numbering : %u)\n"
+msgstr ""
+
+#: src/base/cs_join_mesh.c:764
+#, c-format
+msgid ""
+"  Global number of selected vertices: %11llu\n"
+"\n"
+msgstr ""
+"  Nombre global de sommets sélectionnés : %11llu\n"
+"\n"
+
+#: src/base/cs_join_mesh.c:776
+#, c-format
+msgid ""
+"  Number of selected vertices: %11llu\n"
+"\n"
+msgstr ""
+"  Nombre global de sommets sélectionnés : %11llu\n"
+"\n"
+
+#: src/base/cs_join_mesh.c:998 src/base/cs_join_mesh.c:1166
 #, c-format
 msgid ""
 "  The simplified face has less than 3 vertices.\n"
@@ -2364,16 +2323,16 @@ msgstr ""
 "  Vérifier les paramètres de recollement.\n"
 "  Face %d (%u)\n"
 
-#: src/base/cs_join_mesh.c:367
+#: src/base/cs_join_mesh.c:1014
 #, c-format
 msgid ""
 "\n"
-"  Number of simplified faces: %lu\n"
+"  Number of simplified faces: %llu\n"
 msgstr ""
 "\n"
-"  Nombre de faces simplifiées : %lu\n"
+"  Nombre de faces simplifiées : %llu\n"
 
-#: src/base/cs_join_mesh.c:595
+#: src/base/cs_join_mesh.c:1240
 #, c-format
 msgid ""
 "\n"
@@ -2382,30 +2341,30 @@ msgid ""
 " Edge number: %d (%u) - (%d, %d) in old numbering.\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:1388
+#: src/base/cs_join_mesh.c:2054
 msgid ""
 "\n"
 "  Local min/max. tolerance:\n"
 "\n"
-"Glob. Num.  |  Tolerance  |        Coordinates\n"
+" Glob. Num. |  Tolerance  |              Coordinates\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:1412
+#: src/base/cs_join_mesh.c:2078
 msgid ""
 "\n"
 "  Global min/max. tolerance:\n"
 "\n"
-"Glob. Num.  |  Tolerance  |        Coordinates\n"
+" Glob. Num. |  Tolerance  |              Coordinates\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:2598
+#: src/base/cs_join_mesh.c:3259
 #, c-format
 msgid ""
 " The given vertex number: %d is not defined in the edge structure (edges-"
 ">vtx_idx).\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:2610
+#: src/base/cs_join_mesh.c:3271
 #, c-format
 msgid ""
 " The given couple of vertex numbers :\n"
@@ -2414,17 +2373,17 @@ msgid ""
 " is not defined in the edge structure.\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:2704
+#: src/base/cs_join_mesh.c:3365
 #, c-format
 msgid ""
-" Problem in mesh connectivity. Face: %lu\n"
+" Problem in mesh connectivity. Face: %llu\n"
 " Problem detected during connectivity update:\n"
 " The face is defined by less than 3 points (excessive merging has occured).\n"
 "\n"
 " Modify joining parameters to reduce merging (fraction & merge).\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3161 src/base/cs_join_mesh.c:3274
+#: src/base/cs_join_mesh.c:3822 src/base/cs_join_mesh.c:3935
 #, c-format
 msgid ""
 "\n"
@@ -2432,7 +2391,7 @@ msgid ""
 "  -- Dump a cs_join_mesh_t structure: (%p) --\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3166 src/base/cs_join_mesh.c:3279
+#: src/base/cs_join_mesh.c:3827 src/base/cs_join_mesh.c:3940
 #, c-format
 msgid ""
 "\n"
@@ -2440,29 +2399,29 @@ msgid ""
 "  -- Dump a cs_join_mesh_t structure: %s (%p) --\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3168
+#: src/base/cs_join_mesh.c:3829
 #, c-format
 msgid ""
 "\n"
 " mesh->n_faces:       %9d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3169 src/base/cs_join_mesh.c:3282
+#: src/base/cs_join_mesh.c:3830 src/base/cs_join_mesh.c:3943
 #, c-format
 msgid ""
 " mesh->n_g_faces:   %11u\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3178
+#: src/base/cs_join_mesh.c:3839
 #, c-format
 msgid ""
 "\n"
-" face_id: %5d gnum: %9u - n_vertices: %4d\n"
+" face_id: %5d gnum: %9u n_vertices: %4d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3201 src/base/cs_join_mesh.c:3219
-#: src/base/cs_join_mesh.c:3314 src/base/cs_join_mesh.c:3333
+#: src/base/cs_join_mesh.c:3862 src/base/cs_join_mesh.c:3880
+#: src/base/cs_join_mesh.c:3996
 #, c-format
 msgid ""
 "  Incoherency found in the current mesh definition\n"
@@ -2470,7 +2429,7 @@ msgid ""
 "  Vertices: local (%d, %d), global (%u, %u) are defined twice\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3235 src/base/cs_join_mesh.c:3349
+#: src/base/cs_join_mesh.c:3896 src/base/cs_join_mesh.c:4012
 #, c-format
 msgid ""
 "\n"
@@ -2481,60 +2440,125 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3243 src/base/cs_join_mesh.c:3357
+#: src/base/cs_join_mesh.c:3904 src/base/cs_join_mesh.c:4020
 #, c-format
 msgid ""
 " Local Num | Global Num |  Tolerance  |        Coordinates\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3281
+#: src/base/cs_join_mesh.c:3942
 #, c-format
 msgid ""
 "\n"
 " mesh->n_faces:     %11d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3291
+#: src/base/cs_join_mesh.c:3952
 #, c-format
 msgid ""
 "\n"
-" face_id: %9d gnum: %10u - n_vertices : %4d\n"
+" face_id: %9d gnum: %10llu n_vertices : %4d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3387
+#: src/base/cs_join_mesh.c:3976
+#, c-format
+msgid ""
+"  Incoherency found in the current mesh definition\n"
+"  Face number: %d (global: %llu)\n"
+"  Vertices: local (%d, %d), global (%llu, %llu) are defined twice\n"
+msgstr ""
+
+#: src/base/cs_join_mesh.c:4050
 msgid ""
 "\n"
 "  Edge connectivity used in the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3388
+#: src/base/cs_join_mesh.c:4051
 #, c-format
 msgid "  Number of edges:      %8d\n"
 msgstr "  Nombre d'arêtes :     %8d\n"
 
-#: src/base/cs_join_mesh.c:3389
+#: src/base/cs_join_mesh.c:4052
 #, c-format
 msgid "  Number of vertices:   %8d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3398
+#: src/base/cs_join_mesh.c:4061
 #, c-format
-msgid "  Edge %6d  (%7u) <Vertex> [%7u %7u]\n"
+msgid "  Edge %6d  (%8u) <Vertex> [%8u %8u]\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3425
+#: src/base/cs_join_mesh.c:4088
 msgid ""
 "\n"
 "  Vertex -> Vertex connectivity :\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3432
+#: src/base/cs_join_mesh.c:4095
 #, c-format
 msgid "  Vertex %6d (%7u) - %3d - "
 msgstr ""
 
+#: src/base/cs_join_perio.c:234
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the periodicity number.\n"
+"  It must be between > 0 and is here: %d\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:529
+#, c-format
+msgid ""
+"\n"
+"  Delete %d interior periodic faces locally\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:651
+#, c-format
+msgid "  Adding periodicity %d (translation [%10.4e, %10.4e, %10.4e]).\n"
+msgstr "  Ajout de la périodicité %d (translation [%10.4e, %10.4e, %10.4e]).\n"
+
+#: src/base/cs_join_perio.c:726
+#, c-format
+msgid "  Adding periodicity %d (rotation).\n"
+msgstr "  Ajout de la périodicité %d (rotation).\n"
+
+#: src/base/cs_join_perio.c:822
+#, c-format
+msgid "  Adding periodicity %d (general formulation).\n"
+msgstr "  Ajout de la périodicité %d (formulation générale).\n"
+
+#: src/base/cs_join_perio.c:891
+#, c-format
+msgid ""
+" Periodicity number %d is not defined\n"
+" %d periodicities are defined\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:1218
+#, c-format
+msgid ""
+"  Apply periodicity to the local join mesh structure\n"
+"  New number of faces to treat locally: %8d\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:1231 src/base/cs_join_util.c:2441
+msgid ""
+"\n"
+"  Selected faces for the joining operation:\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:1521
+#, c-format
+msgid ""
+"  Vertex state (%d) is not consistent.\n"
+"  Can not apply changes from periodic faces to original face.\n"
+"  Check your periodicity parameters.\n"
+msgstr ""
+
 #: src/base/cs_join_post.c:238
 msgid ""
 " Size of \"int\" is not 4 or 8 bytes.\n"
@@ -2549,32 +2573,47 @@ msgstr ""
 msgid "VtxTolerance"
 msgstr ""
 
-#: src/base/cs_join_set.c:961
+#: src/base/cs_join_set.c:1106
 #, c-format
 msgid ""
 "  Fail to build an inverted cs_join_gset_t structure.\n"
 "  Cannot find %u in element list.\n"
 msgstr ""
 
-#: src/base/cs_join_set.c:1832
+#: src/base/cs_join_set.c:2409
 #, c-format
 msgid " Unexpected type (%s) to display in the current dump.\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:872
+#: src/base/cs_join_split.c:843
 msgid ""
 "  face splitting with face -> face connectivity is not yet implemented\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1032
+#: src/base/cs_join_split.c:1037
 #, c-format
 msgid ""
 " Joining operation : split face %d\n"
-" Problem in the connectivity. Could not find a connection with the vertex %"
-"d\n"
+" Problem in the connectivity. Could not find a connection with the vertex "
+"%d\n"
+msgstr ""
+
+#: src/base/cs_join_split.c:1195
+#, c-format
+msgid " Warning: open cycle for global face %u\n"
+msgstr ""
+
+#: src/base/cs_join_split.c:1236
+#, c-format
+msgid " Warning: global face %u scanned twice\n"
+msgstr ""
+
+#: src/base/cs_join_split.c:1323
+#, c-format
+msgid " Warning: loop limit reached for global face %u\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1422
+#: src/base/cs_join_split.c:1603
 #, c-format
 msgid ""
 "\n"
@@ -2583,7 +2622,7 @@ msgstr ""
 "\n"
 "  Nombre global de faces après subdivision : %10u\n"
 
-#: src/base/cs_join_split.c:1474
+#: src/base/cs_join_split.c:1657
 #, c-format
 msgid ""
 " Inconsistent values between:\n"
@@ -2592,31 +2631,40 @@ msgid ""
 " These values should be equal.\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1781
+#: src/base/cs_join_split.c:1925
 #, c-format
-msgid "  Split face: %d with returned code: %d\n"
+msgid "  Split face %d >> returned code: %d\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1953
+#: src/base/cs_join_split.c:2087
 #, c-format
 msgid ""
 "\n"
 "  *** WARNING ***\n"
-"  Globally, %lu problem(s) found during the face splitting\n"
-"     %12lu  open cycles,\n"
-"     %12lu  edges traversed twice,\n"
-"     %12lu  faces split into more than max_subfaces (= %d)\n"
+"  Globally, %llu problem(s) found during the face splitting\n"
+"     %12llu  open cycles,\n"
+"     %12llu  edges traversed twice,\n"
+"     %12llu  faces split into more than max_subfaces (= %d)\n"
 "\n"
 "    => Eventually modify joining parameters\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:827
+#: src/base/cs_join_split.c:2119
+#, c-format
+msgid ""
+" At least one original face has been cut into more than %d subfaces\n"
+". You can increase this parameter in usjoin() or usperi() by setting the "
+"advanced parameter maxsf.\n"
+" Be careful. It may produce mesh with a poor quality.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:761
 #, c-format
 msgid "  Add %d new vertices from the single elements sync.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:1510
+#: src/base/cs_join_update.c:1536
 #, c-format
 msgid ""
 "  Cannot find the first corresponding vertex between the face connectivity "
@@ -2624,7 +2672,7 @@ msgid ""
 "  Current global face number: %u\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:1672
+#: src/base/cs_join_update.c:1698
 #, c-format
 msgid ""
 "  Face %d (%u): Edge with two different descriptions: (%d, %d) [%u, %u]\n"
@@ -2632,14 +2680,47 @@ msgid ""
 "  Impossible to continue the mesh update after the merge operation.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3576
+#: src/base/cs_join_update.c:2486
+#, c-format
+msgid "  Join Face connectivity %d (%u): "
+msgstr ""
+
+#: src/base/cs_join_update.c:2517
+msgid "  Cannot achieve to reorient the current joined face.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:3099 src/base/cs_join_update.c:3151
+#, c-format
+msgid ""
+"  Cannot achieve to reorient the current joined face with face %d (selected "
+"face).\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:3421
+#, c-format
+msgid ""
+" Incoherency found before interior face orientation checking.\n"
+" Join face %d (%u) and related faces [%d, %d]\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:3613
+#, c-format
+msgid "  Delete %d local vertices not used in mesh definition.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4068
 #, c-format
 msgid ""
 "  Warning: Face %d (%u) has more than two ancestors.\n"
 "  Old faces implied:"
 msgstr ""
 
-#: src/base/cs_join_update.c:3593
+#: src/base/cs_join_update.c:4087
+#, c-format
+msgid "  Warning: Face %d (%u) has no ancestor.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4098
 #, c-format
 msgid ""
 "\n"
@@ -2648,37 +2729,49 @@ msgid ""
 "    Number of border faces to add  : %9d\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3610
+#: src/base/cs_join_update.c:4125
+#, c-format
+msgid ""
+" There are %u undefined faces with no ancestor.\n"
+" Cannot continue the joining algorithm.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4133
 #, c-format
 msgid ""
 "\n"
 "  Global configuration after the joining operation:\n"
-"     Global number of border faces to add : %10u\n"
+"     Global number of border faces to add: %10llu\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3826
+#: src/base/cs_join_update.c:4141
+#, c-format
+msgid "     Global number of multiple border faces: %10llu\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4348
 #, c-format
 msgid "  Clean border face %d. New number of vertices: %d\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3848
+#: src/base/cs_join_update.c:4370
 #, c-format
 msgid ""
 "\n"
 "  Degenerate connectivity for %d final local boundary faces.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3887
+#: src/base/cs_join_update.c:4409
 #, c-format
 msgid "  Clean interior face %d. New number of vertices: %d\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3909
+#: src/base/cs_join_update.c:4431
 #, c-format
 msgid "  Degenerate connectivity for %d final local interior faces.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3959
+#: src/base/cs_join_update.c:4481
 #, c-format
 msgid ""
 "\n"
@@ -2687,36 +2780,112 @@ msgid ""
 "    Global number of cleaned border faces:   %8u\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2476
+#: src/base/cs_join_util.c:2074
 #, c-format
-msgid "  Number of boundary faces selected for joining: %10u\n"
+msgid ""
+"Mesh joining:  Forbidden value for the tml parameter.\n"
+"  It must be between > 0 and is here: %d\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2489
+#: src/base/cs_join_util.c:2085
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the tmb parameter.\n"
+"  It must be between > 0 and is here: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2096
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the tmr parameter.\n"
+"  It must be between > 0.0 and is here: %f\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2111
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the merge tolerance factor.\n"
+"  It must be positive or nul and not: %f\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2121
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the max. number of tolerance breaks.\n"
+"  It must be between >= 0 and not: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2138
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the tcm parameter.\n"
+"  It must be between 1, 2 or 11, 12 and here is: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2148
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for icm parameter.\n"
+"  It must be 1 or 2 and here is: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2158
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the maxsf parameter.\n"
+"  It must be between > 0 and here is: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2291
+#, c-format
+msgid "  Global number of boundary faces selected for joining: %10u\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2411
 msgid ""
 "\n"
-"  Selected faces for the joining operation:\n"
+"  Local information about selection structure:\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2412
+#, c-format
+msgid "    number of faces:               %8d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2414
+#, c-format
+msgid "    number of vertices:            %8d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2416
+#, c-format
+msgid "    number of adj. border faces:   %8d\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2508
+#: src/base/cs_join_util.c:2418
+#, c-format
+msgid "    number of adj. interior faces: %8d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2450
 msgid ""
 "\n"
 "  Select vertices for the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2556
+#: src/base/cs_join_util.c:2457
 msgid ""
 "\n"
 "  Contiguous border faces for the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2573
+#: src/base/cs_join_util.c:2464
 msgid ""
 "\n"
 "  Contiguous interior faces for the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2708 src/base/cs_join_util.c:2724
+#: src/base/cs_join_util.c:2682 src/base/cs_join_util.c:2698
 #, c-format
 msgid ""
 "  Inconsistent mesh definition. Cannot build edges.\n"
@@ -2743,7 +2912,7 @@ msgstr ""
 "avec une synchronisation de halo externe, précédée d'une sauvegarde\n"
 "et suivie d'une restoration du halo de rotation."
 
-#: src/base/cs_matrix.c:2009
+#: src/base/cs_matrix.c:2011
 msgid ""
 "Assigning non-symmetric matrix coefficients to a matrix\n"
 "in a symmetric CSR format."
@@ -2751,7 +2920,7 @@ msgstr ""
 "Affectation de coefficients matriciels non symétriques\n"
 "à une matrice en stockage CSR symmétrique."
 
-#: src/base/cs_matrix.c:2614
+#: src/base/cs_matrix.c:2616
 #, c-format
 msgid ""
 "Handling of matrixes in %s format\n"
@@ -2760,9 +2929,9 @@ msgstr ""
 "La gestion des matrices au format %s \n"
 "n'est pas encore opérationnelle."
 
-#: src/base/cs_matrix.c:2750 src/base/cs_matrix.c:2767
-#: src/base/cs_matrix.c:2793 src/base/cs_matrix.c:2813
-#: src/base/cs_matrix.c:2835
+#: src/base/cs_matrix.c:2752 src/base/cs_matrix.c:2769
+#: src/base/cs_matrix.c:2795 src/base/cs_matrix.c:2815
+#: src/base/cs_matrix.c:2837
 msgid "The matrix is not defined."
 msgstr "La matrice n'est pas définie."
 
@@ -2948,7 +3117,7 @@ msgstr ""
 "rangs :\n"
 "\n"
 
-#: src/base/cs_mesh.c:1061
+#: src/base/cs_mesh.c:1065
 #, c-format
 msgid ""
 "\n"
@@ -2963,7 +3132,7 @@ msgstr ""
 "                       Y : %14.7e %14.7e\n"
 "                       Z : %14.7e %14.7e\n"
 
-#: src/base/cs_mesh.c:1093
+#: src/base/cs_mesh.c:1097
 msgid ""
 "\n"
 " Global definition of the number of elements (cells, vertices, faces...)\n"
@@ -2971,7 +3140,7 @@ msgstr ""
 "\n"
 " Définition globale du nombre d'éléments (cellules, sommets, faces...)\n"
 
-#: src/base/cs_mesh.c:1179
+#: src/base/cs_mesh.c:1183
 msgid ""
 "\n"
 " Halo construction with extended neighborhood\n"
@@ -2983,11 +3152,11 @@ msgstr ""
 " ==========================================\n"
 "\n"
 
-#: src/base/cs_mesh.c:1186
+#: src/base/cs_mesh.c:1190
 msgid " Periodicities combination\n"
 msgstr " Composition des périodicités\n"
 
-#: src/base/cs_mesh.c:1195
+#: src/base/cs_mesh.c:1199
 msgid ""
 "\n"
 " Halo construction with standard neighborhood\n"
@@ -2999,27 +3168,27 @@ msgstr ""
 " ============================================\n"
 "\n"
 
-#: src/base/cs_mesh.c:1223
+#: src/base/cs_mesh.c:1227
 msgid " Definition of periodic couples\n"
 msgstr " Définition des couples périodiques\n"
 
-#: src/base/cs_mesh.c:1245
+#: src/base/cs_mesh.c:1249
 msgid " Interface creation\n"
 msgstr " Création de l'interface\n"
 
-#: src/base/cs_mesh.c:1278
+#: src/base/cs_mesh.c:1282
 msgid " Halo creation\n"
 msgstr " Création des halos\n"
 
-#: src/base/cs_mesh.c:1283
+#: src/base/cs_mesh.c:1287
 msgid " Halo definition\n"
 msgstr " Définition des halos\n"
 
-#: src/base/cs_mesh.c:1307
+#: src/base/cs_mesh.c:1311
 msgid " Extended neighborhood structures definition\n"
 msgstr " Définition des structures pour le voisinage étendu\n"
 
-#: src/base/cs_mesh.c:1334
+#: src/base/cs_mesh.c:1338
 #, c-format
 msgid ""
 "\n"
@@ -3028,20 +3197,20 @@ msgstr ""
 "\n"
 " Création de la connectivité étendue (%.3g s)\n"
 
-#: src/base/cs_mesh.c:1485
+#: src/base/cs_mesh.c:1489
 #, c-format
 msgid ""
 " %s\n"
-"     Number of cells:          %lu\n"
-"     Number of interior faces: %lu\n"
-"     Number of boundary faces: %lu\n"
-"     Number of vertices:       %lu\n"
+"     Number of cells:          %llu\n"
+"     Number of interior faces: %llu\n"
+"     Number of boundary faces: %llu\n"
+"     Number of vertices:       %llu\n"
 msgstr ""
 " %s\n"
-"     Nombre de cellules :       %lu\n"
-"     Nombre de faces internes : %lu\n"
-"     Nombre de faces de bord :  %lu\n"
-"     Nombre de sommets :        %lu\n"
+"     Nombre de cellules :       %llu\n"
+"     Nombre de faces internes : %llu\n"
+"     Nombre de faces de bord :  %llu\n"
+"     Nombre de sommets :        %llu\n"
 
 #: src/base/cs_mesh_coherency.c:104
 msgid "    Checking the face -> cells connectivity coherency\n"
@@ -3319,7 +3488,7 @@ msgstr ""
 #: src/base/cs_mesh_quantities.c:1232
 #, c-format
 msgid ""
-"  %lu cells have a Negative volume.\n"
+"  %llu cells have a Negative volume.\n"
 " Run mesh quality check for post-processing output.\n"
 " In case of mesh joining, this may be due to overly  agressive joining "
 "parameters."
@@ -3329,7 +3498,7 @@ msgstr ""
 msgid "Fluid volume"
 msgstr "Volume fluide"
 
-#: src/base/cs_mesh_warping.c:1028
+#: src/base/cs_mesh_warping.c:1031
 msgid ""
 "The faces have been renumbered before cutting.\n"
 "This case should not arise, because the mesh entities\n"
@@ -3339,12 +3508,12 @@ msgstr ""
 "Ce cas ne devrait pas se produire, car on devrait découper\n"
 "les entités de maillage avant de les renuméroter."
 
-#: src/base/cs_mesh_warping.c:1036
+#: src/base/cs_mesh_warping.c:1039
 #, c-format
 msgid "\t%12d global faces before cutting\n"
 msgstr "\t%12d faces globales avant découpage\n"
 
-#: src/base/cs_mesh_warping.c:1056
+#: src/base/cs_mesh_warping.c:1059
 #, c-format
 msgid ""
 "\t%12d global faces after cutting\n"
@@ -3353,19 +3522,19 @@ msgstr ""
 "\t%12d faces globales après découpage\n"
 "\n"
 
-#: src/base/cs_mesh_warping.c:1102
+#: src/base/cs_mesh_warping.c:1105
 msgid "Warped faces to cut"
 msgstr "Faces gauche a decouper"
 
-#: src/base/cs_mesh_warping.c:1123
+#: src/base/cs_mesh_warping.c:1126
 msgid "Face warping"
 msgstr "Gauchissement des faces"
 
-#: src/base/cs_mesh_warping.c:1163
+#: src/base/cs_mesh_warping.c:1166
 msgid "Warped faces after cutting"
 msgstr "Faces gauche apres decoupage"
 
-#: src/base/cs_mesh_warping.c:1218
+#: src/base/cs_mesh_warping.c:1221
 #, c-format
 msgid ""
 "\n"
@@ -3384,7 +3553,7 @@ msgstr ""
 " Angle maximal autorisé (rad) :\t%7.4f\n"
 "\n"
 
-#: src/base/cs_mesh_warping.c:1281
+#: src/base/cs_mesh_warping.c:1284
 msgid ""
 "\n"
 " No face to cut. Verify the criterion if necessary.\n"
@@ -3392,7 +3561,7 @@ msgstr ""
 "\n"
 " Aucune face à découper. Revoir le critère si nécessaire.\n"
 
-#: src/base/cs_mesh_warping.c:1328
+#: src/base/cs_mesh_warping.c:1331
 #, c-format
 msgid ""
 " Interior faces:\n"
@@ -3409,7 +3578,7 @@ msgstr ""
 "\t%12d faces localement après découpage\n"
 "\n"
 
-#: src/base/cs_mesh_warping.c:1335 src/base/cs_mesh_warping.c:1375
+#: src/base/cs_mesh_warping.c:1338 src/base/cs_mesh_warping.c:1378
 #, c-format
 msgid ""
 " Size of the new face -> vertices connectivity: %12d\n"
@@ -3418,7 +3587,7 @@ msgstr ""
 " Taille de la nouvelle connectivité face -> sommets :%12d\n"
 "\n"
 
-#: src/base/cs_mesh_warping.c:1368
+#: src/base/cs_mesh_warping.c:1371
 #, c-format
 msgid ""
 " Boundary faces:\n"
@@ -3657,11 +3826,11 @@ msgstr ""
 #, c-format
 msgid ""
 "                                  total       min        max\n"
-"     number of cells:     %12lu %10d %10d\n"
+"     number of cells:     %12llu %10d %10d\n"
 "     number of faces:                  %10d %10d\n"
 msgstr ""
 "                                  total       min        max\n"
-"     nombre de cellules : %12lu %10d %10d\n"
+"     nombre de cellules : %12llu %10d %10d\n"
 "     nombre de faces :                 %10d %10d\n"
 
 #: src/base/cs_multigrid.c:1731
@@ -3677,11 +3846,11 @@ msgstr ""
 #, c-format
 msgid ""
 "   number of coarse grids:           %d\n"
-"   number of cells in coarsest grid: %lu\n"
+"   number of cells in coarsest grid: %llu\n"
 "\n"
 msgstr ""
 "   nombre de maillages grossiers :                        %d\n"
-"   nombre de cellules dans le maillage le plus grossier : %lu\n"
+"   nombre de cellules dans le maillage le plus grossier : %llu\n"
 "\n"
 
 #: src/base/cs_numbering.c:80
@@ -3717,7 +3886,7 @@ msgstr ""
 " --solcom          noyau autonome avec maillage \"geomet\" au\n"
 "                   format SolCom (obsolète)\n"
 
-#: src/base/cs_opts.c:122
+#: src/base/cs_opts.c:121
 #, c-format
 msgid ""
 " --mpi             use MPI for parallelism or coupling\n"
@@ -3728,7 +3897,7 @@ msgstr ""
 "                   [appnum] : numéro de cette application en cas de\n"
 "                              couplage de codes (défaut : 0)\n"
 
-#: src/base/cs_opts.c:126
+#: src/base/cs_opts.c:125
 #, c-format
 msgid ""
 " --mpi-io          <mode> set parallel I/O behavior\n"
@@ -3738,12 +3907,12 @@ msgid ""
 "                     ip:  MPI-IO with individual file pointers\n"
 msgstr ""
 
-#: src/base/cs_opts.c:133
+#: src/base/cs_opts.c:131
 #, c-format
 msgid " -q, --quality     mesh quality verification mode\n"
 msgstr " -q, --quality     vérification de la qualité du maillage\n"
 
-#: src/base/cs_opts.c:135
+#: src/base/cs_opts.c:133
 #, c-format
 msgid ""
 " --cwf             <criterion> cut warped faces\n"
@@ -3755,7 +3924,7 @@ msgstr ""
 "                    -post : active le post-traitement lié au \n"
 "                            découpage des faces\n"
 
-#: src/base/cs_opts.c:139
+#: src/base/cs_opts.c:137
 #, c-format
 msgid ""
 " --benchmark       elementary operations performance\n"
@@ -3766,7 +3935,7 @@ msgstr ""
 "                   [--mpitrace] opérations effectuées une seule\n"
 "                                fois pour traces MPI légères\n"
 
-#: src/base/cs_opts.c:143
+#: src/base/cs_opts.c:141
 #, c-format
 msgid ""
 " --log             output redirection for rank -1 or 0:\n"
@@ -3777,7 +3946,7 @@ msgstr ""
 "                     0 : sortie standard\n"
 "                     1 : sorties dans \"listing\" (défaut)\n"
 
-#: src/base/cs_opts.c:147
+#: src/base/cs_opts.c:145
 #, c-format
 msgid ""
 " --logp            output redirection for rank > 0:\n"
@@ -3792,24 +3961,24 @@ msgstr ""
 "                         indépendants, type deboggeur)\n"
 "                     1 : sorties dans \"listing_n<rang>\"\n"
 
-#: src/base/cs_opts.c:154
+#: src/base/cs_opts.c:151
 #, c-format
 msgid " -p, --param       <file_name> parameter file\n"
 msgstr " -p, --param       <nom_du_fichier> fichier de paramètres\n"
 
-#: src/base/cs_opts.c:159
+#: src/base/cs_opts.c:154
 #, c-format
 msgid ""
 " --syr-socket      enable sockets for SYRTHES 3 coupling\n"
 "                   <port_num> port number on rank 0\n"
 msgstr ""
 
-#: src/base/cs_opts.c:164
+#: src/base/cs_opts.c:158
 #, c-format
 msgid " --version         print version number\n"
 msgstr " --version         affiche le numéro de version\n"
 
-#: src/base/cs_opts.c:166
+#: src/base/cs_opts.c:160
 #, c-format
 msgid ""
 " -h, --help        this help message\n"
@@ -3818,21 +3987,21 @@ msgstr ""
 " -h, --help        appel de l'aide (cet affichage)\n"
 "\n"
 
-#: src/base/cs_opts.c:179
+#: src/base/cs_opts.c:173
 #, c-format
 msgid "%s version %s\n"
 msgstr "%s version %s\n"
 
-#: src/base/cs_opts.c:332
+#: src/base/cs_opts.c:326
 msgid "command: \n"
 msgstr "commande : \n"
 
-#: src/base/cs_opts.c:347
+#: src/base/cs_opts.c:341
 #, c-format
 msgid "  build %s\n"
 msgstr "  build %s\n"
 
-#: src/base/cs_opts.c:351
+#: src/base/cs_opts.c:345
 #, c-format
 msgid ""
 "  MPI version %d.%d (%s)\n"
@@ -3841,7 +4010,7 @@ msgstr ""
 "  Version MPI %d.%d (%s)\n"
 "\n"
 
-#: src/base/cs_opts.c:354
+#: src/base/cs_opts.c:348
 #, c-format
 msgid ""
 "  MPI version %d.%d\n"
@@ -3850,6 +4019,34 @@ msgstr ""
 "  Version MPI %d.%d\n"
 "\n"
 
+#: src/base/cs_opts.c:606
+#, c-format
+msgid ""
+"%s was built without MPI support,\n"
+"so option \"%s\" may not be used.\n"
+msgstr ""
+
+#: src/base/cs_opts.c:657
+#, c-format
+msgid ""
+"%s was built without XML support,\n"
+"so parameter file \"%s\" may not be loaded.\n"
+msgstr ""
+
+#: src/base/cs_opts.c:716
+#, c-format
+msgid ""
+"%s was built without socket support,\n"
+"so option \"%s\" may not be used.\n"
+msgstr ""
+
+#: src/base/cs_opts.c:733
+#, c-format
+msgid ""
+"%s was built without dynamic loader support,\n"
+"so module file \"%s\" may not be loaded.\n"
+msgstr ""
+
 #: src/base/cs_perio.c:344
 #, c-format
 msgid ""
@@ -4006,7 +4203,7 @@ msgstr " Ajout de la périodicité %d (translation [%10.4e, %10.4e, %10.4e]).\n"
 msgid " Adding periodicity %d (rotation).\n"
 msgstr " Ajout de la périodicité %d (rotation).\n"
 
-#: src/base/cs_preprocessor_data.c:338 src/base/cs_preprocessor_data.c:2149
+#: src/base/cs_preprocessor_data.c:338 src/base/cs_preprocessor_data.c:2156
 #, c-format
 msgid ""
 "Message of type <%s> on <%s>\n"
@@ -4032,12 +4229,12 @@ msgstr "   le partitionnement sera basé sur une courbe fractale.\n"
 #, c-format
 msgid ""
 "The number of cells reported by file\n"
-"\"%s\" (%lu)\n"
-"does not correspond the those of the mesh (%lu)."
+"\"%s\" (%llu)\n"
+"does not correspond the those of the mesh (%llu)."
 msgstr ""
 "Le nombre de cellules indiqué par le fichier\n"
-"\"%s\" (%lu)\n"
-"ne correspond pas au maillage courant (%lu)."
+"\"%s\" (%llu)\n"
+"ne correspond pas au maillage courant (%llu)."
 
 #: src/base/cs_preprocessor_data.c:426
 #, c-format
@@ -4050,7 +4247,12 @@ msgstr ""
 "\"%s\" (%d)\n"
 "ne correspond pas au nombre de rangs courant (%d)."
 
-#: src/base/cs_preprocessor_data.c:1519 src/base/cs_preprocessor_data.c:1775
+#: src/base/cs_preprocessor_data.c:461
+#, c-format
+msgid "Message of type <%s> on <%s> is unexpected."
+msgstr "Message de type <%s> sur <%s> inattendu."
+
+#: src/base/cs_preprocessor_data.c:1526 src/base/cs_preprocessor_data.c:1782
 #, c-format
 msgid ""
 "Number of cells on rank %d is zero.\n"
@@ -4059,7 +4261,7 @@ msgstr ""
 "Le nombre de cellules pour le rang %d est nul.\n"
 "(rapport nombre de cellules / nombre de processeurs trop faible)."
 
-#: src/base/cs_preprocessor_data.c:2463
+#: src/base/cs_preprocessor_data.c:2494
 #, c-format
 msgid ""
 "The algorithm selection indicator for domain partitioning\n"
@@ -4074,7 +4276,7 @@ msgstr ""
 "  2: partition basée sur une courbe fractale\n"
 "et non %d."
 
-#: src/base/cs_preprocessor_data.c:2508
+#: src/base/cs_preprocessor_data.c:2539
 #, c-format
 msgid ""
 "Section of type <%s> on <%s>\n"
@@ -4235,12 +4437,12 @@ msgstr ""
 #, c-format
 msgid ""
 "The size of location \"%s\" associated with\n"
-"the restart file \"%s\" is %lu and does not\n"
-"correspond to that of the current mesh (%lu).\n"
+"the restart file \"%s\" is %llu and does not\n"
+"correspond to that of the current mesh (%llu).\n"
 msgstr ""
 "La taille du support \"%s\" associé au fichier suite\n"
-"\"%s\" vaut %lu et ne correspond pas\n"
-"à celle du maillage en cours (%lu).\n"
+"\"%s\" vaut %llu et ne correspond pas\n"
+"à celle du maillage en cours (%llu).\n"
 
 #: src/base/cs_restart.c:1433
 #, c-format
@@ -4255,56 +4457,56 @@ msgstr ""
 #, c-format
 msgid ""
 "  Location: %s\n"
-"    (number: %03d, n_glob_ents: %lu)\n"
+"    (number: %03d, n_glob_ents: %llu)\n"
 msgstr ""
 "  Support : %s\n"
-"    (numéro : %03d, n_glob_ents : %lu)\n"
+"    (numéro : %03d, n_glob_ents : %llu)\n"
 
-#: src/base/cs_restart.c:1502
+#: src/base/cs_restart.c:1503
 msgid "  General information associated with the restart file:\n"
 msgstr "  Informations générales associées au fichier suite :\n"
 
-#: src/base/cs_restart.c:1561
+#: src/base/cs_restart.c:1562
 #, c-format
 msgid "  %s: location id %d for \"%s\" does not exist.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1567
+#: src/base/cs_restart.c:1569
 #, c-format
-msgid "  %s: location id %d for \"%s\" has size %lu, but %lu is expected.\n"
+msgid "  %s: location id %d for \"%s\" has size %llu, but %llu is expected.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1589
+#: src/base/cs_restart.c:1591
 #, c-format
 msgid "  %s: section \"%s\" not present.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1616
+#: src/base/cs_restart.c:1618
 #, c-format
 msgid "  %s: section \"%s\" at location id %d but not at %d.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1626
+#: src/base/cs_restart.c:1628
 #, c-format
 msgid "  %s: section \"%s\" has %d values per location and  not %d.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1633
+#: src/base/cs_restart.c:1635
 #, c-format
 msgid "  %s: section \"%s\" has %d values and not %d.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1643
+#: src/base/cs_restart.c:1645
 #, c-format
 msgid "  %s: section \"%s\" is not of integer type.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1656
+#: src/base/cs_restart.c:1658
 #, c-format
 msgid "  %s: section \"%s\" is not of floating-point type.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1840
+#: src/base/cs_restart.c:1842
 #, c-format
 msgid ""
 "\n"
@@ -4375,27 +4577,27 @@ msgstr ""
 "   nombre de rangs MPI :        %d\n"
 "\n"
 
-#: src/base/cs_sat_coupling.c:1015 src/base/cs_sat_coupling.c:1222
-#: src/base/cs_sat_coupling.c:1289 src/base/cs_sat_coupling.c:1364
-#: src/base/cs_sat_coupling.c:1425 src/base/cs_sat_coupling.c:1495
-#: src/base/cs_sat_coupling.c:1593 src/base/cs_sat_coupling.c:1672
-#: src/base/cs_sat_coupling.c:1763 src/base/cs_sat_coupling.c:1839
-#: src/base/cs_sat_coupling.c:1907
+#: src/base/cs_sat_coupling.c:1016 src/base/cs_sat_coupling.c:1231
+#: src/base/cs_sat_coupling.c:1298 src/base/cs_sat_coupling.c:1373
+#: src/base/cs_sat_coupling.c:1434 src/base/cs_sat_coupling.c:1504
+#: src/base/cs_sat_coupling.c:1602 src/base/cs_sat_coupling.c:1681
+#: src/base/cs_sat_coupling.c:1772 src/base/cs_sat_coupling.c:1848
+#: src/base/cs_sat_coupling.c:1916
 #, c-format
 msgid "Impossible coupling number %d; there are %d couplings"
 msgstr "Numéro de couplage %d impossible ;  on a %d couplages"
 
-#: src/base/cs_sat_coupling.c:1030
+#: src/base/cs_sat_coupling.c:1063
 #, c-format
 msgid "coupled_cells_%d"
 msgstr ""
 
-#: src/base/cs_sat_coupling.c:1049
+#: src/base/cs_sat_coupling.c:1074
 #, c-format
 msgid "coupled_faces_%d"
 msgstr ""
 
-#: src/base/cs_sat_coupling.c:1302
+#: src/base/cs_sat_coupling.c:1311
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for LELCPL()\n"
@@ -4406,7 +4608,7 @@ msgstr ""
 "On a indiqué NCECPL = %d et NFBCPL = %d.\n"
 "On devrait avoir les valeurs %d et %d pour ce couplage."
 
-#: src/base/cs_sat_coupling.c:1377
+#: src/base/cs_sat_coupling.c:1386
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for LELNCP()\n"
@@ -4417,7 +4619,7 @@ msgstr ""
 "On a indiqué NCENCP = %d et NFBNCP = %d.\n"
 "On devrait avoir les valeurs %d et %d pour ce couplage."
 
-#: src/base/cs_sat_coupling.c:1519
+#: src/base/cs_sat_coupling.c:1528
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for COOCPL()\n"
@@ -4428,13 +4630,13 @@ msgstr ""
 "On a indiqué ITYDIS = %d et NBRPTS = %d.\n"
 "On devrait avoir la valeur %d pour NBRPTS."
 
-#: src/base/cs_sat_coupling.c:1600
+#: src/base/cs_sat_coupling.c:1609
 msgid ""
 "The centred interpolation scheme is not available\n"
 "when coupling cells"
 msgstr ""
 
-#: src/base/cs_sat_coupling.c:1611
+#: src/base/cs_sat_coupling.c:1620
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for PNDCPL().\n"
@@ -4445,7 +4647,7 @@ msgstr ""
 "On a indiqué ITYLOC = %d et NBRPTS = %d.\n"
 "On devrait avoir la valeur %d pour NBRPTS."
 
-#: src/base/cs_sat_coupling.c:1689
+#: src/base/cs_sat_coupling.c:1698
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for VARCPL()\n"
@@ -4456,7 +4658,7 @@ msgstr ""
 "On a indiqué ITYVAR = %d et NBRDIS = %d.\n"
 "On devrait avoir la valeur 0 ou %d pour NBRDIS."
 
-#: src/base/cs_sat_coupling.c:1696
+#: src/base/cs_sat_coupling.c:1705
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for VARCPL()\n"
@@ -4467,7 +4669,7 @@ msgstr ""
 "On a indiqué ITYVAR = %d et NBRLOC = %d.\n"
 "On devrait avoir la valeur 0 ou %d pour NBRLOC."
 
-#: src/base/cs_sat_coupling.c:2068
+#: src/base/cs_sat_coupling.c:2077
 msgid ""
 "At least 1 Code_Saturne coupling was defined for which\n"
 "no communication with a Code_Saturne instance is possible."
@@ -4997,20 +5199,20 @@ msgstr "Erreur lors de la projection du maillage extrait."
 #, c-format
 msgid ""
 "\n"
-"Extracted mesh built of %lu elements.\n"
+"Extracted mesh built of %llu elements.\n"
 msgstr ""
 "\n"
-"Maillage extrait composé de %lu éléments.\n"
+"Maillage extrait composé de %llu éléments.\n"
 
 #: src/base/cs_syr4_coupling.c:506
 #, c-format
 msgid ""
 "Coupling with SYRTHES impossible:\n"
-"%lu element centers from mesh \"%s\"\n"
+"%llu element centers from mesh \"%s\"\n"
 "not located on SYRTHES mesh."
 msgstr ""
 "Couplage avec SYRTHES impossible :\n"
-"%lu centres d'éléments du maillage \"%s\"\n"
+"%llu centres d'éléments du maillage \"%s\"\n"
 "non localisés sur le maillage SYRTHES."
 
 #: src/base/cs_syr4_coupling.c:762
diff --git a/po/fr.po b/po/ncs.pot
similarity index 60%
copy from po/fr.po
copy to po/ncs.pot
index 50120ef..778865f 100644
--- a/po/fr.po
+++ b/po/ncs.pot
@@ -1,62 +1,53 @@
-# translation of fr.po to
-# French translations for ncs package.
-# Copyright (C) 2008 EDF S.A.
-# This file is distributed under the same license as the ncs package.
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR EDF S.A.
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL at ADDRESS>, YEAR.
 #
-# Automatically generated, 2008.
-# Saturne <saturne-support at edf.fr>, 2008.
+#, fuzzy
 msgid ""
 msgstr ""
-"Project-Id-Version: ncs 2.0\n"
+"Project-Id-Version: ncs 2.0.0\n"
 "Report-Msgid-Bugs-To: saturne-support at edf.fr\n"
-"POT-Creation-Date: 2010-02-12 19:18+0100\n"
-"PO-Revision-Date: 2010-01-11 12:50+0100\n"
-"Last-Translator: Code_Saturne <saturne-support at edf.fr>\n"
-"Language-Team: French <traduc at traduc.org>\n"
+"POT-Creation-Date: 2010-12-03 14:17+0100\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL at ADDRESS>\n"
+"Language-Team: LANGUAGE <LL at li.org>\n"
+"Language: \n"
 "MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Type: text/plain; charset=CHARSET\n"
 "Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=2; plural=(n > 1);\n"
 
-#: src/apps/cs_solver.c:292
+#: src/apps/cs_solver.c:293
 #, c-format
 msgid ""
 "\n"
 " Cutting warped faces (%.3g s)\n"
 msgstr ""
-"\n"
-" Découpage des faces gauches (%.3g s)\n"
 
-#: src/apps/cs_solver.c:298
+#: src/apps/cs_solver.c:299
 msgid ""
 "\n"
 " Renumbering mesh:\n"
 msgstr ""
-"\n"
-" Renumérotation du maillage:\n"
 
-#: src/apps/cs_solver.c:354
+#: src/apps/cs_solver.c:355
 msgid "Mesh"
-msgstr "Maillage"
+msgstr ""
 
-#: src/apps/cs_solver.c:368
+#: src/apps/cs_solver.c:369
 #, c-format
 msgid ""
 "\n"
 " Computing geometric quantities (%.3g s)\n"
 msgstr ""
-"\n"
-" Calcul des grandeurs géométriques (%.3g s)\n"
 
-#: src/apps/cs_solver.c:384
+#: src/apps/cs_solver.c:385
 msgid ""
 "\n"
 " Computing quality criteria\n"
 msgstr ""
-"\n"
-" Calcul des critères de qualité\n"
 
-#: src/apps/cs_solver.c:406
+#: src/apps/cs_solver.c:407
 #, c-format
 msgid ""
 "\n"
@@ -65,13 +56,8 @@ msgid ""
 "       longra =   %10d (Number of reals)\n"
 "       (%d bytes/integer, %d bytes/real)\n"
 msgstr ""
-"\n"
-" --- Tableaux de travail Fortran principaux :\n"
-"       longia =   %10d (Nombre d'entiers)\n"
-"       longra =   %10d (Nombre de réels)\n"
-"       (%d octets/entier, %d octets/réel)\n"
 
-#: src/apps/cs_solver.c:416
+#: src/apps/cs_solver.c:417
 #, c-format
 msgid ""
 "\n"
@@ -79,12 +65,8 @@ msgid ""
 "       nideve =   %10d (Number of integer)\n"
 "       nrdeve =   %10d (Number of reals)\n"
 msgstr ""
-"\n"
-" --- Tableaux de travail Fortran développeur :\n"
-"       nideve =   %10d (Nombre d'entiers)\n"
-"       nrdeve =   %10d (Nombre de réels)\n"
 
-#: src/apps/cs_solver.c:422
+#: src/apps/cs_solver.c:423
 #, c-format
 msgid ""
 "\n"
@@ -93,19 +75,12 @@ msgid ""
 "       nrtuse =   %10d (Number of reals)\n"
 "\n"
 msgstr ""
-"\n"
-" --- Tableaux de travail Fortran utilisateur :\n"
-"       nituse =   %10d (Nombre d'entiers)\n"
-"       nrtuse =   %10d (Nombre de réels)\n"
-"\n"
 
-#: src/apps/cs_solver.c:484
+#: src/apps/cs_solver.c:485
 msgid ""
 "\n"
 " Destroying structures and ending computation\n"
 msgstr ""
-"\n"
-" Destruction des structures et clôture du calcul\n"
 
 #: src/base/cs_base.c:222
 #, c-format
@@ -113,8 +88,6 @@ msgid ""
 "Fatal error: bft_printf() called on a message of size %d\n"
 "whereas the print buffer is of size %d."
 msgstr ""
-"Erreur fatale: bft_printf() appellé sur message de taille %d\n"
-"alors que le tampon d'impression est de taille %d."
 
 #: src/base/cs_base.c:398
 #, c-format
@@ -122,8 +95,6 @@ msgid ""
 "\n"
 "System error: %s\n"
 msgstr ""
-"\n"
-"Erreur système : %s\n"
 
 #: src/base/cs_base.c:400
 #, c-format
@@ -132,9 +103,6 @@ msgid ""
 "%s:%d: Fatal error.\n"
 "\n"
 msgstr ""
-"\n"
-"%s:%d: Erreur fatale.\n"
-"\n"
 
 #: src/base/cs_base.c:420
 msgid ""
@@ -144,88 +112,73 @@ msgid ""
 "-------------------------\n"
 "\n"
 msgstr ""
-"\n"
-"\n"
-"Résumé de l'allocation mémoire\n"
-"------------------------------\n"
-"\n"
 
 #: src/base/cs_base.c:427
 #, c-format
-msgid "Theoretical current allocated memory:   %lu kB\n"
-msgstr "Mémoire dynamique instrumentée théorique : %lu ko\n"
+msgid "Theoretical current allocated memory:   %llu kB\n"
+msgstr ""
 
 #: src/base/cs_base.c:431
 #, c-format
-msgid "Theoretical maximum allocated memory:   %lu kB\n"
-msgstr "Mémoire dynamique instrumentée théorique : %lu ko\n"
+msgid "Theoretical maximum allocated memory:   %llu kB\n"
+msgstr ""
 
 #: src/base/cs_base.c:441
 #, c-format
-msgid "Maximum program memory measure:         %lu kB\n"
-msgstr "Mémoire programme mesurée maximale:        %lu ko\n"
+msgid "Maximum program memory measure:         %llu kB\n"
+msgstr ""
 
 #: src/base/cs_base.c:449
 #, c-format
-msgid "Current program memory measure:         %lu kB\n"
-msgstr "Mémoire programme mesurée courante:        %lu ko\n"
+msgid "Current program memory measure:         %llu kB\n"
+msgstr ""
 
 #: src/base/cs_base.c:511
 msgid ""
 "\n"
 "Call stack:\n"
 msgstr ""
-"\n"
-"Pile d'appels :\n"
 
 #: src/base/cs_base.c:539
 msgid ""
 "End of stack\n"
 "\n"
 msgstr ""
-"Fin de la pile\n"
-"\n"
 
 #: src/base/cs_base.c:557
 msgid ""
 "SIGHUP signal (hang-up) intercepted.\n"
 "--> computation interrupted.\n"
 msgstr ""
-"Signal SIGHUP (déconnexion) intercepté.\n"
-"--> calcul interrompu.\n"
 
 #: src/base/cs_base.c:563
 msgid ""
 "SIGINT signal (Control+C or equivalent) received.\n"
 "--> computation interrupted by user.\n"
 msgstr ""
-"Signal SIGINT (Control+C ou équivalent) reçu.\n"
-"--> calcul interrompu par l'utilisateur.\n"
 
 #: src/base/cs_base.c:568
 msgid ""
 "SIGTERM signal (termination) received.\n"
 "--> computation interrupted by environment.\n"
 msgstr ""
-"Signal SIGTERM (terminaison) reçu.\n"
-"--> calcul interrompu par l'environnement.\n"
 
 #: src/base/cs_base.c:573
 msgid "SIGFPE signal (floating point exception) intercepted!\n"
-msgstr "Signal SIGFPE (exception en virgule flottante) intercepté !\n"
+msgstr ""
 
 #: src/base/cs_base.c:578
 msgid "SIGSEGV signal (forbidden memory area access) intercepted!\n"
-msgstr "Signal SIGSEGV (accès à une zone mémoire interdite) intercepté !\n"
+msgstr ""
 
 #: src/base/cs_base.c:584
 msgid "SIGXCPU signal (CPU time limit reached) intercepted.\n"
-msgstr "Signal SIGXCPU (temps CPU limite atteint) intercepté.\n"
+msgstr ""
 
 #: src/base/cs_base.c:590
 #, c-format
 msgid "Signal %d intercepted!\n"
-msgstr "Signal %d intercepté !\n"
+msgstr ""
 
 #: src/base/cs_base.c:648
 #, c-format
@@ -234,9 +187,6 @@ msgid ""
 "MPI error (communicator %s):\n"
 "%s\n"
 msgstr ""
-"\n"
-"Erreur MPI (communicateur %s):\n"
-"%s\n"
 
 #: src/base/cs_base.c:651
 #, c-format
@@ -245,9 +195,6 @@ msgid ""
 "MPI error:\n"
 "%s\n"
 msgstr ""
-"\n"
-"Erreur MPI :\n"
-"%s\n"
 
 #: src/base/cs_base.c:766
 #, c-format
@@ -258,11 +205,6 @@ msgid ""
 "\n"
 " ----> Define iasize to a value at least equal to %d integers)."
 msgstr ""
-" Sous-programme appelant iasize :                   %s\n"
-" Mémoire nécessaire dans ia (en nombre d'entiers) : %d\n"
-"         disponible :                               %d\n"
-"\n"
-" ----> Définir iasize au moins égale à %d entiers)."
 
 #: src/base/cs_base.c:810
 #, c-format
@@ -273,19 +215,14 @@ msgid ""
 "\n"
 " ----> Define rasize to a value at least equal to %d reals)."
 msgstr ""
-" Sous-programme appelant rasize :                   %s\n"
-" Mémoire nécessaire dans ra (en nombre de réels) :  %d\n"
-"         disponible :                               %d\n"
-"\n"
-" ----> Définir rasize au moins égale à %d réels)."
 
 #: src/base/cs_base.c:1091
 msgid "Total memory used:                       "
-msgstr "Consommation mémoire totale mesurée :     "
+msgstr ""
 
 #: src/base/cs_base.c:1092
 msgid "Theoretical instrumented dynamic memory: "
-msgstr "Mémoire dynamique instrumentée théorique :"
+msgstr ""
 
 #: src/base/cs_base.c:1096
 msgid ""
@@ -293,51 +230,39 @@ msgid ""
 "Memory use summary:\n"
 "\n"
 msgstr ""
-"\n"
-"Bilan de l'occupation mémoire :\n"
-"\n"
 
 #: src/base/cs_base.c:1159
 #, c-format
 msgid "  %s %12.3f %cb\n"
-msgstr "  %s %12.3f %co\n"
+msgstr ""
 
 #: src/base/cs_base.c:1164
 #, c-format
 msgid "                             local minimum: %12.3f %cb  (rank %d)\n"
-msgstr "                             minimum local : %12.3f %co  (rang %d)\n"
+msgstr ""
 
 #: src/base/cs_base.c:1167
 #, c-format
 msgid "                             local maximum: %12.3f %cb  (rank %d)\n"
-msgstr "                             maximum local : %12.3f %co  (rang %d)\n"
+msgstr ""
 
 #: src/base/cs_base.c:1207
 #, c-format
 msgid ""
 "\n"
 "  Fortran work arrays memory use:\n"
-"   %-12lu integers needed (maximum reached in %s)\n"
-"   %-12lu reals    needed (maximum reached in %s)\n"
+"   %-12llu integers needed (maximum reached in %s)\n"
+"   %-12llu reals    needed (maximum reached in %s)\n"
 "\n"
 "   Local maximum work memory requested %12.3f %cb\n"
 "                                  used %12.3f %cb\n"
 msgstr ""
-"\n"
-"  Utilisation des tableaux de travail Fortran :\n"
-"   %-12lu entiers nécessaires (maximum atteint dans %s)\n"
-"   %-12lu réels   nécessaires (maximum atteint dans %s)\n"
-"\n"
-"   Mémoire de travail maximale locale demandée %12.3f %co\n"
-"                                      utilisée %12.3f %co\n"
 
 #: src/base/cs_base.c:1244
 msgid ""
 "\n"
 "Calculation time summary:\n"
 msgstr ""
-"\n"
-"Bilan des temps de calcul :\n"
 
 #: src/base/cs_base.c:1258
 #, c-format
@@ -345,13 +270,11 @@ msgid ""
 "\n"
 "  User CPU time:       %12.3f s\n"
 msgstr ""
-"\n"
-"  Temps CPU utilisateur : %12.3f s\n"
 
 #: src/base/cs_base.c:1260
 #, c-format
 msgid "  System CPU time:     %12.3f s\n"
-msgstr "  Temps CPU système :     %12.3f s\n"
+msgstr ""
 
 #: src/base/cs_base.c:1265
 #, c-format
@@ -359,13 +282,11 @@ msgid ""
 "\n"
 "  CPU time:            %12.3f s\n"
 msgstr ""
-"\n"
-"  Temps CPU :             %12.3f s\n"
 
 #: src/base/cs_base.c:1274
 #, c-format
 msgid "  Total CPU time:      %12.3f s\n"
-msgstr "  Temps CPU cumulé :      %12.3f s\n"
+msgstr ""
 
 #: src/base/cs_base.c:1285
 #, c-format
@@ -373,53 +294,51 @@ msgid ""
 "\n"
 "  Elapsed time:        %12.3f s\n"
 msgstr ""
-"\n"
-"  Temps écoulé :          %12.3f s\n"
 
 #: src/base/cs_base.c:1288
 #, c-format
 msgid "  CPU / elapsed time   %12.3f\n"
-msgstr "  Temps CPU / écoulé      %12.3f\n"
+msgstr ""
 
 #: src/base/cs_base.c:1380
 msgid "Local case configuration:\n"
-msgstr "Configuration locale du cas :\n"
+msgstr ""
 
 #: src/base/cs_base.c:1382
 msgid "Date:              "
-msgstr "Date :             "
+msgstr ""
 
 #: src/base/cs_base.c:1390
 msgid "System:            "
-msgstr "Système :          "
+msgstr ""
 
 #: src/base/cs_base.c:1392
 msgid "Machine:           "
-msgstr "Machine :          "
+msgstr ""
 
 #: src/base/cs_base.c:1396
 msgid "Processor:         "
-msgstr "Processeur :       "
+msgstr ""
 
 #: src/base/cs_base.c:1399
 msgid "Memory:            "
-msgstr "Mémoire :          "
+msgstr ""
 
 #: src/base/cs_base.c:1402
 msgid "User:              "
-msgstr "Utilisateur :      "
+msgstr ""
 
 #: src/base/cs_base.c:1406
 msgid "Directory:         "
-msgstr "Répertoire :       "
+msgstr ""
 
 #: src/base/cs_base.c:1409
 msgid "MPI ranks:         "
-msgstr "Rangs MPI :        "
+msgstr ""
 
 #: src/base/cs_base.c:1412
 msgid "OpenMP threads:    "
-msgstr "Threads OpenMP:    "
+msgstr ""
 
 #: src/base/cs_base.c:1442
 #, c-format
@@ -428,9 +347,6 @@ msgid ""
 "\n"
 "Code_Saturne: %s:%d: Warning\n"
 msgstr ""
-"\n"
-"\n"
-"Code_Saturne : %s:%d : Avertissement\n"
 
 #: src/base/cs_benchmark.c:164
 #, c-format
@@ -438,8 +354,6 @@ msgid ""
 "  Wall clock : %12.5e\n"
 "  CPU :        %12.5e\n"
 msgstr ""
-"  Temps écoulé: %12.5e\n"
-"  CPU:          %12.5e\n"
 
 #: src/base/cs_benchmark.c:193
 #, c-format
@@ -448,9 +362,6 @@ msgid ""
 "  Wall clock : %12.5e %12.5e\n"
 "  CPU :        %12.5e %12.5e %12.5e\n"
 msgstr ""
-"               Min          Max          Total\n"
-"  Écoulé :     %12.5e %12.5e\n"
-"  CPU :        %12.5e %12.5e %12.5e\n"
 
 #: src/base/cs_benchmark.c:221
 #, c-format
@@ -460,10 +371,6 @@ msgid ""
 "  CPU :        %12.5e\n"
 "  GFLOPS :     %12.5e\n"
 msgstr ""
-"  N ops :      %12ld\n"
-"  Wall clock : %12.5e\n"
-"  CPU :        %12.5e\n"
-"  GFLOPS :     %12.5e\n"
 
 #: src/base/cs_benchmark.c:268
 #, c-format
@@ -474,11 +381,6 @@ msgid ""
 "  CPU :        %12.5e %12.5e %12.5e\n"
 "  GFLOPS :     %12.5e %12.5e %12.5e\n"
 msgstr ""
-"               Min          Max          Total\n"
-"  N ops :      %12ld %12ld %12ld\n"
-"  Wall clock : %12.5e %12.5e\n"
-"  CPU :        %12.5e %12.5e %12.5e\n"
-"  GFLOPS :     %12.5e %12.5e %12.5e\n"
 
 #: src/base/cs_benchmark.c:280
 #, c-format
@@ -489,11 +391,6 @@ msgid ""
 "  CPU :        %12.5e %12.5e %12.5e\n"
 "  GFLOPS :     %12.5e %12.5e %12.5e %12.5e\n"
 msgstr ""
-"               Min          Max          Total        Single\n"
-"  N ops :      %12ld %12ld %12ld %12ld\n"
-"  Wall clock : %12.5e %12.5e\n"
-"  CPU :        %12.5e %12.5e %12.5e\n"
-"  GFLOPS :     %12.5e %12.5e %12.5e %12.5e\n"
 
 #: src/base/cs_benchmark.c:356
 #, c-format
@@ -502,9 +399,6 @@ msgid ""
 "Simple local dot product %s with BLAS\n"
 "-------------------------------------\n"
 msgstr ""
-"\n"
-"Produit scalaire local simple %s avec BLAS\n"
-"------------------------------------------\n"
 
 #: src/base/cs_benchmark.c:361
 #, c-format
@@ -513,9 +407,6 @@ msgid ""
 "Simple global dot product %s with BLAS\n"
 "---------------------------------------\n"
 msgstr ""
-"\n"
-"Produit scalaire global simple %s avec BLAS\n"
-"--------------------------------------------\n"
 
 #: src/base/cs_benchmark.c:366 src/base/cs_benchmark.c:403
 #: src/base/cs_benchmark.c:458 src/base/cs_benchmark.c:483
@@ -526,7 +417,7 @@ msgstr ""
 #: src/base/cs_benchmark.c:1376 src/base/cs_benchmark.c:1404
 #, c-format
 msgid "  (calls: %d;  test sum: %12.5f)\n"
-msgstr "  (appels : %d;  somme test : %12.5f)\n"
+msgstr ""
 
 #: src/base/cs_benchmark.c:393
 #, c-format
@@ -535,9 +426,6 @@ msgid ""
 "Simple local dot product %s\n"
 "---------------------------\n"
 msgstr ""
-"\n"
-"Produit scalaire local simple %s\n"
-"--------------------------------\n"
 
 #: src/base/cs_benchmark.c:398
 #, c-format
@@ -546,9 +434,6 @@ msgid ""
 "Simple global dot product %s\n"
 "----------------------------\n"
 msgstr ""
-"\n"
-"Produit scalaire global simple %s\n"
-"---------------------------------\n"
 
 #: src/base/cs_benchmark.c:455
 msgid ""
@@ -556,9 +441,6 @@ msgid ""
 "Double local dot product X.X, Y.Y with BLAS\n"
 "-------------------------------------------\n"
 msgstr ""
-"\n"
-"Produit scalaire local double X.X, X.Y avec BLAS\n"
-"------------------------------------------------\n"
 
 #: src/base/cs_benchmark.c:479
 msgid ""
@@ -566,9 +448,6 @@ msgid ""
 "Double local dot product X.X, Y.Y\n"
 "---------------------------------\n"
 msgstr ""
-"\n"
-"Produit scalaire local double X.X, X.Y\n"
-"--------------------------------------\n"
 
 #: src/base/cs_benchmark.c:540
 msgid ""
@@ -576,9 +455,6 @@ msgid ""
 "Y <- aX + Y with BLAS\n"
 "---------------------\n"
 msgstr ""
-"\n"
-"Y <- aX + Y avec BLAS\n"
-"---------------------\n"
 
 #: src/base/cs_benchmark.c:564
 msgid ""
@@ -586,9 +462,6 @@ msgid ""
 "Y <- aX + Y\n"
 "-----------\n"
 msgstr ""
-"\n"
-"Y <- aX + Y\n"
-"-----------\n"
 
 #: src/base/cs_benchmark.c:624
 msgid ""
@@ -596,9 +469,6 @@ msgid ""
 "Division z = x/y\n"
 "----------------\n"
 msgstr ""
-"\n"
-"Division z = x/y\n"
-"----------------\n"
 
 #: src/base/cs_benchmark.c:645
 msgid ""
@@ -606,9 +476,6 @@ msgid ""
 "Division y = 1/x\n"
 "----------------\n"
 msgstr ""
-"\n"
-"Division y = 1/x\n"
-"----------------\n"
 
 #: src/base/cs_benchmark.c:666
 msgid ""
@@ -616,9 +483,6 @@ msgid ""
 "Division x <- 1/x\n"
 "-----------------\n"
 msgstr ""
-"\n"
-"Division x <- 1/x\n"
-"-----------------\n"
 
 #: src/base/cs_benchmark.c:719
 msgid ""
@@ -626,9 +490,6 @@ msgid ""
 "y = sqrt(x)\n"
 "-----------\n"
 msgstr ""
-"\n"
-"y = sqrt(x)\n"
-"-----------\n"
 
 #: src/base/cs_benchmark.c:740
 msgid ""
@@ -636,9 +497,6 @@ msgid ""
 "x = sqrt(x)\n"
 "-----------\n"
 msgstr ""
-"\n"
-"x = sqrt(x)\n"
-"-----------\n"
 
 #: src/base/cs_benchmark.c:809
 #, c-format
@@ -647,14 +505,11 @@ msgid ""
 "Matrix construction / destruction (%s)\n"
 "---------------------------------\n"
 msgstr ""
-"\n"
-"Construction / Destruction d'une matrice (%s)\n"
-"----------------------------------------\n"
 
 #: src/base/cs_benchmark.c:813 src/base/cs_benchmark.c:894
 #, c-format
 msgid "  (calls: %d)\n"
-msgstr "  (appels : %d)\n"
+msgstr ""
 
 #: src/base/cs_benchmark.c:890
 #, c-format
@@ -663,9 +518,6 @@ msgid ""
 "Matrix value assignment (%s)\n"
 "-----------------------\n"
 msgstr ""
-"\n"
-"Affectation de valeurs à une matrice (%s)\n"
-"------------------------------------\n"
 
 #: src/base/cs_benchmark.c:994
 #, c-format
@@ -674,9 +526,6 @@ msgid ""
 "Matrix.vector product (%s)\n"
 "---------------------\n"
 msgstr ""
-"\n"
-"Produit matrice.vecteur (%s)\n"
-"-----------------------\n"
 
 #: src/base/cs_benchmark.c:1020
 #, c-format
@@ -685,9 +534,6 @@ msgid ""
 "Local matrix.vector product (%s)\n"
 "---------------------------\n"
 msgstr ""
-"\n"
-"Produit matrice.vecteur local (%s)\n"
-"-----------------------------\n"
 
 #: src/base/cs_benchmark.c:1050
 #, c-format
@@ -696,9 +542,6 @@ msgid ""
 "Matrix.vector product alpha.A.x + beta.y (%s)\n"
 "----------------------------------------\n"
 msgstr ""
-"\n"
-"Produit matrice.vecteur alpha.A.x + beta.y (%s)\n"
-"------------------------------------------\n"
 
 #: src/base/cs_benchmark.c:1080
 #, c-format
@@ -707,9 +550,6 @@ msgid ""
 "(Matrix-diagonal).vector product (%s)\n"
 "--------------------------------\n"
 msgstr ""
-"\n"
-"Produit (matrice-diagonale).vecteur (%s)\n"
-"-----------------------------------\n"
 
 #: src/base/cs_benchmark.c:1132
 #, c-format
@@ -718,9 +558,6 @@ msgid ""
 "(Matrix without diagonal).vector product (%s)\n"
 "----------------------------------------\n"
 msgstr ""
-"\n"
-"Produit (matrice sans diagonale).vecteur (%s)\n"
-"----------------------------------------\n"
 
 #: src/base/cs_benchmark.c:1347
 msgid ""
@@ -728,9 +565,6 @@ msgid ""
 "Matrix.vector product, extradiagonal part, variant 0\n"
 "---------------------\n"
 msgstr ""
-"\n"
-"Produit matrice.vecteur, partie extradiagonale, variante 0\n"
-"-----------------------\n"
 
 #: src/base/cs_benchmark.c:1372
 msgid ""
@@ -738,9 +572,6 @@ msgid ""
 "Matrix.vector product, extradiagonal part, variant 1\n"
 "---------------------\n"
 msgstr ""
-"\n"
-"Produit matrice.vecteur, partie extradiagonale, variante 1\n"
-"-----------------------\n"
 
 #: src/base/cs_benchmark.c:1400
 msgid ""
@@ -748,9 +579,6 @@ msgid ""
 "Matrix.vector product, face values only\n"
 "---------------------\n"
 msgstr ""
-"\n"
-"Produit matrice.vecteur, valeurs aux faces uniquement\n"
-"-----------------------\n"
 
 #: src/base/cs_benchmark.c:1483
 msgid ""
@@ -758,35 +586,32 @@ msgid ""
 "Benchmark mode activated\n"
 "========================\n"
 msgstr ""
-"\n"
-"Activation du mode Benchmark\n"
-"============================\n"
 
 #: src/base/cs_benchmark.c:1525 src/base/cs_benchmark.c:1555
 #: src/base/cs_benchmark.c:1598 src/base/cs_matrix.c:316
 msgid "native"
-msgstr "native"
+msgstr ""
 
 #: src/base/cs_benchmark.c:1535 src/base/cs_benchmark.c:1571
 #: src/base/cs_benchmark.c:1612 src/base/cs_matrix.c:317
 msgid "CSR"
-msgstr "CSR"
+msgstr ""
 
 #: src/base/cs_benchmark.c:1543
 msgid "CSR sym"
-msgstr "CSR sym"
+msgstr ""
 
 #: src/base/cs_benchmark.c:1562 src/base/cs_benchmark.c:1605
 msgid "native, sym coeffs"
-msgstr "native, sym coeffs"
+msgstr ""
 
 #: src/base/cs_benchmark.c:1578
 msgid "CSR, sym coeffs"
-msgstr "CSR, sym coeffs"
+msgstr ""
 
 #: src/base/cs_benchmark.c:1585 src/base/cs_benchmark.c:1619
 msgid "CSR_sym"
-msgstr "CSR_sym"
+msgstr ""
 
 #: src/base/cs_boundary_conditions.c:307
 #, c-format
@@ -795,41 +620,33 @@ msgid ""
 "Phase %d:\n"
 "  "
 msgstr ""
-"\n"
-"Phase %d :\n"
-"  "
 
 #: src/base/cs_boundary_conditions.c:309
 #, c-format
 msgid ""
 "\n"
 "First face with boundary condition definition error\n"
-"  (out of %lu)\n"
+"  (out of %llu)\n"
 "  has boundary condition type %d, center (%g, %g, %g)\n"
 "\n"
 msgstr ""
-"\n"
-"Première face avec une mauvaise définition de conditions aux limites\n"
-"  (sur %lu)\n"
-"  a une condition aux limites de type %d, un centre (%g, %g, %g)\n"
-"\n"
 
 #: src/base/cs_boundary_conditions.c:350
 msgid "Faces with B.C. error"
-msgstr "Faces avec erreur de C.L."
+msgstr ""
 
 #: src/base/cs_boundary_conditions.c:376
 msgid "Faces with valid B.C.'s"
-msgstr "Faces avec C.L. valides"
+msgstr ""
 
 #: src/base/cs_boundary_conditions.c:401
 #, c-format
 msgid "Phase %d, "
-msgstr "Phase %d,"
+msgstr ""
 
 #: src/base/cs_boundary_conditions.c:407
 msgid "BC type"
-msgstr "Type de CL"
+msgstr ""
 
 #: src/base/cs_boundary_conditions.c:430
 msgid ""
@@ -839,25 +656,19 @@ msgid ""
 "  For details, read the end of the calculation log,\n"
 "  or visualize the error postprocessing output."
 msgstr ""
-"\n"
-"Certaines définitions de conditions aux limites sont incomplètes\n"
-"ou incorrectes :\n"
-"\n"
-"  Pour plus de détails, vérifiez la fin du \"listing\" de calcul,\n"
-"  ou visualisez le post traitement dédié aux erreurs."
 
 #: src/base/cs_calcium.c:262 src/base/cs_syr3_comm.c:877
 #, c-format
 msgid "    %d first and last elements:\n"
-msgstr "    %d premiers et derniers éléments :\n"
+msgstr ""
 
 #: src/base/cs_calcium.c:268 src/base/cs_syr3_comm.c:881
 msgid "    elements:\n"
-msgstr "    éléments :\n"
+msgstr ""
 
 #: src/base/cs_calcium.c:327
 msgid "    ..........   ............\n"
-msgstr "    ..........   ............\n"
+msgstr ""
 
 #: src/base/cs_calcium.c:375 src/base/cs_calcium.c:445
 #, c-format
@@ -865,8 +676,6 @@ msgid ""
 "\n"
 "Component %d [%p]:\n"
 msgstr ""
-"\n"
-"Composant %d [%p]:\n"
 
 #: src/base/cs_calcium.c:378 src/base/cs_calcium.c:448
 #, c-format
@@ -874,8 +683,6 @@ msgid ""
 "\n"
 "Component %d:\n"
 msgstr ""
-"\n"
-"Composant %d:\n"
 
 #: src/base/cs_calcium.c:380
 #, c-format
@@ -883,8 +690,6 @@ msgid ""
 "Reading up to %d values of type %s, time_dependency %s\n"
 "              (min/max time %f/%f, iteration %d) ..."
 msgstr ""
-"Lecture d'au plus %d valeurs de type %s, dep_temps %s\n"
-"              (temps min/max %f/%f, itération %d) ..."
 
 #: src/base/cs_calcium.c:410
 #, c-format
@@ -892,8 +697,6 @@ msgid ""
 "[ok]\n"
 "Read          %d values (min time %f, iteration %d).\n"
 msgstr ""
-"[ok]\n"
-"Lu            %d valeurs (temps min %f, itération %d).\n"
 
 #: src/base/cs_calcium.c:450
 #, c-format
@@ -901,23 +704,21 @@ msgid ""
 "Writing %d values of type %s, time_dependency %s\n"
 "        (time %f, iteration %d) ..."
 msgstr ""
-"Écriture de %d valeurs de type %s, dep_temps %s\n"
-"        (temps %f, itération %d) ..."
 
 #: src/base/cs_calcium.c:475 src/base/cs_sat_coupling.c:276
 #: src/base/cs_syr4_coupling.c:210
 msgid "[ok]\n"
-msgstr "[ok]\n"
+msgstr ""
 
 #: src/base/cs_calcium.c:678
 #, c-format
 msgid "Error calling dlsym: %s\n"
-msgstr "Erreur à l'appel de dlsym : %s\n"
+msgstr ""
 
 #: src/base/cs_calcium.c:1184
 #, c-format
 msgid "Error loading %s: %s."
-msgstr "Erreur au chargement de %s : %s."
+msgstr ""
 
 #: src/base/cs_calcium.c:1221
 #, c-format
@@ -925,8 +726,6 @@ msgid ""
 "Shared library support not available.\n"
 "Unable to load: %s\n"
 msgstr ""
-"Support de librairies partagées non disponible.\n"
-"Impossible de charger : %s\n"
 
 #: src/base/cs_coupling.c:123
 msgid ""
@@ -935,9 +734,6 @@ msgid ""
 "------------------------------------\n"
 "\n"
 msgstr ""
-"\n"
-"Applications accessibles grâce à MPI :\n"
-"--------------------------------------\n"
 
 #: src/base/cs_coupling.c:150
 #, c-format
@@ -947,12 +743,8 @@ msgid ""
 "     lead rank: %d; n_ranks: %d\n"
 "\n"
 msgstr ""
-"  %d; type :        \"%s\"%s\n"
-"     nom de cas :  \"%s\"\n"
-"     rang racine : %d ; nb_rangs : %d\n"
-"\n"
 
-#: src/base/cs_ext_neighborhood.c:1005
+#: src/base/cs_ext_neighborhood.c:1007
 msgid ""
 "\n"
 "WARNING\n"
@@ -962,32 +754,18 @@ msgid ""
 "cases (1D mesh). Verify that it is your case, otherwise\n"
 "contact support.\n"
 msgstr ""
-"\n"
-"ATTENTION\n"
-"Le voisinage étendu est nul alors que la méthode de calcul\n"
-"des gradients par moindres carrés sur support étendu est\n"
-"activée. Ceci peut arriver dans certains cas spécifiques\n"
-"(maillage 1D). Vérifiez que c'est bien votre cas, sinon\n"
-"contactez le support.\n"
 
-#: src/base/cs_ext_neighborhood.c:1162
+#: src/base/cs_ext_neighborhood.c:1163
 #, c-format
 msgid ""
 "\n"
 " Extended neighborhood reduced by non-orthogonality\n"
 " --------------------------------------------------\n"
 "\n"
-" Size of complete cell-cell connectivity: %12lu\n"
-" Size of filtered cell-cell conectivity:  %12lu\n"
-" %lu connections removed, for a ratio of %4.2g %% used\n"
+" Size of complete cell-cell connectivity: %12llu\n"
+" Size of filtered cell-cell conectivity:  %12llu\n"
+" %llu connections removed, for a ratio of %4.2g %% used\n"
 msgstr ""
-"\n"
-" Limitation du voisinage étendu par non-orthogonalité\n"
-" ----------------------------------------------------\n"
-"\n"
-" Taille de la connectivité cellules-cellules complète : %12lu\n"
-" Taille de la connectivité cellules-cellules filtrée :  %12lu\n"
-" %lu connexions supprimées, soit un ratio de %4.2g %% utilisées\n"
 
 #: src/base/cs_gradient.c:598
 #, c-format
@@ -995,8 +773,6 @@ msgid ""
 " GRADIENT LIMITATION in %10d cells\n"
 "    MINIMUM FACTOR = %14.5e; MAXIMUM FACTOR = %14.5e\n"
 msgstr ""
-" LIMITATION DE GRADIENT en %10d CELLULES\n"
-"    FACTEUR MINIMUM = %14.5e ; FACTEUR MAXIMUM = %14.5e\n"
 
 #: src/base/cs_grid.c:876
 #, c-format
@@ -1004,24 +780,22 @@ msgid ""
 "Connectivity error:\n"
 "Face %d has same cell %d on both sides."
 msgstr ""
-"Erreur de connectivité :\n"
-"La face %d voit la cellule %d des deux cotés."
 
 #: src/base/cs_gui_boundary_conditions.c:472
 #, c-format
 msgid "Invalid number of coal-> dp_FCP: %i xml: %i\n"
 msgstr ""
 
-#: src/base/cs_gui_boundary_conditions.c:577 src/base/cs_gui.c:4809
-#: src/base/cs_gui.c:4857 src/base/cs_gui.c:4905 src/base/cs_gui.c:4953
-#: src/base/cs_gui.c:5027 src/base/cs_gui_mobile_mesh.c:281
+#: src/base/cs_gui_boundary_conditions.c:577 src/base/cs_gui.c:4812
+#: src/base/cs_gui.c:4860 src/base/cs_gui.c:4908 src/base/cs_gui.c:4956
+#: src/base/cs_gui.c:5030 src/base/cs_gui_mobile_mesh.c:281
 #, c-format
 msgid "Error: can not interprete expression: %s\n"
 msgstr ""
 
-#: src/base/cs_gui_boundary_conditions.c:583 src/base/cs_gui.c:4813
-#: src/base/cs_gui.c:4861 src/base/cs_gui.c:4909 src/base/cs_gui.c:4957
-#: src/base/cs_gui.c:5031 src/base/cs_gui_mobile_mesh.c:291
+#: src/base/cs_gui_boundary_conditions.c:583 src/base/cs_gui.c:4816
+#: src/base/cs_gui.c:4864 src/base/cs_gui.c:4912 src/base/cs_gui.c:4960
+#: src/base/cs_gui.c:5034 src/base/cs_gui_mobile_mesh.c:291
 #, c-format
 msgid "Error: can not find the required symbol: %s\n"
 msgstr ""
@@ -1062,10 +836,6 @@ msgid ""
 "\"%s\"\n"
 " does not correspond to any boundary face.\n"
 msgstr ""
-"Le groupe ou attribut \"%s\" figurant dans le\n"
-"critère de sélection:\n"
-"\"%s\"\n"
-" ne correspond à aucune face de bord.\n"
 
 #: src/base/cs_gui_boundary_conditions.c:1680
 #: src/base/cs_gui_boundary_conditions.c:1843
@@ -1165,49 +935,49 @@ msgid ""
 " label not found"
 msgstr ""
 
-#: src/base/cs_gui.c:2630
+#: src/base/cs_gui.c:2633
 #, c-format
 msgid "Invalid turbulence model: %s.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:2740
+#: src/base/cs_gui.c:2743
 #, c-format
 msgid "Scalar: %i and its variance: %i are the same.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3102
+#: src/base/cs_gui.c:3105
 #, c-format
 msgid ""
 "The kernel variables number %i and the calculated one by the GUI %i are not "
 "the same.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3550
+#: src/base/cs_gui.c:3553
 msgid "Specific heat value is zero or not found in the xml file.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3571
+#: src/base/cs_gui.c:3574
 msgid "mass molar value is zero or not found in the xml file.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3579
+#: src/base/cs_gui.c:3582
 msgid "Density value is zero or not found in the xml file.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:3835 src/base/cs_gui_radiative_transfer.c:744
+#: src/base/cs_gui.c:3838 src/base/cs_gui_radiative_transfer.c:744
 #: src/base/cs_gui_specific_physics.c:532
 #, c-format
 msgid "number of properties is not correct: %i instead of: %i\n"
 msgstr ""
 
-#: src/base/cs_gui.c:4212 src/base/cs_gui_particles.c:782
+#: src/base/cs_gui.c:4215 src/base/cs_gui_particles.c:782
 #: src/base/cs_gui_particles.c:788 src/base/cs_gui_particles.c:794
 #: src/base/cs_gui_radiative_transfer.c:845
 #, c-format
 msgid "Name of variable %i was never set.\n"
 msgstr ""
 
-#: src/base/cs_gui.c:4293 src/base/cs_selector.c:315
+#: src/base/cs_gui.c:4296 src/base/cs_selector.c:315
 #, c-format
 msgid ""
 "The group or attribute \"%s\" in the selection\n"
@@ -1215,12 +985,8 @@ msgid ""
 "\"%s\"\n"
 " does not correspond to any cell.\n"
 msgstr ""
-"Le groupe ou attribut \"%s\" figurant dans le\n"
-"critère de sélection:\n"
-"\"%s\"\n"
-" ne correspond à aucune cellule.\n"
 
-#: src/base/cs_gui.c:5211 src/base/cs_gui_util.c:159
+#: src/base/cs_gui.c:5214 src/base/cs_gui_util.c:159
 #, c-format
 msgid "Unable to open the file: %s\n"
 msgstr ""
@@ -1273,7 +1039,7 @@ msgstr ""
 #: src/base/cs_gui_radiative_transfer.c:306
 #, c-format
 msgid "unknow type %s\n"
-msgstr "type inconnu %s \n"
+msgstr ""
 
 #: src/base/cs_gui_radiative_transfer.c:395
 #, c-format
@@ -1417,12 +1183,6 @@ msgid ""
 "The first 64 bytes read contain:\n"
 "\"%s\"\n"
 msgstr ""
-"Erreur à la lecture du fichier : \"%s\".\n"
-"Le format du fichier n'est pas à la bonne version.\n"
-"Les 64 premiers octets attendus contiennent :\n"
-"\"%s\"\n"
-"Les 64 premiers octets lus contiennent :\n"
-"\"%s\"\n"
 
 #: src/base/cs_io.c:651
 #, c-format
@@ -1432,15 +1192,11 @@ msgid ""
 "\"%s\" was expected,\n"
 "\"%s\" was read."
 msgstr ""
-"Erreur à la lecture du fichier : \"%s.\n"
-"Le contenu du fichier n'est pas du type attendu.\n"
-"On attendait \"%s\"\n"
-"On a lu \"%s\"."
 
 #: src/base/cs_io.c:698
 #, c-format
 msgid "Error writing the header of file: \"%s\".\n"
-msgstr "Erreur à l'écriture de l'entête du fichier : \"%s\".\n"
+msgstr ""
 
 #: src/base/cs_io.c:847
 #, c-format
@@ -1448,8 +1204,6 @@ msgid ""
 "Restart file \"%s\"\n"
 "in format 1.1 is not conforming."
 msgstr ""
-"Le fichier suite \"%s\"\n"
-"au format 1.1 n'est pas conforme."
 
 #: src/base/cs_io.c:896
 #, c-format
@@ -1457,8 +1211,6 @@ msgid ""
 "Restart file \"%s\" does not correspond\n"
 "to part %d of the original restart file."
 msgstr ""
-"Le fichier suite \"%s\" ne correspond pas\n"
-"à la partie %d du fichier suite d'origine."
 
 #: src/base/cs_io.c:1125
 #, c-format
@@ -1466,8 +1218,6 @@ msgid ""
 "\n"
 "  Section read on \"%s\":\n"
 msgstr ""
-"\n"
-"  Section lue sur \"%s\" :\n"
 
 #: src/base/cs_io.c:1130
 #, c-format
@@ -1475,217 +1225,180 @@ msgid ""
 "\n"
 "  Section written on \"%s\":\n"
 msgstr ""
-"\n"
-"  Section écrite sur \"%s\" :\n"
 
 #: src/base/cs_io.c:1159
 #, c-format
 msgid ""
 "    section name:           \"%s\"\n"
-"    number of elements:     %lu\n"
+"    number of elements:     %llu\n"
 msgstr ""
-"    nom de la rubrique :    \"%s\"\n"
-"    nombre d'éléments :     %lu\n"
 
 #: src/base/cs_io.c:1194 src/base/cs_syr3_comm.c:849
 #, c-format
 msgid "    element type name:      \"%s\"\n"
-msgstr "    nom du type d'élément : \"%s\"\n"
+msgstr ""
 
 #: src/base/cs_io.c:1238
 msgid " (local)"
-msgstr " (locaux)"
+msgstr ""
 
 #: src/base/cs_io.c:1259
 #, c-format
 msgid "    %d first and last elements%s:\n"
-msgstr "    %d premiers et derniers éléments%s :\n"
+msgstr ""
 
 #: src/base/cs_io.c:1264
 #, c-format
 msgid "    elements%s:\n"
-msgstr "    éléments%s :\n"
+msgstr ""
 
-#: src/base/cs_io.c:1812 src/base/cs_io.c:1989 src/base/cs_io.c:3001
-#: src/base/cs_io.c:3088
+#: src/base/cs_io.c:1812 src/base/cs_io.c:1989 src/base/cs_io.c:3006
+#: src/base/cs_io.c:3093
 #, c-format
-msgid "Error writing %lu bytes to file \"%s\"."
-msgstr "Erreur à l'écriture de %lu octets dans le fichier \"%s\"."
+msgid "Error writing %llu bytes to file \"%s\"."
+msgstr ""
 
 #: src/base/cs_io.c:2012
 #, c-format
 msgid ""
-" %lu indexed records:\n"
+" %llu indexed records:\n"
 "   (name, n_vals, location_id, index_id, n_loc_vals, type, embed, file_id, "
 "offset)\n"
 "\n"
 msgstr ""
-" %lu sections indexées :\n"
-"   (nom, n_vals, id_support, id_index, n_vals_loc, type, inclus, id_fichier, "
-"position)\n"
-"\n"
 
-#: src/base/cs_io.c:2025
+#: src/base/cs_io.c:2026
 #, c-format
-msgid " %40s %10lu %2u %2u %2u %6s %c %2u %ld\n"
+msgid " %40s %10llu %2u %2u %2u %6s %c %2u %ld\n"
 msgstr ""
 
-#: src/base/cs_io.c:2034
+#: src/base/cs_io.c:2035
 #, c-format
 msgid ""
 "\n"
 " %u associated file(s):\n"
 msgstr ""
-"\n"
-" %u fichier(s) associé(s):\n"
 
-#: src/base/cs_io.c:2037
+#: src/base/cs_io.c:2038
 #, c-format
 msgid "  \"%s\"\n"
-msgstr "  \"%s\"\n"
+msgstr ""
 
-#: src/base/cs_io.c:2087 src/base/cs_io.c:2143
+#: src/base/cs_io.c:2088 src/base/cs_io.c:2144
 #, c-format
 msgid ""
 "\n"
 " Reading file:        %s\n"
 msgstr ""
-"\n"
-" Lecture du fichier :  %s\n"
 
-#: src/base/cs_io.c:2089
+#: src/base/cs_io.c:2090
 #, c-format
 msgid ""
 "\n"
 " Writing file:        %s\n"
 msgstr ""
-"\n"
-" Écriture du fichier : %s\n"
 
-#: src/base/cs_io.c:2200
+#: src/base/cs_io.c:2201
 #, c-format
 msgid " Finished reading:    %s\n"
-msgstr " Fin de la lecture :  %s\n"
+msgstr ""
 
-#: src/base/cs_io.c:2203
+#: src/base/cs_io.c:2204
 #, c-format
 msgid " Finished writing:    %s\n"
-msgstr " Fin de l'écriture :  %s\n"
+msgstr ""
 
-#: src/base/cs_io.c:2469
+#: src/base/cs_io.c:2470
 #, c-format
 msgid ""
 "Type \"%s\" is not known\n"
 "Known types: \"c \", \"i4\", \"i8\", \"u4\", \"u8\", \"r4\", \"r8\"."
 msgstr ""
-"Type \"%s\" inconnu\n"
-"Types connus : \"c \", \"i4\", \"i8\", \"u4\", \"u8\", \"r4\", \"r8\"."
 
-#: src/base/cs_io.c:2525
+#: src/base/cs_io.c:2526
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
 "Data type \"%s\" is not recognized."
 msgstr ""
-"Erreur à la lecture du fichier : \"%s\".\n"
-"Le type de données \"%s\" n'est pas reconnu."
 
-#: src/base/cs_io.c:2634
+#: src/base/cs_io.c:2639
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
 "Type expected for section: \"%s\" is a signed integer\n"
 "and is not convertible from type read: \"%s\"."
 msgstr ""
-"Erreur à la lecture du fichier : \"%s\".\n"
-"Le type attendu pour la section : \n"
-"\"%s\" est un entier signé\n"
-"et n'est pas convertible à partir du type lu : \"%s\"."
 
-#: src/base/cs_io.c:2669
+#: src/base/cs_io.c:2674
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
 "Type expected for section: \"%s\" is an unsigned integer\n"
 "and is not convertible from type read: \"%s\"."
 msgstr ""
-"Erreur à la lecture du fichier : \"%s\".\n"
-"Le type attendu pour la section : \n"
-"\"%s\" est un entier non signé\n"
-"et n'est pas convertible à partir du type lu : \"%s\"."
 
-#: src/base/cs_io.c:2700
+#: src/base/cs_io.c:2705
 #, c-format
 msgid ""
 "Error reading file: \"%s\".\n"
 "Type expected for section: \"%s\"\n"
 "is \"r4\" or \"r8\" (real), and not \"%s\"."
 msgstr ""
-"Erreur à la lecture du fichier : \"%s\".\n"
-"Le type attendu pour la section : \"%s\"\n"
-"est \"r4\" ou \"r8\" (réel), et non \"%s\"."
 
-#: src/base/cs_io.c:2936
+#: src/base/cs_io.c:2941
 #, c-format
 msgid ""
 "    first element for next rank:\n"
-"    %10lu : %12d\n"
+"    %10llu : %12llu\n"
 msgstr ""
-"    premier élement rang suivant :\n"
-"    %10lu : %12d\n"
 
-#: src/base/cs_io.c:3106
+#: src/base/cs_io.c:3111
 #, c-format
 msgid "  I/O mode:          %s\n"
-msgstr "  mode E/S :          %s\n"
+msgstr ""
 
-#: src/base/cs_io.c:3112
+#: src/base/cs_io.c:3117
 msgid "MPI-IO, explicit offsets"
-msgstr "MPI-IO, positions explicites"
+msgstr ""
 
-#: src/base/cs_io.c:3116
+#: src/base/cs_io.c:3121
 msgid "MPI-IO, individual file pointers"
-msgstr "MPI-IO, pointeurs de fichiers individuels"
+msgstr ""
 
-#: src/base/cs_io.c:3120
+#: src/base/cs_io.c:3125
 msgid ""
 "serial IO\n"
 "\n"
 msgstr ""
-"ES série\n"
-"\n"
 
-#: src/base/cs_io.c:3169
+#: src/base/cs_io.c:3174
 msgid ""
 "\n"
 "\n"
 " file contents:\n"
 "\n"
 msgstr ""
-"\n"
-"\n"
-" contenu du fichier :\n"
-"\n"
 
-#: src/base/cs_io.c:3172
+#: src/base/cs_io.c:3177
 #, c-format
 msgid "  file: %s\n"
-msgstr "  fichier : %s\n"
+msgstr ""
 
-#: src/base/cs_io.c:3174
+#: src/base/cs_io.c:3179
 #, c-format
 msgid "  contents: \"%s\"\n"
-msgstr "  contenu : \"%s\"\n"
+msgstr ""
 
-#: src/base/cs_io.c:3176
+#: src/base/cs_io.c:3181
 msgid "  mode: CS_IO_MODE_READ\n"
-msgstr "  mode : CS_IO_MODE_READ\n"
+msgstr ""
 
-#: src/base/cs_io.c:3178
+#: src/base/cs_io.c:3183
 msgid "  mode: CS_IO_MODE_WRITE\n"
-msgstr "  mode : CS_IO_MODE_WRITE\n"
+msgstr ""
 
-#: src/base/cs_io.c:3180
+#: src/base/cs_io.c:3185
 #, c-format
 msgid ""
 "  default header size: %lu\n"
@@ -1694,43 +1407,23 @@ msgid ""
 "  verbosity level:     %ld\n"
 "\n"
 msgstr ""
-"  taille d'en-tête par défaut : %lu\n"
-"  alignement des en-têtes :     %lu\n"
-"  alignement des corps :        %lu\n"
-"  niveau d'impression :         %ld\n"
-"\n"
-
-#: src/base/cs_join.c:440
-#, c-format
-msgid "  Tolerance computation mode (%d) is not defined\n"
-msgstr ""
-
-#: src/base/cs_join.c:646
-#, c-format
-msgid ""
-"Incompatible value for the \"fraction\" parameter.\n"
-"Value must be lower than 1.0 or greater than 0.0\n"
-"The current value is : %f\n"
-msgstr ""
 
-#: src/base/cs_join.c:731
-#, c-format
+#: src/base/cs_join.c:209
 msgid ""
-"Incompatible value for the \"vertex tolerance\" parameter\n"
-"Value must be lower than DBL_MAX and current value is : %f (global "
-"numbering : %u)\n"
+"\n"
+"  Element selection successfully done.\n"
 msgstr ""
 
-#: src/base/cs_join.c:758
+#: src/base/cs_join.c:288
 #, c-format
 msgid ""
-"  Global number of selected vertices: %11lu\n"
 "\n"
+"  Sorting possible intersections between faces:\n"
+"      wall clock time:            %10.3g\n"
+"      CPU time:                   %10.3g\n"
 msgstr ""
-"  Nombre global de sommets sélectionnés : %11lu\n"
-"\n"
 
-#: src/base/cs_join.c:793
+#: src/base/cs_join.c:417
 #, c-format
 msgid ""
 "\n"
@@ -1738,25 +1431,8 @@ msgid ""
 "        wall clock time:            %10.3g\n"
 "        CPU time:                   %10.3g\n"
 msgstr ""
-"\n"
-"    Définition du maillage de recollement local :\n"
-"        temps écoulé :              %10.3g\n"
-"        temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:879
-#, c-format
-msgid ""
-"\n"
-"  Sorting possible intersections between faces:\n"
-"      wall clock time:            %10.3g\n"
-"      CPU time:                   %10.3g\n"
-msgstr ""
-"\n"
-"  Tri des intersection possibles entre faces:\n"
-"      temps écoulé :              %10.3g\n"
-"      temps CPU :                 %10.3g\n"
-
-#: src/base/cs_join.c:1030
+#: src/base/cs_join.c:459
 #, c-format
 msgid ""
 "\n"
@@ -1764,28 +1440,20 @@ msgid ""
 "      wall clock time:            %10.3g\n"
 "      CPU time:                   %10.3g\n"
 msgstr ""
-"\n"
-"  Définition de structures pour l'algorithme de recollement :\n"
-"      temps écoulé :              %10.3g\n"
-"      temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1138
+#: src/base/cs_join.c:566
 msgid ""
 "\n"
 "  Joining operation is conforming.\n"
 msgstr ""
-"\n"
-"  L'opération de recollement est conforme.\n"
 
-#: src/base/cs_join.c:1148
+#: src/base/cs_join.c:576
 msgid ""
 "\n"
 "  Joining operation is non-conforming.\n"
 msgstr ""
-"\n"
-"  L'opération de recollement est non-conforme.\n"
 
-#: src/base/cs_join.c:1220
+#: src/base/cs_join.c:649
 #, c-format
 msgid ""
 "\n"
@@ -1793,12 +1461,8 @@ msgid ""
 "    wall clock time:            %10.3g\n"
 "    CPU time:                   %10.3g\n"
 msgstr ""
-"\n"
-"  Intersections d'arêtes et création de sommets :\n"
-"    temps écoulé :              %10.3g\n"
-"    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1356
+#: src/base/cs_join.c:1089
 #, c-format
 msgid ""
 "\n"
@@ -1806,12 +1470,8 @@ msgid ""
 "    wall clock time:            %10.3g\n"
 "    CPU time:                   %10.3g\n"
 msgstr ""
-"\n"
-"  Fusion des sommets :\n"
-"    temps écoulé :              %10.3g\n"
-"    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1431
+#: src/base/cs_join.c:1238
 #, c-format
 msgid ""
 "\n"
@@ -1819,87 +1479,27 @@ msgid ""
 "    wall clock time:            %10.3g\n"
 "    CPU time:                   %10.3g\n"
 msgstr ""
-"\n"
-"  Découpage des anciennes faces et reconstruction de nouvelles faces\n"
-"    temps écoulé :              %10.3g\n"
-"    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:1594
+#: src/base/cs_join.c:1378
 #, c-format
 msgid "  Join number %d is not defined.\n"
-msgstr "  Le recollement numéro %d n'est pas défini.\n"
+msgstr ""
 
-#: src/base/cs_join.c:1641
+#: src/base/cs_join.c:1421 src/base/cs_join_perio.c:220
 #, c-format
 msgid ""
 "Mesh joining:  Forbidden value for the fraction parameter.\n"
 "  It must be between [0.0, 1.0[ and is here: %f\n"
 msgstr ""
 
-#: src/base/cs_join.c:1648
+#: src/base/cs_join.c:1428 src/base/cs_join_perio.c:227
 #, c-format
 msgid ""
 "Mesh joining:  Forbidden value for the plane parameter.\n"
 "  It must be between [0, 90] and is here: %f\n"
 msgstr ""
 
-#: src/base/cs_join.c:1707
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tml parameter.\n"
-"  It must be between > 0 and is here: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1718
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tmb parameter.\n"
-"  It must be between > 0 and is here: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1729
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tmr parameter.\n"
-"  It must be between > 0.0 and is here: %f\n"
-msgstr ""
-
-#: src/base/cs_join.c:1744
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the merge tolerance factor.\n"
-"  It must be positive or nul and not: %f\n"
-msgstr ""
-
-#: src/base/cs_join.c:1754
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the max. number of tolerance breaks.\n"
-"  It must be between >= 0 and not: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1771
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the tcm parameter.\n"
-"  It must be between 1, 2 or 11, 12 and here is: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1781
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for icm parameter.\n"
-"  It must be 1 or 2 and here is: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1791
-#, c-format
-msgid ""
-"Mesh joining:  Forbidden value for the maxsf parameter.\n"
-"  It must be between > 0 and here is: %d\n"
-msgstr ""
-
-#: src/base/cs_join.c:1839
+#: src/base/cs_join.c:1486
 #, c-format
 msgid ""
 "\n"
@@ -1907,17 +1507,20 @@ msgid ""
 "  Joining number %d:\n"
 "\n"
 msgstr ""
+
+#: src/base/cs_join.c:1490
+#, c-format
+msgid ""
 "\n"
-" -------------------------------------------------------\n"
-"  Recollement numéro %d :\n"
-"\n"
+"  Joining for periodicity: %d\n"
+msgstr ""
 
-#: src/base/cs_join.c:1841
+#: src/base/cs_join.c:1492
 #, c-format
 msgid "  Selection criteria: \"%s\"\n"
-msgstr "  Critère de sélection : \"%s\"\n"
+msgstr ""
 
-#: src/base/cs_join.c:1844
+#: src/base/cs_join.c:1495
 #, c-format
 msgid ""
 "\n"
@@ -1926,16 +1529,12 @@ msgid ""
 "    Maximum angle between joined face planes: %8.5f\n"
 "\n"
 msgstr ""
-"\n"
-"  Paramètres de recollement :\n"
-"    Fraction de la plus petite arête incidente :        %8.5f\n"
-"    Angle maximum entre plans de faces recollées :      %8.5f\n"
-"\n"
 
-#: src/base/cs_join.c:1851
+#: src/base/cs_join.c:1501
 #, c-format
 msgid ""
-"  Advanced join parameters:\n"
+"  Advanced joining parameters:\n"
+"    Verbosity level:                          %8d\n"
 "    Deepest level reachable in tree building: %8d\n"
 "    Max boxes by leaf:                        %8d\n"
 "    Max ratio of linked boxes / init. boxes:  %8.5f\n"
@@ -1948,32 +1547,28 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/base/cs_join.c:1870
+#: src/base/cs_join.c:1522
 msgid " Before joining"
-msgstr " Avant recollement"
-
-#: src/base/cs_join.c:1919
-msgid ""
-"\n"
-"  Element selection successfully done.\n"
 msgstr ""
 
-#: src/base/cs_join.c:1962
+#: src/base/cs_join.c:1559
 #, c-format
 msgid ""
 "\n"
 "  Number of faces to treat locally: %10d\n"
 msgstr ""
 
-#: src/base/cs_join.c:2036
+#: src/base/cs_join.c:1641
 msgid ""
 "\n"
 "Stop joining algorithm: no face selected...\n"
 msgstr ""
-"\n"
-"Arrêt du recollement: aucune face sélectionnée...\n"
 
-#: src/base/cs_join.c:2045
+#: src/base/cs_join.c:1649
+msgid " After joining"
+msgstr ""
+
+#: src/base/cs_join.c:1656
 #, c-format
 msgid ""
 "\n"
@@ -1981,16 +1576,8 @@ msgid ""
 "    wall clock time:            %10.3g\n"
 "    CPU time:                   %10.3g\n"
 msgstr ""
-"\n"
-"  Traitement pour le recollement %2d terminé\n"
-"    temps écoulé :              %10.3g\n"
-"    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join.c:2074
-msgid " After joining"
-msgstr " Après recollement"
-
-#: src/base/cs_join.c:2092
+#: src/base/cs_join.c:1684
 #, c-format
 msgid ""
 "\n"
@@ -2001,15 +1588,8 @@ msgid ""
 "    CPU time:                   %10.3g\n"
 "\n"
 msgstr ""
-"\n"
-"  Fin des étapes de recollement :\n"
-"\n"
-"  Temps associés :\n"
-"    temps écoulé :              %10.3g\n"
-"    temps CPU :                 %10.3g\n"
-"\n"
 
-#: src/base/cs_join_intersect.c:399
+#: src/base/cs_join_intersect.c:400
 #, c-format
 msgid ""
 "\n"
@@ -2019,30 +1599,27 @@ msgid ""
 "  Intersection found for curv. abs. %f (e1) - %f (e2) will be ignored.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:414
+#: src/base/cs_join_intersect.c:415
 #, c-format
 msgid ""
 " Failure for edge 1:  Distance [v_inter1, v_inter2]: %e > v_inter1.tol: %e\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:418
+#: src/base/cs_join_intersect.c:419
 #, c-format
 msgid ""
 " Failure for edge 2:  Distance [v_inter1, v_inter2]: %e > v_inter2.tol: %e\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:2177
+#: src/base/cs_join_intersect.c:2186
 #, c-format
 msgid ""
 "  Determination of possible face intersections:\n"
 "\n"
 "    bounding-box tree layout: %dD\n"
 msgstr ""
-"  Détermination des intersections possibles entre faces :\n"
-"\n"
-"    répartition de l'arbre de boîtes englobantes : %dD\n"
 
-#: src/base/cs_join_intersect.c:2184
+#: src/base/cs_join_intersect.c:2193
 #, c-format
 msgid ""
 "                                   rank mean      minimum      maximum\n"
@@ -2056,18 +1633,8 @@ msgid ""
 "      temporary search structure: %10lu | %10lu | %10lu\n"
 "\n"
 msgstr ""
-"                               moyenne des rangs      minimum      maximum\n"
-"    profondeur :                      %10d | %10d | %10d\n"
-"    nombre de feuilles :              %10lu | %10lu | %10lu\n"
-"    nombre de boîtes :                %10lu | %10lu | %10lu\n"
-"    feuilles au-dessus du seuil :     %10lu | %10lu | %10lu\n"
-"    boîtes par feuilles :             %10d | %10d | %10d\n"
-"    Empreinte mémoire (ko):\n"
-"      structure de recherche finale : %10lu | %10lu | %10lu\n"
-"      structure intermédiaire :       %10lu | %10lu | %10lu\n"
-"\n"
 
-#: src/base/cs_join_intersect.c:2207
+#: src/base/cs_join_intersect.c:2216
 #, c-format
 msgid ""
 "    depth:                        %10d\n"
@@ -2080,40 +1647,27 @@ msgid ""
 "      temporary search structure: %10lu\n"
 "\n"
 msgstr ""
-"    profondeur :                      %10d\n"
-"    nombre de feuilles :              %10lu\n"
-"    nombre de boîtes :                %10lu\n"
-"    feuilles au-dessus du seuil :     %10lu\n"
-"    boîtes par feuille :              %10d moyenne [%d min, %d max]\n"
-"    Empreinte mémoire (ko) :\n"
-"      structure de recherche finale : %10lu\n"
-"      structure intermédiaire :       %10lu\n"
-"\n"
 
-#: src/base/cs_join_intersect.c:2219
+#: src/base/cs_join_intersect.c:2228
 #, c-format
 msgid ""
 "    Associated times:           construction        query\n"
 "      wall clock time:            %10.3g   %10.3g\n"
 msgstr ""
-"    Temsp associés:             construction        requête\n"
-"      wall clock time:            %10.3g   %10.3g\n"
 
-#: src/base/cs_join_intersect.c:2236
+#: src/base/cs_join_intersect.c:2245
 #, c-format
 msgid ""
 "      Min local CPU time:         %10.3g   %10.3g\n"
 "      Max local CPU time:         %10.3g   %10.3g\n"
 msgstr ""
-"      temps CPU local min :       %10.3g   %10.3g\n"
-"      temps CPU local max :       %10.3g   %10.3g\n"
 
-#: src/base/cs_join_intersect.c:2244
+#: src/base/cs_join_intersect.c:2253
 #, c-format
 msgid "      CPU time:                   %10.3g   %10.3g\n"
-msgstr "      temps CPU :                 %10.3g   %10.3g\n"
+msgstr ""
 
-#: src/base/cs_join_intersect.c:2515
+#: src/base/cs_join_intersect.c:2524
 #, c-format
 msgid ""
 "\n"
@@ -2122,7 +1676,7 @@ msgid ""
 "   Vertex %d (%u) of abscissa: %f is before vertex %d (%u) of abscissa: %f\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:2526
+#: src/base/cs_join_intersect.c:2535
 #, c-format
 msgid ""
 "\n"
@@ -2133,38 +1687,39 @@ msgid ""
 "  Vertex %d appears twice.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:2752
+#: src/base/cs_join_intersect.c:2665 src/base/cs_join_intersect.c:2682
+msgid "  Vertex number out of bounds.\n"
+msgstr ""
+
+#: src/base/cs_join_intersect.c:2782
 #, c-format
 msgid ""
 "\n"
-"  Equivalences broken for %lu edges.\n"
+"  Equivalences broken for %llu edges.\n"
 msgstr ""
-"\n"
-"  Equivalences cassées pour %lu éléments.\n"
 
-#: src/base/cs_join_intersect.c:2758
+#: src/base/cs_join_intersect.c:2788
 #, c-format
 msgid ""
 "\n"
-"  Max. number of equiv. breaks: %lu\n"
+"  Max. number of equiv. breaks: %llu\n"
 msgstr ""
-"\n"
-"  Nombre max d'équivalences cassées : %lu\n"
 
-#: src/base/cs_join_intersect.c:3377
+#: src/base/cs_join_intersect.c:3409
 #, c-format
 msgid ""
 "  The received edge global number (%u) is unknown on the current rank.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:3489
+#: src/base/cs_join_intersect.c:3520
 #, c-format
 msgid ""
 "\n"
-"  Add %d new vertices in the %s mesh definition.\n"
+"  Add %d new vertices in the %s mesh definition during update of the edge "
+"definition.\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:3670
+#: src/base/cs_join_intersect.c:3704
 #, c-format
 msgid ""
 "\n"
@@ -2172,28 +1727,22 @@ msgid ""
 "    Vertex-Vertex intersections:    %12lu\n"
 "    Other intersections:            %12lu\n"
 msgstr ""
-"\n"
-"  Nombre local d'intersections détectées :  %12lu\n"
-"    Intersections sommet-sommet :     %12lu\n"
-"    Autres intersections :            %12lu\n"
 
-#: src/base/cs_join_intersect.c:3677
+#: src/base/cs_join_intersect.c:3711
 #, c-format
 msgid ""
 "\n"
 "  Local number of edge-edge intersection warnings:%9d\n"
 msgstr ""
 
-#: src/base/cs_join_intersect.c:3679
+#: src/base/cs_join_intersect.c:3713
 #, c-format
 msgid ""
 "\n"
 "  Local number of equivalences between vertices:%9d\n"
 msgstr ""
-"\n"
-"  Nombre local d'équivalences entre sommets : %9d\n"
 
-#: src/base/cs_join_intersect.c:3689
+#: src/base/cs_join_intersect.c:3723
 #, c-format
 msgid ""
 "\n"
@@ -2201,12 +1750,8 @@ msgid ""
 "    wall clock time:            %10.3g\n"
 "    CPU time:                   %10.3g\n"
 msgstr ""
-"\n"
-"  Intersections d'arêtes (seulement)\n"
-"    temps écoulé :              %10.3g\n"
-"    temps CPU :                 %10.3g\n"
 
-#: src/base/cs_join_merge.c:352
+#: src/base/cs_join_merge.c:348
 #, c-format
 msgid ""
 "  The number of new vertices to create is not consistent.\n"
@@ -2215,7 +1760,7 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:582
+#: src/base/cs_join_merge.c:580
 #, c-format
 msgid ""
 "\n"
@@ -2225,7 +1770,7 @@ msgid ""
 "  Check the fraction parameter.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:687
+#: src/base/cs_join_merge.c:685
 #, c-format
 msgid ""
 "\n"
@@ -2235,96 +1780,86 @@ msgid ""
 "  Check the fraction parameter.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:980
+#: src/base/cs_join_merge.c:978
 #, c-format
 msgid ""
 "\n"
 "  Number of local iterations to converge on vertex equivalences: %3d\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:983
+#: src/base/cs_join_merge.c:981
 #, c-format
 msgid ""
 "  Number of global iterations to converge on vertex equivalences: %3d\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:1431
+#: src/base/cs_join_merge.c:1437
 #, c-format
 msgid ""
 "\n"
-"  Pre-merge for %lu global couple of elements.\n"
+"  Pre-merge for %llu global couple of elements.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:1435
+#: src/base/cs_join_merge.c:1441
 #, c-format
 msgid ""
 "\n"
 "  Local number of pre-merge: %d\n"
 msgstr ""
-"\n"
-"  Nombre local de pre-fusion: %d\n"
 
-#: src/base/cs_join_merge.c:1938
+#: src/base/cs_join_merge.c:1944
 #, c-format
 msgid " Number of tolerance reductions:  %4d\n"
-msgstr " Nombre de réductions de tolérance : %4d\n"
+msgstr ""
 
-#: src/base/cs_join_merge.c:2041
+#: src/base/cs_join_merge.c:2048
 msgid ""
 "\n"
 "  No need to merge vertices.\n"
 msgstr ""
-"\n"
-"  Pas besoin de fusionner des sommets.\n"
 
-#: src/base/cs_join_merge.c:2045
+#: src/base/cs_join_merge.c:2052
 #, c-format
 msgid ""
 "\n"
-"  Max size of a merge set of vertices: %lu\n"
+"  Max size of a merge set of vertices: %llu\n"
 msgstr ""
-"\n"
-"  Taille max d'un ensemble de fusion de sommets : %lu\n"
 
-#: src/base/cs_join_merge.c:2113
+#: src/base/cs_join_merge.c:2120
 #, c-format
 msgid ""
 "\n"
 "  %3d loop(s) to get consistent subsets\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:2177
+#: src/base/cs_join_merge.c:2184
 #, c-format
 msgid ""
 "\n"
-"  Excessive transitivity for %lu set(s) of vertices.\n"
+"  Excessive transitivity for %llu set(s) of vertices.\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:2183
+#: src/base/cs_join_merge.c:2190
 #, c-format
 msgid ""
 "\n"
-"  Max. number of iterations to solve transitivity excess: %lu\n"
+"  Max. number of iterations to solve transitivity excess: %llu\n"
 msgstr ""
-"\n"
-"  Nombre max d'itérations pour résoudre un excès de transitivité : %lu\n"
 
-#: src/base/cs_join_merge.c:2633
+#: src/base/cs_join_merge.c:2637
 #, c-format
 msgid "  Number of sub-elements to add to edge definition: %8d\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:3052
+#: src/base/cs_join_merge.c:3056
 #, c-format
 msgid ""
 "\n"
-"  Global number of new vertices to create: %10lu\n"
+"  Global number of new vertices to create: %10llu\n"
 msgstr ""
-"\n"
-"  Nombre global de nouveaux sommets à créer : %10lu\n"
 
-#: src/base/cs_join_merge.c:3161
+#: src/base/cs_join_merge.c:3166
 #, c-format
 msgid ""
 "  Inconsistent value found in cs_join_vertex_t struct.:\n"
@@ -2332,15 +1867,15 @@ msgid ""
 "      %u - [%7.4le, %7.4le, %7.4le] - %lg\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:3220
+#: src/base/cs_join_merge.c:3225
 #, c-format
 msgid ""
 "\n"
 "  Final number of equiv. between vertices; local: %9d\n"
-"                                          global: %9lu\n"
+"                                          global: %9llu\n"
 msgstr ""
 
-#: src/base/cs_join_merge.c:3308
+#: src/base/cs_join_merge.c:3313
 #, c-format
 msgid ""
 "\n"
@@ -2348,32 +1883,50 @@ msgid ""
 "              wall clock time:       %10.3g\n"
 "              cpu time:              %10.3g\n"
 msgstr ""
+
+#: src/base/cs_join_mesh.c:459
+#, c-format
+msgid "  Tolerance computation mode (%d) is not defined\n"
+msgstr ""
+
+#: src/base/cs_join_mesh.c:738
+#, c-format
+msgid ""
+"Incompatible value for the \"vertex tolerance\" item\n"
+"Value must be lower than DBL_MAX and current value is : %f (global "
+"numbering : %u)\n"
+msgstr ""
+
+#: src/base/cs_join_mesh.c:764
+#, c-format
+msgid ""
+"  Global number of selected vertices: %11llu\n"
+"\n"
+msgstr ""
+
+#: src/base/cs_join_mesh.c:776
+#, c-format
+msgid ""
+"  Number of selected vertices: %11llu\n"
 "\n"
-"          Fusion des sommets (seulement)\n"
-"              temps écoulé :         %10.3g\n"
-"              temps CPU :            %10.3g\n"
+msgstr ""
 
-#: src/base/cs_join_mesh.c:351 src/base/cs_join_mesh.c:520
+#: src/base/cs_join_mesh.c:998 src/base/cs_join_mesh.c:1166
 #, c-format
 msgid ""
 "  The simplified face has less than 3 vertices.\n"
 "  Check your joining parameters.\n"
 "  Face %d (%u)\n"
 msgstr ""
-"  La face simplifiée a moins de 3 sommets.\n"
-"  Vérifier les paramètres de recollement.\n"
-"  Face %d (%u)\n"
 
-#: src/base/cs_join_mesh.c:367
+#: src/base/cs_join_mesh.c:1014
 #, c-format
 msgid ""
 "\n"
-"  Number of simplified faces: %lu\n"
+"  Number of simplified faces: %llu\n"
 msgstr ""
-"\n"
-"  Nombre de faces simplifiées : %lu\n"
 
-#: src/base/cs_join_mesh.c:595
+#: src/base/cs_join_mesh.c:1240
 #, c-format
 msgid ""
 "\n"
@@ -2382,30 +1935,30 @@ msgid ""
 " Edge number: %d (%u) - (%d, %d) in old numbering.\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:1388
+#: src/base/cs_join_mesh.c:2054
 msgid ""
 "\n"
 "  Local min/max. tolerance:\n"
 "\n"
-"Glob. Num.  |  Tolerance  |        Coordinates\n"
+" Glob. Num. |  Tolerance  |              Coordinates\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:1412
+#: src/base/cs_join_mesh.c:2078
 msgid ""
 "\n"
 "  Global min/max. tolerance:\n"
 "\n"
-"Glob. Num.  |  Tolerance  |        Coordinates\n"
+" Glob. Num. |  Tolerance  |              Coordinates\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:2598
+#: src/base/cs_join_mesh.c:3259
 #, c-format
 msgid ""
 " The given vertex number: %d is not defined in the edge structure (edges-"
 ">vtx_idx).\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:2610
+#: src/base/cs_join_mesh.c:3271
 #, c-format
 msgid ""
 " The given couple of vertex numbers :\n"
@@ -2414,17 +1967,17 @@ msgid ""
 " is not defined in the edge structure.\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:2704
+#: src/base/cs_join_mesh.c:3365
 #, c-format
 msgid ""
-" Problem in mesh connectivity. Face: %lu\n"
+" Problem in mesh connectivity. Face: %llu\n"
 " Problem detected during connectivity update:\n"
 " The face is defined by less than 3 points (excessive merging has occured).\n"
 "\n"
 " Modify joining parameters to reduce merging (fraction & merge).\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3161 src/base/cs_join_mesh.c:3274
+#: src/base/cs_join_mesh.c:3822 src/base/cs_join_mesh.c:3935
 #, c-format
 msgid ""
 "\n"
@@ -2432,7 +1985,7 @@ msgid ""
 "  -- Dump a cs_join_mesh_t structure: (%p) --\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3166 src/base/cs_join_mesh.c:3279
+#: src/base/cs_join_mesh.c:3827 src/base/cs_join_mesh.c:3940
 #, c-format
 msgid ""
 "\n"
@@ -2440,29 +1993,29 @@ msgid ""
 "  -- Dump a cs_join_mesh_t structure: %s (%p) --\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3168
+#: src/base/cs_join_mesh.c:3829
 #, c-format
 msgid ""
 "\n"
 " mesh->n_faces:       %9d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3169 src/base/cs_join_mesh.c:3282
+#: src/base/cs_join_mesh.c:3830 src/base/cs_join_mesh.c:3943
 #, c-format
 msgid ""
 " mesh->n_g_faces:   %11u\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3178
+#: src/base/cs_join_mesh.c:3839
 #, c-format
 msgid ""
 "\n"
-" face_id: %5d gnum: %9u - n_vertices: %4d\n"
+" face_id: %5d gnum: %9u n_vertices: %4d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3201 src/base/cs_join_mesh.c:3219
-#: src/base/cs_join_mesh.c:3314 src/base/cs_join_mesh.c:3333
+#: src/base/cs_join_mesh.c:3862 src/base/cs_join_mesh.c:3880
+#: src/base/cs_join_mesh.c:3996
 #, c-format
 msgid ""
 "  Incoherency found in the current mesh definition\n"
@@ -2470,7 +2023,7 @@ msgid ""
 "  Vertices: local (%d, %d), global (%u, %u) are defined twice\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3235 src/base/cs_join_mesh.c:3349
+#: src/base/cs_join_mesh.c:3896 src/base/cs_join_mesh.c:4012
 #, c-format
 msgid ""
 "\n"
@@ -2481,60 +2034,125 @@ msgid ""
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3243 src/base/cs_join_mesh.c:3357
+#: src/base/cs_join_mesh.c:3904 src/base/cs_join_mesh.c:4020
 #, c-format
 msgid ""
 " Local Num | Global Num |  Tolerance  |        Coordinates\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3281
+#: src/base/cs_join_mesh.c:3942
 #, c-format
 msgid ""
 "\n"
 " mesh->n_faces:     %11d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3291
+#: src/base/cs_join_mesh.c:3952
 #, c-format
 msgid ""
 "\n"
-" face_id: %9d gnum: %10u - n_vertices : %4d\n"
+" face_id: %9d gnum: %10llu n_vertices : %4d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3387
+#: src/base/cs_join_mesh.c:3976
+#, c-format
+msgid ""
+"  Incoherency found in the current mesh definition\n"
+"  Face number: %d (global: %llu)\n"
+"  Vertices: local (%d, %d), global (%llu, %llu) are defined twice\n"
+msgstr ""
+
+#: src/base/cs_join_mesh.c:4050
 msgid ""
 "\n"
 "  Edge connectivity used in the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3388
+#: src/base/cs_join_mesh.c:4051
 #, c-format
 msgid "  Number of edges:      %8d\n"
-msgstr "  Nombre d'arêtes :     %8d\n"
+msgstr ""
 
-#: src/base/cs_join_mesh.c:3389
+#: src/base/cs_join_mesh.c:4052
 #, c-format
 msgid "  Number of vertices:   %8d\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3398
+#: src/base/cs_join_mesh.c:4061
 #, c-format
-msgid "  Edge %6d  (%7u) <Vertex> [%7u %7u]\n"
+msgid "  Edge %6d  (%8u) <Vertex> [%8u %8u]\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3425
+#: src/base/cs_join_mesh.c:4088
 msgid ""
 "\n"
 "  Vertex -> Vertex connectivity :\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_mesh.c:3432
+#: src/base/cs_join_mesh.c:4095
 #, c-format
 msgid "  Vertex %6d (%7u) - %3d - "
 msgstr ""
 
+#: src/base/cs_join_perio.c:234
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the periodicity number.\n"
+"  It must be between > 0 and is here: %d\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:529
+#, c-format
+msgid ""
+"\n"
+"  Delete %d interior periodic faces locally\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:651
+#, c-format
+msgid "  Adding periodicity %d (translation [%10.4e, %10.4e, %10.4e]).\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:726
+#, c-format
+msgid "  Adding periodicity %d (rotation).\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:822
+#, c-format
+msgid "  Adding periodicity %d (general formulation).\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:891
+#, c-format
+msgid ""
+" Periodicity number %d is not defined\n"
+" %d periodicities are defined\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:1218
+#, c-format
+msgid ""
+"  Apply periodicity to the local join mesh structure\n"
+"  New number of faces to treat locally: %8d\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:1231 src/base/cs_join_util.c:2441
+msgid ""
+"\n"
+"  Selected faces for the joining operation:\n"
+msgstr ""
+
+#: src/base/cs_join_perio.c:1521
+#, c-format
+msgid ""
+"  Vertex state (%d) is not consistent.\n"
+"  Can not apply changes from periodic faces to original face.\n"
+"  Check your periodicity parameters.\n"
+msgstr ""
+
 #: src/base/cs_join_post.c:238
 msgid ""
 " Size of \"int\" is not 4 or 8 bytes.\n"
@@ -2549,41 +2167,54 @@ msgstr ""
 msgid "VtxTolerance"
 msgstr ""
 
-#: src/base/cs_join_set.c:961
+#: src/base/cs_join_set.c:1106
 #, c-format
 msgid ""
 "  Fail to build an inverted cs_join_gset_t structure.\n"
 "  Cannot find %u in element list.\n"
 msgstr ""
 
-#: src/base/cs_join_set.c:1832
+#: src/base/cs_join_set.c:2409
 #, c-format
 msgid " Unexpected type (%s) to display in the current dump.\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:872
+#: src/base/cs_join_split.c:843
 msgid ""
 "  face splitting with face -> face connectivity is not yet implemented\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1032
+#: src/base/cs_join_split.c:1037
 #, c-format
 msgid ""
 " Joining operation : split face %d\n"
-" Problem in the connectivity. Could not find a connection with the vertex %"
-"d\n"
+" Problem in the connectivity. Could not find a connection with the vertex "
+"%d\n"
+msgstr ""
+
+#: src/base/cs_join_split.c:1195
+#, c-format
+msgid " Warning: open cycle for global face %u\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1422
+#: src/base/cs_join_split.c:1236
+#, c-format
+msgid " Warning: global face %u scanned twice\n"
+msgstr ""
+
+#: src/base/cs_join_split.c:1323
+#, c-format
+msgid " Warning: loop limit reached for global face %u\n"
+msgstr ""
+
+#: src/base/cs_join_split.c:1603
 #, c-format
 msgid ""
 "\n"
 "  Global number of faces after splitting: %10u\n"
 msgstr ""
-"\n"
-"  Nombre global de faces après subdivision : %10u\n"
 
-#: src/base/cs_join_split.c:1474
+#: src/base/cs_join_split.c:1657
 #, c-format
 msgid ""
 " Inconsistent values between:\n"
@@ -2592,31 +2223,40 @@ msgid ""
 " These values should be equal.\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1781
+#: src/base/cs_join_split.c:1925
 #, c-format
-msgid "  Split face: %d with returned code: %d\n"
+msgid "  Split face %d >> returned code: %d\n"
 msgstr ""
 
-#: src/base/cs_join_split.c:1953
+#: src/base/cs_join_split.c:2087
 #, c-format
 msgid ""
 "\n"
 "  *** WARNING ***\n"
-"  Globally, %lu problem(s) found during the face splitting\n"
-"     %12lu  open cycles,\n"
-"     %12lu  edges traversed twice,\n"
-"     %12lu  faces split into more than max_subfaces (= %d)\n"
+"  Globally, %llu problem(s) found during the face splitting\n"
+"     %12llu  open cycles,\n"
+"     %12llu  edges traversed twice,\n"
+"     %12llu  faces split into more than max_subfaces (= %d)\n"
 "\n"
 "    => Eventually modify joining parameters\n"
 "\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:827
+#: src/base/cs_join_split.c:2119
+#, c-format
+msgid ""
+" At least one original face has been cut into more than %d subfaces\n"
+". You can increase this parameter in usjoin() or usperi() by setting the "
+"advanced parameter maxsf.\n"
+" Be careful. It may produce mesh with a poor quality.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:761
 #, c-format
 msgid "  Add %d new vertices from the single elements sync.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:1510
+#: src/base/cs_join_update.c:1536
 #, c-format
 msgid ""
 "  Cannot find the first corresponding vertex between the face connectivity "
@@ -2624,7 +2264,7 @@ msgid ""
 "  Current global face number: %u\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:1672
+#: src/base/cs_join_update.c:1698
 #, c-format
 msgid ""
 "  Face %d (%u): Edge with two different descriptions: (%d, %d) [%u, %u]\n"
@@ -2632,14 +2272,47 @@ msgid ""
 "  Impossible to continue the mesh update after the merge operation.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3576
+#: src/base/cs_join_update.c:2486
+#, c-format
+msgid "  Join Face connectivity %d (%u): "
+msgstr ""
+
+#: src/base/cs_join_update.c:2517
+msgid "  Cannot achieve to reorient the current joined face.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:3099 src/base/cs_join_update.c:3151
+#, c-format
+msgid ""
+"  Cannot achieve to reorient the current joined face with face %d (selected "
+"face).\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:3421
+#, c-format
+msgid ""
+" Incoherency found before interior face orientation checking.\n"
+" Join face %d (%u) and related faces [%d, %d]\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:3613
+#, c-format
+msgid "  Delete %d local vertices not used in mesh definition.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4068
 #, c-format
 msgid ""
 "  Warning: Face %d (%u) has more than two ancestors.\n"
 "  Old faces implied:"
 msgstr ""
 
-#: src/base/cs_join_update.c:3593
+#: src/base/cs_join_update.c:4087
+#, c-format
+msgid "  Warning: Face %d (%u) has no ancestor.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4098
 #, c-format
 msgid ""
 "\n"
@@ -2648,37 +2321,49 @@ msgid ""
 "    Number of border faces to add  : %9d\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3610
+#: src/base/cs_join_update.c:4125
+#, c-format
+msgid ""
+" There are %u undefined faces with no ancestor.\n"
+" Cannot continue the joining algorithm.\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4133
 #, c-format
 msgid ""
 "\n"
 "  Global configuration after the joining operation:\n"
-"     Global number of border faces to add : %10u\n"
+"     Global number of border faces to add: %10llu\n"
+msgstr ""
+
+#: src/base/cs_join_update.c:4141
+#, c-format
+msgid "     Global number of multiple border faces: %10llu\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3826
+#: src/base/cs_join_update.c:4348
 #, c-format
 msgid "  Clean border face %d. New number of vertices: %d\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3848
+#: src/base/cs_join_update.c:4370
 #, c-format
 msgid ""
 "\n"
 "  Degenerate connectivity for %d final local boundary faces.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3887
+#: src/base/cs_join_update.c:4409
 #, c-format
 msgid "  Clean interior face %d. New number of vertices: %d\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3909
+#: src/base/cs_join_update.c:4431
 #, c-format
 msgid "  Degenerate connectivity for %d final local interior faces.\n"
 msgstr ""
 
-#: src/base/cs_join_update.c:3959
+#: src/base/cs_join_update.c:4481
 #, c-format
 msgid ""
 "\n"
@@ -2687,36 +2372,112 @@ msgid ""
 "    Global number of cleaned border faces:   %8u\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2476
+#: src/base/cs_join_util.c:2074
 #, c-format
-msgid "  Number of boundary faces selected for joining: %10u\n"
+msgid ""
+"Mesh joining:  Forbidden value for the tml parameter.\n"
+"  It must be between > 0 and is here: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2085
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the tmb parameter.\n"
+"  It must be between > 0 and is here: %d\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2489
+#: src/base/cs_join_util.c:2096
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the tmr parameter.\n"
+"  It must be between > 0.0 and is here: %f\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2111
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the merge tolerance factor.\n"
+"  It must be positive or nul and not: %f\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2121
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the max. number of tolerance breaks.\n"
+"  It must be between >= 0 and not: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2138
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the tcm parameter.\n"
+"  It must be between 1, 2 or 11, 12 and here is: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2148
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for icm parameter.\n"
+"  It must be 1 or 2 and here is: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2158
+#, c-format
+msgid ""
+"Mesh joining:  Forbidden value for the maxsf parameter.\n"
+"  It must be between > 0 and here is: %d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2291
+#, c-format
+msgid "  Global number of boundary faces selected for joining: %10u\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2411
 msgid ""
 "\n"
-"  Selected faces for the joining operation:\n"
+"  Local information about selection structure:\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2412
+#, c-format
+msgid "    number of faces:               %8d\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2508
+#: src/base/cs_join_util.c:2414
+#, c-format
+msgid "    number of vertices:            %8d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2416
+#, c-format
+msgid "    number of adj. border faces:   %8d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2418
+#, c-format
+msgid "    number of adj. interior faces: %8d\n"
+msgstr ""
+
+#: src/base/cs_join_util.c:2450
 msgid ""
 "\n"
 "  Select vertices for the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2556
+#: src/base/cs_join_util.c:2457
 msgid ""
 "\n"
 "  Contiguous border faces for the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2573
+#: src/base/cs_join_util.c:2464
 msgid ""
 "\n"
 "  Contiguous interior faces for the joining operation:\n"
 msgstr ""
 
-#: src/base/cs_join_util.c:2708 src/base/cs_join_util.c:2724
+#: src/base/cs_join_util.c:2682 src/base/cs_join_util.c:2698
 #, c-format
 msgid ""
 "  Inconsistent mesh definition. Cannot build edges.\n"
@@ -2725,7 +2486,7 @@ msgstr ""
 
 #: src/base/cs_matrix.c:321
 msgid "diagonal + faces"
-msgstr "diagonale + faces"
+msgstr ""
 
 #: src/base/cs_matrix.c:322
 msgid "Compressed Sparse Row"
@@ -2738,46 +2499,38 @@ msgid ""
 "with an external halo synchronization, preceded by a backup and\n"
 "followed by a restoration of the rotation halo."
 msgstr ""
-"Produit matriciel avec mode de rotation CS_PERIO_IGNORE non encore\n"
-"implémenté : utiliser dans ce cas cs_matrix_vector_multiply_nosync()\n"
-"avec une synchronisation de halo externe, précédée d'une sauvegarde\n"
-"et suivie d'une restoration du halo de rotation."
 
-#: src/base/cs_matrix.c:2009
+#: src/base/cs_matrix.c:2011
 msgid ""
 "Assigning non-symmetric matrix coefficients to a matrix\n"
 "in a symmetric CSR format."
 msgstr ""
-"Affectation de coefficients matriciels non symétriques\n"
-"à une matrice en stockage CSR symmétrique."
 
-#: src/base/cs_matrix.c:2614
+#: src/base/cs_matrix.c:2616
 #, c-format
 msgid ""
 "Handling of matrixes in %s format\n"
 "is not operational yet."
 msgstr ""
-"La gestion des matrices au format %s \n"
-"n'est pas encore opérationnelle."
 
-#: src/base/cs_matrix.c:2750 src/base/cs_matrix.c:2767
-#: src/base/cs_matrix.c:2793 src/base/cs_matrix.c:2813
-#: src/base/cs_matrix.c:2835
+#: src/base/cs_matrix.c:2752 src/base/cs_matrix.c:2769
+#: src/base/cs_matrix.c:2795 src/base/cs_matrix.c:2815
+#: src/base/cs_matrix.c:2837
 msgid "The matrix is not defined."
-msgstr "La matrice n'est pas définie."
+msgstr ""
 
 #: src/base/cs_mesh.c:155
 msgid "Synchronizing cell families\n"
-msgstr " Synchronisation des familles des cellules\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:209
 msgid "    no value\n"
-msgstr "    aucune valeur\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:217 src/base/cs_mesh.c:375
 #, c-format
 msgid "    minimum value =         %10d\n"
-msgstr "    valeur minimale =       %10d\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:218 src/base/cs_mesh.c:376
 #, c-format
@@ -2785,8 +2538,6 @@ msgid ""
 "    maximum value =         %10d\n"
 "\n"
 msgstr ""
-"    valeur maximale =       %10d\n"
-"\n"
 
 #: src/base/cs_mesh.c:289
 msgid ""
@@ -2794,19 +2545,16 @@ msgid ""
 " Halo creation times summary\n"
 "\n"
 msgstr ""
-"\n"
-" Bilan des temps pour la création du halo\n"
-"\n"
 
 #: src/base/cs_mesh.c:292
 #, c-format
 msgid "     Interface creation:                       %.3g s\n"
-msgstr "     Création de l'interface :                  %.3g s\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:296
 #, c-format
 msgid "     Extended connectivity creation:            %.3g s\n"
-msgstr "     Création de la connectivité étendue :      %.3g s\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:299
 #, c-format
@@ -2814,8 +2562,6 @@ msgid ""
 "     Halo creation:                             %.3g s\n"
 "\n"
 msgstr ""
-"     Création du halo :                         %.3g s\n"
-"\n"
 
 #: src/base/cs_mesh.c:303
 #, c-format
@@ -2823,8 +2569,6 @@ msgid ""
 "     Total time for halo creation:              %.3g s\n"
 "\n"
 msgstr ""
-"     Temps total de création du halo :          %.3g s\n"
-"\n"
 
 #: src/base/cs_mesh.c:373
 msgid ""
@@ -2832,24 +2576,18 @@ msgid ""
 " Histogram of the number of interior faces per cell:\n"
 "\n"
 msgstr ""
-"\n"
-" Histogramme du nombre de faces internes par cellule :\n"
-"\n"
 
 #: src/base/cs_mesh.c:470
 msgid ""
 "\n"
 " Histogram of the number of cells per rank:\n"
 "\n"
-msgstr ""
-"\n"
-" Histogramme de la distribution du nombre de cellules sur les rangs :\n"
-"\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:478
 #, c-format
 msgid " Number of cells:                                      %d\n"
-msgstr " Nombre de cellules :                                  %d\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:491
 msgid ""
@@ -2857,10 +2595,6 @@ msgid ""
 " Histogram of the number of standard + halo cells per rank:\n"
 "\n"
 msgstr ""
-"\n"
-" Histogramme de la distribution du nombre de cellules\n"
-" standard + halo sur les rangs :\n"
-"\n"
 
 #: src/base/cs_mesh.c:500
 #, c-format
@@ -2868,8 +2602,6 @@ msgid ""
 " Number of cells + halo cells:                         %d\n"
 "\n"
 msgstr ""
-" Nombre de cellules + cellules halo :                  %d\n"
-"\n"
 
 #: src/base/cs_mesh.c:520
 msgid ""
@@ -2877,9 +2609,6 @@ msgid ""
 " Histogram of the number of ghost cells per rank:\n"
 "\n"
 msgstr ""
-"\n"
-" Histogramme de la distribution des cellules fantômes sur les rangs :\n"
-"\n"
 
 #: src/base/cs_mesh.c:532
 msgid ""
@@ -2888,10 +2617,6 @@ msgid ""
 " in the standard neighborhood per rank:\n"
 "\n"
 msgstr ""
-"\n"
-" Histogramme de la distribution des cellules fantômes\n"
-" dans le voisinage standard sur les rangs :\n"
-"\n"
 
 #: src/base/cs_mesh.c:542
 #, c-format
@@ -2899,13 +2624,11 @@ msgid ""
 "\n"
 " Number of ghost cells:                          %10d\n"
 msgstr ""
-"\n"
-" Nombre de cellules fantômes :                  %10d\n"
 
 #: src/base/cs_mesh.c:545
 #, c-format
 msgid "   in the standard neighborhood:              %10d\n"
-msgstr "   dans le voisinage standard :               %10d\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:564
 msgid ""
@@ -2913,14 +2636,11 @@ msgid ""
 " Histogram of the number of interior faces per rank:\n"
 "\n"
 msgstr ""
-"\n"
-" Histogramme de la distribution du nombre de faces interne sur les rangs :\n"
-"\n"
 
 #: src/base/cs_mesh.c:572
 #, c-format
 msgid " Number of interior faces:                             %d\n"
-msgstr " Nombre de faces internes :                            %d\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:588
 msgid ""
@@ -2928,14 +2648,11 @@ msgid ""
 " Histogram of the number of boundary faces per rank:\n"
 "\n"
 msgstr ""
-"\n"
-" Histogramme de la distribution du nombre de faces de bord sur les rangs :\n"
-"\n"
 
 #: src/base/cs_mesh.c:596
 #, c-format
 msgid " Number of boundary faces:                             %d\n"
-msgstr " Nombre de faces de bord :                             %d\n"
+msgstr ""
 
 #: src/base/cs_mesh.c:617
 msgid ""
@@ -2943,12 +2660,8 @@ msgid ""
 " Histogram of the number of neighboring domains per rank:\n"
 "\n"
 msgstr ""
-"\n"
-" Histogramme de la distribution du nombre de domaines voisins sur les "
-"rangs :\n"
-"\n"
 
-#: src/base/cs_mesh.c:1061
+#: src/base/cs_mesh.c:1065
 #, c-format
 msgid ""
 "\n"
@@ -2957,95 +2670,73 @@ msgid ""
 "                       Y : %14.7e %14.7e\n"
 "                       Z : %14.7e %14.7e\n"
 msgstr ""
-"\n"
-" Coordonnées du maillage         minimale    et maximale\n"
-"                       X : %14.7e %14.7e\n"
-"                       Y : %14.7e %14.7e\n"
-"                       Z : %14.7e %14.7e\n"
 
-#: src/base/cs_mesh.c:1093
+#: src/base/cs_mesh.c:1097
 msgid ""
 "\n"
 " Global definition of the number of elements (cells, vertices, faces...)\n"
 msgstr ""
-"\n"
-" Définition globale du nombre d'éléments (cellules, sommets, faces...)\n"
 
-#: src/base/cs_mesh.c:1179
+#: src/base/cs_mesh.c:1183
 msgid ""
 "\n"
 " Halo construction with extended neighborhood\n"
 " ============================================\n"
 "\n"
 msgstr ""
-"\n"
-" Construction du halo avec voisinage étendu\n"
-" ==========================================\n"
-"\n"
 
-#: src/base/cs_mesh.c:1186
+#: src/base/cs_mesh.c:1190
 msgid " Periodicities combination\n"
-msgstr " Composition des périodicités\n"
+msgstr ""
 
-#: src/base/cs_mesh.c:1195
+#: src/base/cs_mesh.c:1199
 msgid ""
 "\n"
 " Halo construction with standard neighborhood\n"
 " ============================================\n"
 "\n"
 msgstr ""
-"\n"
-" Construction du halo avec voisinage standard\n"
-" ============================================\n"
-"\n"
 
-#: src/base/cs_mesh.c:1223
+#: src/base/cs_mesh.c:1227
 msgid " Definition of periodic couples\n"
-msgstr " Définition des couples périodiques\n"
+msgstr ""
 
-#: src/base/cs_mesh.c:1245
+#: src/base/cs_mesh.c:1249
 msgid " Interface creation\n"
-msgstr " Création de l'interface\n"
+msgstr ""
 
-#: src/base/cs_mesh.c:1278
+#: src/base/cs_mesh.c:1282
 msgid " Halo creation\n"
-msgstr " Création des halos\n"
+msgstr ""
 
-#: src/base/cs_mesh.c:1283
+#: src/base/cs_mesh.c:1287
 msgid " Halo definition\n"
-msgstr " Définition des halos\n"
+msgstr ""
 
-#: src/base/cs_mesh.c:1307
+#: src/base/cs_mesh.c:1311
 msgid " Extended neighborhood structures definition\n"
-msgstr " Définition des structures pour le voisinage étendu\n"
+msgstr ""
 
-#: src/base/cs_mesh.c:1334
+#: src/base/cs_mesh.c:1338
 #, c-format
 msgid ""
 "\n"
 " Extended connectivity creation (%.3g s)\n"
 msgstr ""
-"\n"
-" Création de la connectivité étendue (%.3g s)\n"
 
-#: src/base/cs_mesh.c:1485
+#: src/base/cs_mesh.c:1489
 #, c-format
 msgid ""
 " %s\n"
-"     Number of cells:          %lu\n"
-"     Number of interior faces: %lu\n"
-"     Number of boundary faces: %lu\n"
-"     Number of vertices:       %lu\n"
+"     Number of cells:          %llu\n"
+"     Number of interior faces: %llu\n"
+"     Number of boundary faces: %llu\n"
+"     Number of vertices:       %llu\n"
 msgstr ""
-" %s\n"
-"     Nombre de cellules :       %lu\n"
-"     Nombre de faces internes : %lu\n"
-"     Nombre de faces de bord :  %lu\n"
-"     Nombre de sommets :        %lu\n"
 
 #: src/base/cs_mesh_coherency.c:104
 msgid "    Checking the face -> cells connectivity coherency\n"
-msgstr "    Test de cohérence de la connectivité faces -> cellules\n"
+msgstr ""
 
 #: src/base/cs_mesh_coherency.c:110
 #, c-format
@@ -3053,25 +2744,21 @@ msgid ""
 "Internal face -> cells connectivity value not initialized\n"
 "for face: %d (cell_num1 = %d and cell_num2 = %d)\n"
 msgstr ""
-"Valeur de connectivité faces -> cellules pas initialisée\n"
-"pour la face : %d (num_cell1 = %d et num_cell2 = %d)\n"
 
 #: src/base/cs_mesh_coherency.c:147
 msgid ""
 "\n"
 " Checking the mesh structure coherency:\n"
 msgstr ""
-"\n"
-" Tests de cohérence de la structure de maillage :\n"
 
 #: src/base/cs_mesh_coherency.c:165
 msgid "    Coherency criteria definition\n"
-msgstr "    Définition des critères de cohérence\n"
+msgstr ""
 
 #: src/base/cs_mesh_coherency.c:321
 #, c-format
 msgid "    Coherency verification on coordinates %d\n"
-msgstr "    Vérification de cohérence sur coordonnées %d\n"
+msgstr ""
 
 #: src/base/cs_mesh_coherency.c:344 src/base/cs_mesh_coherency.c:393
 #, c-format
@@ -3082,11 +2769,6 @@ msgid ""
 " delta:       %12.3g\n"
 " box center:  %12.3g\n"
 msgstr ""
-"\n"
-"Infos cellule 1 : %d\n"
-" centre cellule : %12.3g %12.3g %12.3g\n"
-" delta :          %12.3g\n"
-" centre boîte :   %12.3g\n"
 
 #: src/base/cs_mesh_coherency.c:351 src/base/cs_mesh_coherency.c:400
 #, c-format
@@ -3097,11 +2779,6 @@ msgid ""
 " delta:       %12.3g\n"
 " box center:  %12.3g\n"
 msgstr ""
-"\n"
-"Infos cellule 2 : %d\n"
-" centre cellule : %12.3g %12.3g %12.3g\n"
-" delta :          %12.3g\n"
-" centre boîte :   %12.3g\n"
 
 #: src/base/cs_mesh_coherency.c:360
 #, c-format
@@ -3111,10 +2788,6 @@ msgid ""
 "between cells %d and %d: test = %g\n"
 "(delta = %g, delta_mean = %g)\n"
 msgstr ""
-"\n"
-"Erreur de cohérence dans le halo standard\n"
-"entre les cellules %d et %d : test = %g\n"
-"(delta = %g, delta_moyen = %g)\n"
 
 #: src/base/cs_mesh_coherency.c:409
 #, c-format
@@ -3124,14 +2797,10 @@ msgid ""
 "between cells %d and %d: test = %g\n"
 "(delta = %g, delta_mean = %g)\n"
 msgstr ""
-"\n"
-"Erreur de cohérence dans le halo étendu\n"
-"entre les cellules %d et %d : test = %g\n"
-"(delta = %g, delta_moyen = %g)\n"
 
 #: src/base/cs_mesh_coherency.c:429
 msgid " End of coherency check of the mesh structure.\n"
-msgstr " Fin des tests de cohérence de la structure de maillage.\n"
+msgstr ""
 
 #: src/base/cs_mesh_connect.c:294
 msgid ""
@@ -3139,9 +2808,6 @@ msgid ""
 "connectivity, necessary for the nodal connectivity\n"
 "reconstruction (cs_mesh_connect_cells_to_nodal)."
 msgstr ""
-"Le maillage principal ne contient pas de connectivité\n"
-"faces->sommets, indispensable à la reconstruction\n"
-"de la connectivité nodale (cs_mesh_connect_cells_to_nodal)."
 
 #: src/base/cs_mesh_connect.c:443
 msgid ""
@@ -3149,9 +2815,6 @@ msgid ""
 "connectivity, necessary for the nodal connectivity\n"
 "reconstruction (cs_mesh_connect_faces_to_nodal)."
 msgstr ""
-"Le maillage principal ne contient pas de connectivité\n"
-"faces->sommets, indispensable à la reconstruction\n"
-"de la connectivité nodale (cs_mesh_connect_faces_to_nodal)."
 
 #: src/base/cs_mesh_halo.c:314
 #, c-format
@@ -3178,32 +2841,27 @@ msgid ""
 "side effect of the Preprocessor.\n"
 "Coordinates of the first impacted point: [%12.5e, %12.5e %12.5e]."
 msgstr ""
-"Incohérence repérée lors de la construction du halo.\n"
-"Plusieurs points locaux ont le même correspondant distant ;\n"
-"ceci est probablement dû à un effet de bord de la construction\n"
-"de périodicités multiples par le Préprocesseur.\n"
-"Coordonnées du premier point impacté: [%12.5e, %12.5e %12.5e]."
 
 #: src/base/cs_mesh_halo.c:3502 src/ctwr/cs_ctwr_halo.c:1492
 msgid "    Local halo definition\n"
-msgstr "    Définition du halo local\n"
+msgstr ""
 
 #: src/base/cs_mesh_halo.c:3514
 msgid "    Halo cleaning\n"
-msgstr "    Nettoyage des halos\n"
+msgstr ""
 
 #: src/base/cs_mesh_halo.c:3524
 msgid "    Distant halo creation\n"
-msgstr "    Création du halo distant\n"
+msgstr ""
 
 #: src/base/cs_mesh_halo.c:3558
 msgid "    Updating the faces -> cells connectivity\n"
-msgstr "    Mise à jour de la connectivité faces -> cellules\n"
+msgstr ""
 
 #: src/base/cs_mesh_quality.c:178
 #, c-format
 msgid "    minimum value =         %10.5e\n"
-msgstr "    valeur minimale =       %10.5e\n"
+msgstr ""
 
 #: src/base/cs_mesh_quality.c:179
 #, c-format
@@ -3211,8 +2869,6 @@ msgid ""
 "    maximum value =         %10.5e\n"
 "\n"
 msgstr ""
-"    valeur maximale =       %10.5e\n"
-"\n"
 
 #: src/base/cs_mesh_quality.c:922
 msgid ""
@@ -3220,9 +2876,6 @@ msgid ""
 "  Histogram of the interior faces warping:\n"
 "\n"
 msgstr ""
-"\n"
-"  Histogramme du gauchissement des faces internes :\n"
-"\n"
 
 #: src/base/cs_mesh_quality.c:927
 msgid ""
@@ -3230,9 +2883,6 @@ msgid ""
 "  Histogram of the boundary faces warping:\n"
 "\n"
 msgstr ""
-"\n"
-"  Histogramme du gauchissement des faces de bord:\n"
-"\n"
 
 #: src/base/cs_mesh_quality.c:1020
 msgid ""
@@ -3240,9 +2890,6 @@ msgid ""
 "  Histogram of the interior faces weighting coefficient:\n"
 "\n"
 msgstr ""
-"\n"
-"  Histogramme des coefficients de pondération des faces internes :\n"
-"\n"
 
 #: src/base/cs_mesh_quality.c:1024
 msgid ""
@@ -3250,9 +2897,6 @@ msgid ""
 "  Histogram of the interior faces off-centering coefficient:\n"
 "\n"
 msgstr ""
-"\n"
-"  Histogramme des coefficients de décentrement des faces internes :\n"
-"\n"
 
 #: src/base/cs_mesh_quality.c:1122
 msgid ""
@@ -3261,9 +2905,6 @@ msgid ""
 "degrees):\n"
 "\n"
 msgstr ""
-"\n"
-"  Histogramme de la non-orthogonalité des faces internes (en degrés) :\n"
-"\n"
 
 #: src/base/cs_mesh_quality.c:1128
 msgid ""
@@ -3272,9 +2913,6 @@ msgid ""
 "degrees):\n"
 "\n"
 msgstr ""
-"\n"
-"  Histogramme de la non-orthogonalité des faces de bord (en degrés) :\n"
-"\n"
 
 #: src/base/cs_mesh_quality.c:1198
 msgid ""
@@ -3282,23 +2920,16 @@ msgid ""
 "  Histogram of cell volumes:\n"
 "\n"
 msgstr ""
-"\n"
-"  Histogramme du volume des cellules :\n"
-"\n"
 
 #: src/base/cs_mesh_quantities.c:169 src/base/cs_mesh_quantities.c:333
 msgid ""
 "Face geometric quantities computation is only\n"
 "implemented in 3D."
 msgstr ""
-"Le calcul des grandeurs géométriques associées aux faces\n"
-"ne sont implantés qu'en 3D."
 
 #: src/base/cs_mesh_quantities.c:572 src/base/cs_mesh_quantities.c:706
 msgid "Cell centre computation is only implemented in 3D."
 msgstr ""
-"Le calcul des centres des cellules\n"
-"ne sont implantés qu'en 3D."
 
 #: src/base/cs_mesh_quantities.c:927
 #, c-format
@@ -3310,16 +2941,11 @@ msgid ""
 "  1: computation based on the vertices\n"
 "and not %d."
 msgstr ""
-"L'indicateur de choix d'algorithme de calcul du centre de gravité\n"
-"des cellules peut prendre les valeurs suivantes :\n"
-"  0 : calcul basé sur les centres et surfaces des faces\n"
-"  1 : calcul basé sur les sommets\n"
-"et non %d."
 
 #: src/base/cs_mesh_quantities.c:1232
 #, c-format
 msgid ""
-"  %lu cells have a Negative volume.\n"
+"  %llu cells have a Negative volume.\n"
 " Run mesh quality check for post-processing output.\n"
 " In case of mesh joining, this may be due to overly  agressive joining "
 "parameters."
@@ -3327,45 +2953,40 @@ msgstr ""
 
 #: src/base/cs_mesh_solcom.c:382 src/base/cs_post.c:3394
 msgid "Fluid volume"
-msgstr "Volume fluide"
+msgstr ""
 
-#: src/base/cs_mesh_warping.c:1028
+#: src/base/cs_mesh_warping.c:1031
 msgid ""
 "The faces have been renumbered before cutting.\n"
 "This case should not arise, because the mesh entities\n"
 "should be cut before renumbering."
 msgstr ""
-"On a découpé les faces préalablement renumérotées.\n"
-"Ce cas ne devrait pas se produire, car on devrait découper\n"
-"les entités de maillage avant de les renuméroter."
 
-#: src/base/cs_mesh_warping.c:1036
+#: src/base/cs_mesh_warping.c:1039
 #, c-format
 msgid "\t%12d global faces before cutting\n"
-msgstr "\t%12d faces globales avant découpage\n"
+msgstr ""
 
-#: src/base/cs_mesh_warping.c:1056
+#: src/base/cs_mesh_warping.c:1059
 #, c-format
 msgid ""
 "\t%12d global faces after cutting\n"
 "\n"
 msgstr ""
-"\t%12d faces globales après découpage\n"
-"\n"
 
-#: src/base/cs_mesh_warping.c:1102
+#: src/base/cs_mesh_warping.c:1105
 msgid "Warped faces to cut"
-msgstr "Faces gauche a decouper"
+msgstr ""
 
-#: src/base/cs_mesh_warping.c:1123
+#: src/base/cs_mesh_warping.c:1126
 msgid "Face warping"
-msgstr "Gauchissement des faces"
+msgstr ""
 
-#: src/base/cs_mesh_warping.c:1163
+#: src/base/cs_mesh_warping.c:1166
 msgid "Warped faces after cutting"
-msgstr "Faces gauche apres decoupage"
+msgstr ""
 
-#: src/base/cs_mesh_warping.c:1218
+#: src/base/cs_mesh_warping.c:1221
 #, c-format
 msgid ""
 "\n"
@@ -3376,23 +2997,14 @@ msgid ""
 " Maximum allowed angle (rad):\t%7.4f\n"
 "\n"
 msgstr ""
-"\n"
-"\n"
-" Découpage des faces gauche demandé\n"
-" ----------------------------------\n"
-"\n"
-" Angle maximal autorisé (rad) :\t%7.4f\n"
-"\n"
 
-#: src/base/cs_mesh_warping.c:1281
+#: src/base/cs_mesh_warping.c:1284
 msgid ""
 "\n"
 " No face to cut. Verify the criterion if necessary.\n"
 msgstr ""
-"\n"
-" Aucune face à découper. Revoir le critère si nécessaire.\n"
 
-#: src/base/cs_mesh_warping.c:1328
+#: src/base/cs_mesh_warping.c:1331
 #, c-format
 msgid ""
 " Interior faces:\n"
@@ -3402,23 +3014,15 @@ msgid ""
 "\t%12d local faces after cutting\n"
 "\n"
 msgstr ""
-" Faces internes:\n"
-"\t%12d faces découpées pour respecter le critère\n"
-"\n"
-"\t%12d faces localement avant découpage\n"
-"\t%12d faces localement après découpage\n"
-"\n"
 
-#: src/base/cs_mesh_warping.c:1335 src/base/cs_mesh_warping.c:1375
+#: src/base/cs_mesh_warping.c:1338 src/base/cs_mesh_warping.c:1378
 #, c-format
 msgid ""
 " Size of the new face -> vertices connectivity: %12d\n"
 "\n"
 msgstr ""
-" Taille de la nouvelle connectivité face -> sommets :%12d\n"
-"\n"
 
-#: src/base/cs_mesh_warping.c:1368
+#: src/base/cs_mesh_warping.c:1371
 #, c-format
 msgid ""
 " Boundary faces:\n"
@@ -3428,12 +3032,6 @@ msgid ""
 "\t%12d local faces after cutting\n"
 "\n"
 msgstr ""
-" Faces de bord:\n"
-"\t%12d faces découpées pour respecter le critère\n"
-"\n"
-"\t%12d faces localement avant découpage\n"
-"\t%12d faces localement après découpage\n"
-"\n"
 
 #: src/base/cs_multigrid.c:280
 #, c-format
@@ -3442,14 +3040,11 @@ msgid ""
 "Summary of multigrid for \"%s\":\n"
 "\n"
 msgstr ""
-"\n"
-"Bilan du multigrille pour \"%s\" :\n"
-"\n"
 
 #: src/base/cs_multigrid.c:290
 #, c-format
 msgid "  Smoother: %s\n"
-msgstr "  Lisseur : %s\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:292
 #, c-format
@@ -3457,13 +3052,11 @@ msgid ""
 "  Descent smoother:     %s\n"
 "  Ascent smoother:      %s\n"
 msgstr ""
-"  Lisseur de descente : %s\n"
-"  Lisseur de remontée : %s\n"
 
 #: src/base/cs_multigrid.c:296
 #, c-format
 msgid "  Coarsest level solver:       %s\n"
-msgstr "  Solveur de niveau grossier : %s\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:301
 #, c-format
@@ -3494,31 +3087,6 @@ msgid ""
 "  Associated times (construction, resolution)\n"
 "    total elapsed:                  %12.3f  %12.3f\n"
 msgstr ""
-"  Nombre de constructions :         %d\n"
-"  Nombre de résolutions :           %d\n"
-"  Nombre de niveaux :\n"
-"    minimal :                       %d\n"
-"    maximal :                       %d\n"
-"    moyen :                         %d\n"
-"  Nombre d'itérations :\n"
-"    sur grille la plus fine :\n"
-"      minimal :                     %d\n"
-"      maximal :                     %d\n"
-"      moyen :                       %d\n"
-"    sur grille la plus grossière :\n"
-"      minimal :                     %d\n"
-"      maximal :                     %d\n"
-"      moyen :                       %d\n"
-"    total sur les grilles :\n"
-"      minimal :                     %d\n"
-"      maximal :                     %d\n"
-"      moyen :                       %d\n"
-"    équivalent (total pondéré par le nombre de cellules) :\n"
-"      minimal :                     %d\n"
-"      maximal :                     %d\n"
-"      moyen :                       %d\n"
-"  Temps associés (construction, résolution)\n"
-"    écoulé cumulé :                 %12.3f  %12.3f\n"
 
 #: src/base/cs_multigrid.c:348
 #, c-format
@@ -3527,14 +3095,11 @@ msgid ""
 "    Max local total CPU time:       %12.3f  %12.3f\n"
 "    Total CPU time:                 %12.3f  %12.3f\n"
 msgstr ""
-"    CPU cumulé local min :          %12.3f  %12.3f\n"
-"    CPU cumulé local max :          %12.3f  %12.3f\n"
-"    CPU cumulé total :              %12.3f  %12.3f\n"
 
 #: src/base/cs_multigrid.c:359
 #, c-format
 msgid "    Total CPU time:                 %12.3f  %12.3f\n"
-msgstr "    CPU cumulé :                    %12.3f  %12.3f\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:735
 msgid ""
@@ -3543,26 +3108,21 @@ msgid ""
 "    cycles | on fine mesh          | on fine mesh\n"
 "  ---------------------------------------------------\n"
 msgstr ""
-"  ---------------------------------------------------\n"
-"    nb.    | Cumul des iterations | Residu norm.\n"
-"    cycles | sur maillage fin     | maillage fin\n"
-"  ---------------------------------------------------\n"
 
 #: src/base/cs_multigrid.c:740
 msgid "  ---------------------------------------------------\n"
-msgstr "  ---------------------------------------------------\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:742
 #, c-format
 msgid "     %4d  |               %6d  |  %12.4e\n"
-msgstr "     %4d  |               %6d  |  %12.4e\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:745
 #, c-format
 msgid ""
 "   N. cycles: %4d; Fine mesh cumulative iter: %5d; Norm. residual %12.4e\n"
 msgstr ""
-"   Nb. cycles : %4d ; Cumul iter maillage fin : %5d ; Residu norme %12.4e\n"
 
 #: src/base/cs_multigrid.c:781
 #, c-format
@@ -3571,9 +3131,6 @@ msgid ""
 "    ********\n"
 "    Maximum number of cycles (%d) reached.\n"
 msgstr ""
-" @@ Attention : multigrille algébrique pour [%s]\n"
-"    *********\n"
-"    Nombre de cycles maximal (%d) atteint\n"
 
 #: src/base/cs_multigrid.c:936
 #, c-format
@@ -3581,8 +3138,6 @@ msgid ""
 "algebraic multigrid [%s]: divergence after %d cycles:\n"
 "  initial residual: %11.4e; current residual: %11.4e"
 msgstr ""
-"multigrille algébrique [%s] : divergence après %d cycles :\n"
-"  résidu initial : %11.4e ; résidu courant : %11.4e"
 
 #: src/base/cs_multigrid.c:941
 #, c-format
@@ -3591,40 +3146,37 @@ msgid ""
 "  during resolution at level %d:\n"
 "  initial residual: %11.4e; current residual: %11.4e"
 msgstr ""
-"multigrille algébrique [%s] : divergence après %d cycles :\n"
-"  au cours de la résolution au niveau %d:\n"
-"  résidu initial : %11.4e ; résidu courant : %11.4e"
 
 #: src/base/cs_multigrid.c:1103
 msgid "  Multigrid cycle: descent\n"
-msgstr "  Cycle multigrille : descente\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:1118 src/base/cs_multigrid.c:1302
 #, c-format
 msgid "    level %3d: smoother\n"
-msgstr "    niveau %3d : lisseur\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:1224
 msgid "  Resolution on coarsest level\n"
-msgstr "  Résolution sur le niveau le plus grossier\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:1271
 msgid "  Multigrid cycle: ascent\n"
-msgstr "  Cycle multigrille : remontée\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:1439
 msgid "Multigrid"
-msgstr "Multigrille"
+msgstr ""
 
 #: src/base/cs_multigrid.c:1471
 #, c-format
 msgid "Multigrid [%s]:\n"
-msgstr "Multigrille [%s]:\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:1478
 #, c-format
 msgid "Multigrid [%s]: cycle %4d\n"
-msgstr "Multigrille [%s] : cycle %4d\n"
+msgstr ""
 
 #: src/base/cs_multigrid.c:1631
 #, c-format
@@ -3632,8 +3184,6 @@ msgid ""
 "\n"
 " Construction of grid hierarchy for \"%s\"\n"
 msgstr ""
-"\n"
-" Construction de la hiérarchie de grilles pour \"%s\"\n"
 
 #: src/base/cs_multigrid.c:1675
 #, c-format
@@ -3641,8 +3191,6 @@ msgid ""
 " CLMLGA: maximum number of coarse grids (%d)\n"
 "         reached for \"%s\".\n"
 msgstr ""
-" CLMLGA : nombre de maillages grossiers maximal (%d)\n"
-"          atteint pour \"%s\".\n"
 
 #: src/base/cs_multigrid.c:1686
 #, c-format
@@ -3650,19 +3198,14 @@ msgid ""
 "\n"
 "   building level %2d grid\n"
 msgstr ""
-"\n"
-"   construction de la grille de niveau %2d\n"
 
 #: src/base/cs_multigrid.c:1722
 #, c-format
 msgid ""
 "                                  total       min        max\n"
-"     number of cells:     %12lu %10d %10d\n"
+"     number of cells:     %12llu %10d %10d\n"
 "     number of faces:                  %10d %10d\n"
 msgstr ""
-"                                  total       min        max\n"
-"     nombre de cellules : %12lu %10d %10d\n"
-"     nombre de faces :                 %10d %10d\n"
 
 #: src/base/cs_multigrid.c:1731
 #, c-format
@@ -3670,23 +3213,18 @@ msgid ""
 "     number of cells:     %10d\n"
 "     number of faces:     %10d\n"
 msgstr ""
-"     nombre de cellules : %10d\n"
-"     nombre de faces :    %10d\n"
 
 #: src/base/cs_multigrid.c:1750
 #, c-format
 msgid ""
 "   number of coarse grids:           %d\n"
-"   number of cells in coarsest grid: %lu\n"
+"   number of cells in coarsest grid: %llu\n"
 "\n"
 msgstr ""
-"   nombre de maillages grossiers :                        %d\n"
-"   nombre de cellules dans le maillage le plus grossier : %lu\n"
-"\n"
 
 #: src/base/cs_numbering.c:80
 msgid "vectorization"
-msgstr "vectorisation"
+msgstr ""
 
 #: src/base/cs_numbering.c:81
 msgid "threads"
@@ -3695,7 +3233,7 @@ msgstr ""
 #: src/base/cs_opts.c:114
 #, c-format
 msgid "Usage: %s [options]\n"
-msgstr "Utilisation : %s [options]\n"
+msgstr ""
 
 #: src/base/cs_opts.c:116
 #, c-format
@@ -3704,9 +3242,6 @@ msgid ""
 "Command line options:\n"
 "\n"
 msgstr ""
-"\n"
-"Options de la ligne de commandes :\n"
-"\n"
 
 #: src/base/cs_opts.c:118
 #, c-format
@@ -3714,21 +3249,16 @@ msgid ""
 " --solcom          stand-alone kernel with \"geomet\" mesh in\n"
 "                   SolCom format (obsolete)\n"
 msgstr ""
-" --solcom          noyau autonome avec maillage \"geomet\" au\n"
-"                   format SolCom (obsolète)\n"
 
-#: src/base/cs_opts.c:122
+#: src/base/cs_opts.c:121
 #, c-format
 msgid ""
 " --mpi             use MPI for parallelism or coupling\n"
 "                   [appnum]: number of this application in\n"
 "                             case of code coupling (default: 0)\n"
 msgstr ""
-" --mpi             calcul parallèle ou couplé via MPI ;\n"
-"                   [appnum] : numéro de cette application en cas de\n"
-"                              couplage de codes (défaut : 0)\n"
 
-#: src/base/cs_opts.c:126
+#: src/base/cs_opts.c:125
 #, c-format
 msgid ""
 " --mpi-io          <mode> set parallel I/O behavior\n"
@@ -3738,46 +3268,36 @@ msgid ""
 "                     ip:  MPI-IO with individual file pointers\n"
 msgstr ""
 
-#: src/base/cs_opts.c:133
+#: src/base/cs_opts.c:131
 #, c-format
 msgid " -q, --quality     mesh quality verification mode\n"
-msgstr " -q, --quality     vérification de la qualité du maillage\n"
+msgstr ""
 
-#: src/base/cs_opts.c:135
+#: src/base/cs_opts.c:133
 #, c-format
 msgid ""
 " --cwf             <criterion> cut warped faces\n"
 "                    -post: activate the post-processing related\n"
 "                           to the cutting of warped faces\n"
 msgstr ""
-" --cwf             <critere> découpage des faces gauches\n"
-"                   (cut warped faces)\n"
-"                    -post : active le post-traitement lié au \n"
-"                            découpage des faces\n"
 
-#: src/base/cs_opts.c:139
+#: src/base/cs_opts.c:137
 #, c-format
 msgid ""
 " --benchmark       elementary operations performance\n"
 "                   [--mpitrace] operations done only once\n"
 "                                for light MPI traces\n"
 msgstr ""
-" --benchmark       performance des opérations élémentaires\n"
-"                   [--mpitrace] opérations effectuées une seule\n"
-"                                fois pour traces MPI légères\n"
 
-#: src/base/cs_opts.c:143
+#: src/base/cs_opts.c:141
 #, c-format
 msgid ""
 " --log             output redirection for rank -1 or 0:\n"
 "                     0: standard output\n"
 "                     1: output in \"listing\" (default)\n"
 msgstr ""
-" --log             redirection des sorties de rang -1 ou 0 :\n"
-"                     0 : sortie standard\n"
-"                     1 : sorties dans \"listing\" (défaut)\n"
 
-#: src/base/cs_opts.c:147
+#: src/base/cs_opts.c:145
 #, c-format
 msgid ""
 " --logp            output redirection for rank > 0:\n"
@@ -3786,69 +3306,86 @@ msgid ""
 "                        terminals, debugger type)\n"
 "                     1: output in \"listing_n<rang>\"\n"
 msgstr ""
-" --logp            redirection des sorties de rang > 0 :\n"
-"                    -1 : sorties supprimees (défaut)\n"
-"                     0 : aucune redirection (si terminaux\n"
-"                         indépendants, type deboggeur)\n"
-"                     1 : sorties dans \"listing_n<rang>\"\n"
 
-#: src/base/cs_opts.c:154
+#: src/base/cs_opts.c:151
 #, c-format
 msgid " -p, --param       <file_name> parameter file\n"
-msgstr " -p, --param       <nom_du_fichier> fichier de paramètres\n"
+msgstr ""
 
-#: src/base/cs_opts.c:159
+#: src/base/cs_opts.c:154
 #, c-format
 msgid ""
 " --syr-socket      enable sockets for SYRTHES 3 coupling\n"
 "                   <port_num> port number on rank 0\n"
 msgstr ""
 
-#: src/base/cs_opts.c:164
+#: src/base/cs_opts.c:158
 #, c-format
 msgid " --version         print version number\n"
-msgstr " --version         affiche le numéro de version\n"
+msgstr ""
 
-#: src/base/cs_opts.c:166
+#: src/base/cs_opts.c:160
 #, c-format
 msgid ""
 " -h, --help        this help message\n"
 "\n"
 msgstr ""
-" -h, --help        appel de l'aide (cet affichage)\n"
-"\n"
 
-#: src/base/cs_opts.c:179
+#: src/base/cs_opts.c:173
 #, c-format
 msgid "%s version %s\n"
-msgstr "%s version %s\n"
+msgstr ""
 
-#: src/base/cs_opts.c:332
+#: src/base/cs_opts.c:326
 msgid "command: \n"
-msgstr "commande : \n"
+msgstr ""
 
-#: src/base/cs_opts.c:347
+#: src/base/cs_opts.c:341
 #, c-format
 msgid "  build %s\n"
-msgstr "  build %s\n"
+msgstr ""
 
-#: src/base/cs_opts.c:351
+#: src/base/cs_opts.c:345
 #, c-format
 msgid ""
 "  MPI version %d.%d (%s)\n"
 "\n"
 msgstr ""
-"  Version MPI %d.%d (%s)\n"
-"\n"
 
-#: src/base/cs_opts.c:354
+#: src/base/cs_opts.c:348
 #, c-format
 msgid ""
 "  MPI version %d.%d\n"
 "\n"
 msgstr ""
-"  Version MPI %d.%d\n"
-"\n"
+
+#: src/base/cs_opts.c:606
+#, c-format
+msgid ""
+"%s was built without MPI support,\n"
+"so option \"%s\" may not be used.\n"
+msgstr ""
+
+#: src/base/cs_opts.c:657
+#, c-format
+msgid ""
+"%s was built without XML support,\n"
+"so parameter file \"%s\" may not be loaded.\n"
+msgstr ""
+
+#: src/base/cs_opts.c:716
+#, c-format
+msgid ""
+"%s was built without socket support,\n"
+"so option \"%s\" may not be used.\n"
+msgstr ""
+
+#: src/base/cs_opts.c:733
+#, c-format
+msgid ""
+"%s was built without dynamic loader support,\n"
+"so module file \"%s\" may not be loaded.\n"
+msgstr ""
 
 #: src/base/cs_perio.c:344
 #, c-format
@@ -3856,12 +3393,10 @@ msgid ""
 "The %d periodic transformations of the halo do not comply\n"
 "with the main mesh transformations (numbering %d).\n"
 msgstr ""
-"Les %d transformations périodiques du halo ne correspondent\n"
-"pas à celles du maillage principal (au nombre de %d).\n"
 
 #: src/base/cs_perio.c:651 src/base/cs_perio.c:793
 msgid "IDIMTE and/or ITENSO have incoherent values"
-msgstr "IDIMTE et/ou ITENSO ont des valeurs incohérentes"
+msgstr ""
 
 #: src/base/cs_perio.c:2527
 #, c-format
@@ -3871,10 +3406,6 @@ msgid ""
 "variables of which the halo has been backed up are defined\n"
 "with [%p, %p, %p]."
 msgstr ""
-"On cherche à restaurer des éléments de rotation d'un\n"
-"halo sur la variable définie à partir de l'adresse %p,\n"
-"alors que les dernières variables dont le halo de rotation\n"
-"a été sauvegardé sont définies à partir de [%p, %p, %p]."
 
 #: src/base/cs_post.c:281
 #, c-format
@@ -3882,8 +3413,6 @@ msgid ""
 "The requested post-processing writer number\n"
 "%d is not defined.\n"
 msgstr ""
-"Le gestionnaire de post traitement numéro %d demandé\n"
-"n'est pas défini.\n"
 
 #: src/base/cs_post.c:312
 #, c-format
@@ -3891,16 +3420,12 @@ msgid ""
 "The requested post-processing mesh number\n"
 "%d is not defined.\n"
 msgstr ""
-"Le maillage de post traitement numéro %d demandé\n"
-"n'est pas défini.\n"
 
 #: src/base/cs_post.c:342
 msgid ""
 "The requested post-processing mesh number\n"
 "must be < 0 (reserved) or > 0 (user).\n"
 msgstr ""
-"Le numéro de maillage de post traitement demandé\n"
-"doit être < 0 (réservé) ou > 0 (utilisateur).\n"
 
 #: src/base/cs_post.c:348
 #, c-format
@@ -3908,8 +3433,6 @@ msgid ""
 "The requested post-processing mesh number\n"
 "(%d) has already been assigned.\n"
 msgstr ""
-"Le numéro de maillage de post traitement demandé\n"
-"(%d) a déjà été affecté.\n"
 
 #: src/base/cs_post.c:770
 msgid "parallel domain"
@@ -3925,8 +3448,6 @@ msgid ""
 "The PSTEVA sub-routine argument IVARPR must be\n"
 "equal to 0 or 1, and not %d.\n"
 msgstr ""
-"L'argument IVARPR du sous-programme PSTEVA doit être\n"
-"égal à 0 ou 1, et non %d.\n"
 
 #: src/base/cs_post.c:1894
 #, c-format
@@ -3934,16 +3455,12 @@ msgid ""
 "The PSTEVA sub-routine argument IENTLA must be\n"
 "equal to 0 or 1, and not %d.\n"
 msgstr ""
-"L'argument IENTLA du sous-programme PSTEVA doit être\n"
-"égal à 0 ou 1, et non %d.\n"
 
 #: src/base/cs_post.c:1961
 msgid ""
 "The requested post-processing writer number\n"
 "must be < 0 (reserved) or > 0 (user).\n"
 msgstr ""
-"Le numéro de gestionnaire de post traitement demandé\n"
-"doit être < 0 (réservé) ou > 0 (utilisateur).\n"
 
 #: src/base/cs_post.c:1967
 #, c-format
@@ -3951,8 +3468,6 @@ msgid ""
 "The requested post-processing writer number\n"
 "(%d) has already been assigned.\n"
 msgstr ""
-"Le numéro de gestionnaire de post traitement demandé\n"
-"(%d) a déjà été affecté.\n"
 
 #: src/base/cs_post.c:2228 src/base/cs_post.c:2231
 msgid " edges"
@@ -3964,8 +3479,6 @@ msgid ""
 "The mesh %d cannot be an alias of mesh %d,\n"
 "which is itself an alias of mesh %d.\n"
 msgstr ""
-"Le maillage %d ne peut être un alias du maillage %d,\n"
-"qui est lui-même déjà un alias du maillage %d.\n"
 
 #: src/base/cs_post.c:3239
 #, c-format
@@ -3979,41 +3492,31 @@ msgid ""
 "  Elapsed time for meshes:          %12.3f\n"
 "  Elapsed time for variables:       %12.3f\n"
 msgstr ""
-"\n"
-"Bilan des écritures de \"%s\" (%s) :\n"
-"\n"
-"  Temps CPU pour les maillages :    %12.3f\n"
-"  Temps CPU pour les champs :       %12.3f\n"
-"\n"
-"  Temps écoulé pour les maillages : %12.3f\n"
-"  Temps écoulé pour les champs :    %12.3f\n"
 
 #: src/base/cs_post.c:3411
 msgid "Boundary"
-msgstr "Bord"
+msgstr ""
 
 #: src/base/cs_post.c:3535
 msgid "Calculation domain"
-msgstr "Domaine de calcul"
+msgstr ""
 
 #: src/base/cs_preprocessor_data.c:250
 #, c-format
 msgid " Adding periodicity %d (translation [%10.4e, %10.4e, %10.4e]).\n"
-msgstr " Ajout de la périodicité %d (translation [%10.4e, %10.4e, %10.4e]).\n"
+msgstr ""
 
 #: src/base/cs_preprocessor_data.c:255
 #, c-format
 msgid " Adding periodicity %d (rotation).\n"
-msgstr " Ajout de la périodicité %d (rotation).\n"
+msgstr ""
 
-#: src/base/cs_preprocessor_data.c:338 src/base/cs_preprocessor_data.c:2149
+#: src/base/cs_preprocessor_data.c:338 src/base/cs_preprocessor_data.c:2156
 #, c-format
 msgid ""
 "Message of type <%s> on <%s>\n"
 "unexpected or of incorrect size"
 msgstr ""
-"Message de type <%s> sur <%s>\n"
-"inattendu ou de taille incorrecte"
 
 #: src/base/cs_preprocessor_data.c:355
 #, c-format
@@ -4022,22 +3525,19 @@ msgstr ""
 
 #: src/base/cs_preprocessor_data.c:357
 msgid "   an unoptimized domain partitioning will be used.\n"
-msgstr "   un découpage de domaines non optimisé sera utilisé.\n"
+msgstr ""
 
 #: src/base/cs_preprocessor_data.c:359
 msgid "   domain partitioning will use a space-filling curve.\n"
-msgstr "   le partitionnement sera basé sur une courbe fractale.\n"
+msgstr ""
 
 #: src/base/cs_preprocessor_data.c:405
 #, c-format
 msgid ""
 "The number of cells reported by file\n"
-"\"%s\" (%lu)\n"
-"does not correspond the those of the mesh (%lu)."
+"\"%s\" (%llu)\n"
+"does not correspond the those of the mesh (%llu)."
 msgstr ""
-"Le nombre de cellules indiqué par le fichier\n"
-"\"%s\" (%lu)\n"
-"ne correspond pas au maillage courant (%lu)."
 
 #: src/base/cs_preprocessor_data.c:426
 #, c-format
@@ -4046,20 +3546,20 @@ msgid ""
 "\"%s\" (%d) does not\n"
 "correspond to the current number of ranks (%d)."
 msgstr ""
-"Le nombre de rangs indiqué par le fichier\n"
-"\"%s\" (%d)\n"
-"ne correspond pas au nombre de rangs courant (%d)."
 
-#: src/base/cs_preprocessor_data.c:1519 src/base/cs_preprocessor_data.c:1775
+#: src/base/cs_preprocessor_data.c:461
+#, c-format
+msgid "Message of type <%s> on <%s> is unexpected."
+msgstr ""
+
+#: src/base/cs_preprocessor_data.c:1526 src/base/cs_preprocessor_data.c:1782
 #, c-format
 msgid ""
 "Number of cells on rank %d is zero.\n"
 "(number of cells / number of processes ratio too low)."
 msgstr ""
-"Le nombre de cellules pour le rang %d est nul.\n"
-"(rapport nombre de cellules / nombre de processeurs trop faible)."
 
-#: src/base/cs_preprocessor_data.c:2463
+#: src/base/cs_preprocessor_data.c:2482
 #, c-format
 msgid ""
 "The algorithm selection indicator for domain partitioning\n"
@@ -4068,20 +3568,13 @@ msgid ""
 "  2: partition based on space-filling curve\n"
 "and not %d."
 msgstr ""
-"L'indicateur de choix d'algorithme de partitionement de domaine\n"
-"peut prendre les valeurs suivantes :\n"
-"  1: partition basée sur la numérotation initiale\n"
-"  2: partition basée sur une courbe fractale\n"
-"et non %d."
 
-#: src/base/cs_preprocessor_data.c:2508
+#: src/base/cs_preprocessor_data.c:2527
 #, c-format
 msgid ""
 "Section of type <%s> on <%s>\n"
 "inexpected or of incorrect size."
 msgstr ""
-"Section de type <%s> sur <%s>\n"
-"inattendue ou de taille incorrecte"
 
 #: src/base/cs_proxy_comm.c:161
 #, c-format
@@ -4089,8 +3582,6 @@ msgid ""
 "Communication %s:\n"
 "Error receiving data through socket."
 msgstr ""
-"Communication %s :\n"
-"Erreur de réception de données par socket."
 
 #: src/base/cs_proxy_comm.c:223
 #, c-format
@@ -4098,8 +3589,6 @@ msgid ""
 "Communication %s:\n"
 "Error sending data through socket."
 msgstr ""
-"Communication %s :\n"
-"Erreur d'envoi de données par socket."
 
 #: src/base/cs_proxy_comm.c:243
 #, c-format
@@ -4107,17 +3596,15 @@ msgid ""
 "Communication %s:\n"
 "Error closing socket."
 msgstr ""
-"Communication %s :\n"
-"Erreur à la fermeture du socket."
 
 #: src/base/cs_proxy_comm.c:290
 msgid "Error initializing socket communication."
-msgstr "Erreur à l'initialisation de la communication par sockets."
+msgstr ""
 
 #: src/base/cs_proxy_comm.c:309
 #, c-format
 msgid "Socket communication: host \"%s\" unknown."
-msgstr "Communication par sockets : hôte \"%s\" inconnu."
+msgstr ""
 
 #: src/base/cs_proxy_comm.c:326
 #, c-format
@@ -4125,21 +3612,19 @@ msgid ""
 "Socket communication: error connecting to\n"
 "%s (port %d)."
 msgstr ""
-"Communication par sockets : erreur de connexion à\n"
-"%s (port %d)."
 
 #: src/base/cs_proxy_comm.c:370
 msgid "Handshake with proxy failed."
-msgstr "Échec de la \"poignée de main\" avec le proxy."
+msgstr ""
 
 #: src/base/cs_proxy_comm.c:432
 #, c-format
 msgid "Connecting to proxy:  %s ..."
-msgstr "Connexion au proxy :  %s ..."
+msgstr ""
 
 #: src/base/cs_proxy_comm.c:434
 msgid "Connecting to proxy ..."
-msgstr "Connexion au proxy ..."
+msgstr ""
 
 #: src/base/cs_proxy_comm.c:451
 #, c-format
@@ -4148,14 +3633,11 @@ msgid ""
 "type argument to cs_proxy_comm_initialize() must be different\n"
 "from CS_PROXY_COMM_TYPE_SOCKET (%d)."
 msgstr ""
-"Librarie compilée sans support des sockets support, donc l'argument\n"
-"de type du communicator dans l'appel à cs_proxy_comm_initialize()\n"
-"doit être différent de CS_PROXY_COMM_TYPE_SOCKET (%d)."
 
 #: src/base/cs_proxy_comm.c:486
 #, c-format
 msgid "Closing communication: %s\n"
-msgstr "Fermeture de la communication : %s\n"
+msgstr ""
 
 #: src/base/cs_renumber.c:890
 #, c-format
@@ -4174,8 +3656,6 @@ msgid ""
 "Location number %d given for restart file\n"
 "\"%s\" is not valid."
 msgstr ""
-"Le numéro de support %d donné pour le fichier suite\n"
-"\"%s\" est invalide."
 
 #: src/base/cs_restart.c:297
 #, c-format
@@ -4183,8 +3663,6 @@ msgid ""
 "Restart file \"%s\" declares a location number %d\n"
 "but no location %d has been declared."
 msgstr ""
-"Le fichier suite \"%s\" déclare un support numéro %d\n"
-"alors qu'aucun support numéro %d n'a été déclaré."
 
 #: src/base/cs_restart.c:605 src/base/cs_restart.c:933
 #, c-format
@@ -4192,8 +3670,6 @@ msgid ""
 "Restart file number <%d> can not be closed\n"
 "(file already closed or invalid number)."
 msgstr ""
-"Le fichier suite numéro <%d> ne peut être fermé\n"
-"(fichier déjà fermé ou numéro invalide)."
 
 #: src/base/cs_restart.c:641
 #, c-format
@@ -4201,8 +3677,6 @@ msgid ""
 "Location type <%d> given for a restart file section\n"
 "is invalid using the Fortran API."
 msgstr ""
-"Le type de support <%d> indiqué pour une rubrique de\n"
-"fichier suite est invalide pour l'interface Fortran."
 
 #: src/base/cs_restart.c:662
 #, c-format
@@ -4210,8 +3684,6 @@ msgid ""
 "Value type <%d> given for a restart file section\n"
 "is invalid using the Fortran API."
 msgstr ""
-"Le type de valeur <%d> indiqué pour une rubrique de\n"
-"fichier suite est invalide pour l'interface Fortran."
 
 #: src/base/cs_restart.c:876
 #, c-format
@@ -4219,8 +3691,6 @@ msgid ""
 "The access mode of the restart file <%s>\n"
 "must be equal to 1 (read) or 2 (write) and not <%d>."
 msgstr ""
-"Le mode d'ouverture du fichier suite <%s>\n"
-"doit être égal à 1 (lecture) ou 2 (écriture) et non <%d>."
 
 #: src/base/cs_restart.c:987 src/base/cs_restart.c:1038
 #, c-format
@@ -4228,19 +3698,14 @@ msgid ""
 "Information on the restart file number <%d> unavailable\n"
 "(file already closed or invalid number)."
 msgstr ""
-"Infomation sur le fichier suite numéro <%d> indisponible\n"
-"(fichier déjà fermé ou numéro invalide)."
 
 #: src/base/cs_restart.c:1372
 #, c-format
 msgid ""
 "The size of location \"%s\" associated with\n"
-"the restart file \"%s\" is %lu and does not\n"
-"correspond to that of the current mesh (%lu).\n"
+"the restart file \"%s\" is %llu and does not\n"
+"correspond to that of the current mesh (%llu).\n"
 msgstr ""
-"La taille du support \"%s\" associé au fichier suite\n"
-"\"%s\" vaut %lu et ne correspond pas\n"
-"à celle du maillage en cours (%lu).\n"
 
 #: src/base/cs_restart.c:1433
 #, c-format
@@ -4248,63 +3713,59 @@ msgid ""
 "The restart file \"%s\" references no\n"
 "location named \"%s\"."
 msgstr ""
-"\"Le fichier suite \\\"%s\\\" ne contient \\n\"\n"
-"\" aucun support de nom \\\"%s\\\".\""
 
 #: src/base/cs_restart.c:1493
 #, c-format
 msgid ""
 "  Location: %s\n"
-"    (number: %03d, n_glob_ents: %lu)\n"
+"    (number: %03d, n_glob_ents: %llu)\n"
 msgstr ""
-"  Support : %s\n"
-"    (numéro : %03d, n_glob_ents : %lu)\n"
 
-#: src/base/cs_restart.c:1502
+#: src/base/cs_restart.c:1503
 msgid "  General information associated with the restart file:\n"
-msgstr "  Informations générales associées au fichier suite :\n"
+msgstr ""
 
-#: src/base/cs_restart.c:1561
+#: src/base/cs_restart.c:1562
 #, c-format
 msgid "  %s: location id %d for \"%s\" does not exist.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1567
+#: src/base/cs_restart.c:1569
 #, c-format
-msgid "  %s: location id %d for \"%s\" has size %lu, but %lu is expected.\n"
+msgid "  %s: location id %d for \"%s\" has size %llu, but %llu is expected.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1589
+#: src/base/cs_restart.c:1591
 #, c-format
 msgid "  %s: section \"%s\" not present.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1616
+#: src/base/cs_restart.c:1618
 #, c-format
 msgid "  %s: section \"%s\" at location id %d but not at %d.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1626
+#: src/base/cs_restart.c:1628
 #, c-format
 msgid "  %s: section \"%s\" has %d values per location and  not %d.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1633
+#: src/base/cs_restart.c:1635
 #, c-format
 msgid "  %s: section \"%s\" has %d values and not %d.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1643
+#: src/base/cs_restart.c:1645
 #, c-format
 msgid "  %s: section \"%s\" is not of integer type.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1656
+#: src/base/cs_restart.c:1658
 #, c-format
 msgid "  %s: section \"%s\" is not of floating-point type.\n"
 msgstr ""
 
-#: src/base/cs_restart.c:1840
+#: src/base/cs_restart.c:1842
 #, c-format
 msgid ""
 "\n"
@@ -4316,14 +3777,6 @@ msgid ""
 "  Elapsed time for reading:         %12.3f\n"
 "  Elapsed time for writing:         %12.3f\n"
 msgstr ""
-"\n"
-"Bilan des écriture / lecture des fichiers de redémarrage :\n"
-"\n"
-"  Nombre de fichiers lus :          %3d\n"
-"  Nombre de fichiers écrits :       %3d\n"
-"\n"
-"  Temps écoulé pour la lecture :    %12.3f\n"
-"  Temps écoulé pour l'écriture :    %12.3f\n"
 
 #: src/base/cs_sat_coupling.c:231
 #, c-format
@@ -4334,23 +3787,18 @@ msgid ""
 "   local number:             %d\n"
 "\n"
 msgstr ""
-" Couplage Code_Saturne :\n"
-"   id de couplage :             %d\n"
-"   nom local :                  \"%s\"\n"
-"   numéro local :               %d\n"
-"\n"
 
 #: src/base/cs_sat_coupling.c:266
 #, c-format
 msgid " Code_Saturne coupling %d: initializing MPI communication ... "
-msgstr " Couplage Code_Saturne %d : initialisation de la communication MPI ..."
+msgstr ""
 
 #: src/base/cs_sat_coupling.c:277 src/base/cs_syr4_coupling.c:211
 #, c-format
 msgid ""
 "  Local ranks = [%d..%d], distant ranks = [%d..%d].\n"
 "\n"
-msgstr "Rangs locaux = [%d..%d], rangs distants = [%d..%d].\n"
+msgstr ""
 
 #: src/base/cs_sat_coupling.c:362
 #, c-format
@@ -4365,115 +3813,86 @@ msgid ""
 "   number of MPI ranks:      %d\n"
 "\n"
 msgstr ""
-" Couplage Code_Saturne :\n"
-"   id de couplage :             %d\n"
-"   nom local :                  \"%s\"\n"
-"   nom d'application distante : \"%s\"\n"
-"   numéro local :               %d\n"
-"   numéro d'application MPI :   %d\n"
-"   rang racine MPI :            %d\n"
-"   nombre de rangs MPI :        %d\n"
-"\n"
 
-#: src/base/cs_sat_coupling.c:1015 src/base/cs_sat_coupling.c:1222
-#: src/base/cs_sat_coupling.c:1289 src/base/cs_sat_coupling.c:1364
-#: src/base/cs_sat_coupling.c:1425 src/base/cs_sat_coupling.c:1495
-#: src/base/cs_sat_coupling.c:1593 src/base/cs_sat_coupling.c:1672
-#: src/base/cs_sat_coupling.c:1763 src/base/cs_sat_coupling.c:1839
-#: src/base/cs_sat_coupling.c:1907
+#: src/base/cs_sat_coupling.c:1016 src/base/cs_sat_coupling.c:1231
+#: src/base/cs_sat_coupling.c:1298 src/base/cs_sat_coupling.c:1373
+#: src/base/cs_sat_coupling.c:1434 src/base/cs_sat_coupling.c:1504
+#: src/base/cs_sat_coupling.c:1602 src/base/cs_sat_coupling.c:1681
+#: src/base/cs_sat_coupling.c:1772 src/base/cs_sat_coupling.c:1848
+#: src/base/cs_sat_coupling.c:1916
 #, c-format
 msgid "Impossible coupling number %d; there are %d couplings"
-msgstr "Numéro de couplage %d impossible ;  on a %d couplages"
+msgstr ""
 
-#: src/base/cs_sat_coupling.c:1030
+#: src/base/cs_sat_coupling.c:1063
 #, c-format
 msgid "coupled_cells_%d"
 msgstr ""
 
-#: src/base/cs_sat_coupling.c:1049
+#: src/base/cs_sat_coupling.c:1074
 #, c-format
 msgid "coupled_faces_%d"
 msgstr ""
 
-#: src/base/cs_sat_coupling.c:1302
+#: src/base/cs_sat_coupling.c:1311
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for LELCPL()\n"
 "NCECPL = %d and NFBCPL = %d are indicated.\n"
 "The values for this coupling should be %d and %d."
 msgstr ""
-"Couplage %d: arguments incohérents pour LELCPL().\n"
-"On a indiqué NCECPL = %d et NFBCPL = %d.\n"
-"On devrait avoir les valeurs %d et %d pour ce couplage."
 
-#: src/base/cs_sat_coupling.c:1377
+#: src/base/cs_sat_coupling.c:1386
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for LELNCP()\n"
 "NCENCP = %d and NFBNCP = %d are indicated.\n"
 "The values for this coupling should be %d and %d."
 msgstr ""
-"Couplage %d: arguments incohérents pour LELNCP().\n"
-"On a indiqué NCENCP = %d et NFBNCP = %d.\n"
-"On devrait avoir les valeurs %d et %d pour ce couplage."
 
-#: src/base/cs_sat_coupling.c:1519
+#: src/base/cs_sat_coupling.c:1528
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for COOCPL()\n"
 "ITYDIS = %d and NBRPTS = %d are indicated.\n"
 "The value for NBRPTS should be %d."
 msgstr ""
-"Couplage %d: arguments incohérents pour COOCPL().\n"
-"On a indiqué ITYDIS = %d et NBRPTS = %d.\n"
-"On devrait avoir la valeur %d pour NBRPTS."
 
-#: src/base/cs_sat_coupling.c:1600
+#: src/base/cs_sat_coupling.c:1609
 msgid ""
 "The centred interpolation scheme is not available\n"
 "when coupling cells"
 msgstr ""
 
-#: src/base/cs_sat_coupling.c:1611
+#: src/base/cs_sat_coupling.c:1620
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for PNDCPL().\n"
 "ITYLOC = %d and NBRPTS = %d are indicated.\n"
 "NBRPTS should be %d."
 msgstr ""
-"Couplage %d: arguments incohérents pour PNDCPL().\n"
-"On a indiqué ITYLOC = %d et NBRPTS = %d.\n"
-"On devrait avoir la valeur %d pour NBRPTS."
 
-#: src/base/cs_sat_coupling.c:1689
+#: src/base/cs_sat_coupling.c:1698
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for VARCPL()\n"
 "ITYVAR = %d and NBRDIS = %d are indicated.\n"
 "NBRDIS should be 0 or %d."
 msgstr ""
-"Couplage %d: arguments incohérents pour VARCPL().\n"
-"On a indiqué ITYVAR = %d et NBRDIS = %d.\n"
-"On devrait avoir la valeur 0 ou %d pour NBRDIS."
 
-#: src/base/cs_sat_coupling.c:1696
+#: src/base/cs_sat_coupling.c:1705
 #, c-format
 msgid ""
 "Coupling %d: inconsistent arguments for VARCPL()\n"
 "ITYVAR = %d and NBRLOC = %d are indicated.\n"
 "NBRLOC should be 0 or %d."
 msgstr ""
-"Couplage %d: arguments incohérents pour VARCPL().\n"
-"On a indiqué ITYVAR = %d et NBRLOC = %d.\n"
-"On devrait avoir la valeur 0 ou %d pour NBRLOC."
 
-#: src/base/cs_sat_coupling.c:2068
+#: src/base/cs_sat_coupling.c:2077
 msgid ""
 "At least 1 Code_Saturne coupling was defined for which\n"
 "no communication with a Code_Saturne instance is possible."
 msgstr ""
-"Au moins 1 couplage Code_Saturne a été défini pour lequel\n"
-"aucune communication avec une instance de Code_Saturne n'est possible."
 
 #: src/base/cs_selector.c:279
 #, c-format
@@ -4483,22 +3902,18 @@ msgid ""
 "\"%s\"\n"
 " does not correspond to any interior face.\n"
 msgstr ""
-"Le groupe ou attribut \"%s\" figurant dans le\n"
-"critère de sélection:\n"
-"\"%s\"\n"
-" ne correspond à aucune face interne.\n"
 
 #: src/base/cs_sles.c:174
 msgid "Conjugate gradient"
-msgstr "Gradient conjugué"
+msgstr ""
 
 #: src/base/cs_sles.c:175
 msgid "Jacobi"
-msgstr "Jacobi"
+msgstr ""
 
 #: src/base/cs_sles.c:176
 msgid "Bi-CGstab"
-msgstr "Bi-CGstab"
+msgstr ""
 
 #: src/base/cs_sles.c:249
 #, c-format
@@ -4512,14 +3927,6 @@ msgid ""
 "  Mean number of iterations:        %d\n"
 "  Total elapsed time:               %12.3f\n"
 msgstr ""
-"\n"
-"Bilan des résolutions pour \"%s\" (%s) :\n"
-"\n"
-"  Nombre d'appels :                 %d\n"
-"  Nombre d'itérations minimal :     %d\n"
-"  Nombre d'itérations maximal :     %d\n"
-"  Nombre d'itérations moyen :       %d\n"
-"  Temps écoulé cumulé :             %12.3f\n"
 
 #: src/base/cs_sles.c:275
 #, c-format
@@ -4528,23 +3935,20 @@ msgid ""
 "  Max local total CPU time:         %12.3f\n"
 "  Total CPU time:                   %12.3f\n"
 msgstr ""
-"  Temps CPU cumulé local min :      %12.3f\n"
-"  Temps CPU cumulé local max :      %12.3f\n"
-"  Temps CPU cumulé total :          %12.3f\n"
 
 #: src/base/cs_sles.c:285
 #, c-format
 msgid "  Total CPU time:                   %12.3f\n"
-msgstr "  Temps CPU cumulé :                %12.3f\n"
+msgstr ""
 
 #: src/base/cs_sles.c:394
 msgid "  n_iter     res_abs     res_nor\n"
-msgstr "  n_iter     res_abs     res_nor\n"
+msgstr ""
 
 #: src/base/cs_sles.c:424 src/base/cs_sles.c:1362
 #, c-format
 msgid "  n_iter : %5d, res_abs : %11.4e, res_nor : %11.4e\n"
-msgstr "  n_iter : %5d, res_abs : %11.4e, res_nor : %11.4e\n"
+msgstr ""
 
 #: src/base/cs_sles.c:450
 #, c-format
@@ -4554,14 +3958,10 @@ msgid ""
 "%s [%s]: divergence after %u iterations:\n"
 "  initial residual: %11.4e; current residual: %11.4e\n"
 msgstr ""
-"\n"
-"\n"
-"%s [%s] : divergence après %u itérations :\n"
-"  résidu initial : %11.4e ; résidu courant : %11.4e\n"
 
 #: src/base/cs_sles.c:468
 msgid " @@ Warning: non convergence\n"
-msgstr " @@ Attention : non convergence\n"
+msgstr ""
 
 #: src/base/cs_sles.c:1374
 #, c-format
@@ -4575,14 +3975,6 @@ msgid ""
 "\n"
 "    The matrix cannot be considered as invertible anymore."
 msgstr ""
-"\n"
-"\n"
-"%s [%s]:\n"
-" @@ Attention : non convergence et arrêt\n"
-"\n"
-"    Le coefficient alpha est inférieur à %12.4e\n"
-"\n"
-"    La matrice ne peut plus être considérée come  inversible."
 
 #: src/base/cs_sles.c:1439
 #, c-format
@@ -4597,15 +3989,6 @@ msgid ""
 "\n"
 "    The resolution does not progress anymore."
 msgstr ""
-"\n"
-"\n"
-"%s [%s]:\n"
-" @@ Attention : non convergence et arrêt\n"
-"\n"
-"    Le carre de la norme du vecteur de descente\n"
-"    est inférieur à %12.4e\n"
-"\n"
-"    La résolution ne progresse plus."
 
 #: src/base/cs_sles.c:1747
 #, c-format
@@ -4618,13 +4001,11 @@ msgid ""
 "%s [%s]:\n"
 "  immediate exit; r_norm = %11.4e, residual = %11.4e\n"
 msgstr ""
-"%s [%s]:\n"
-"  sortie immédiate ; r_norm = %11.4e, residu = %11.4e\n"
 
 #: src/base/cs_syr3_comm.c:151
 #, c-format
 msgid "Error in socket communication:  %s (node %4d)\n"
-msgstr "Erreur pour la communication par socket :  %s (noeud %4d)\n"
+msgstr ""
 
 #: src/base/cs_syr3_comm.c:175
 #, c-format
@@ -4632,8 +4013,6 @@ msgid ""
 "MPI error for communication:  %s\n"
 "Error type: %s"
 msgstr ""
-"Erreur MPI pour la communication :  %s\n"
-"Type d'erreur : %s"
 
 #: src/base/cs_syr3_comm.c:204
 #, c-format
@@ -4642,9 +4021,6 @@ msgid ""
 "because the requested process rank (%d)\n"
 "is greater than or equal to the number of MPI processes (%d)"
 msgstr ""
-"Impossible d'établir la communication : %s\n"
-"car le rang du processus recherché (%d)\n"
-"est supérieur ou égal au nombre de processus MPI (%d)."
 
 #: src/base/cs_syr3_comm.c:228
 #, c-format
@@ -4655,11 +4031,6 @@ msgid ""
 "magic string read:     \"%s\"\n"
 "magic string expected: \"%s\"\n"
 msgstr ""
-"Erreur pour la communication : \"%s\".\n"
-"Le format de l'interface n'est pas à la bonne version.\n"
-"La chaîne magique indique une mauvaise version du format de l'interface.\n"
-"chaîne magique lue      : \"%s\"\n"
-"chaîne magique attendue : \"%s\"\n"
 
 #: src/base/cs_syr3_comm.c:488
 #, c-format
@@ -4667,8 +4038,6 @@ msgid ""
 "Communication %s:\n"
 "Error while receiving data by socket.\n"
 msgstr ""
-"Communication %s :\n"
-"Erreur de réception de données par socket.\n"
 
 #: src/base/cs_syr3_comm.c:570
 #, c-format
@@ -4676,39 +4045,31 @@ msgid ""
 "Communication %s:\n"
 "Error sending data by socket.\n"
 msgstr ""
-"Communication %s :\n"
-"Erreur d'envoi de données par socket.\n"
 
 #: src/base/cs_syr3_comm.c:626 src/base/cs_syr3_comm.c:679
 #: src/base/cs_syr3_comm.c:688 src/base/cs_syr3_comm.c:696
 msgid "Error in socket communication\n"
-msgstr "Erreur de communication par socket\n"
+msgstr ""
 
 #: src/base/cs_syr3_comm.c:646
 msgid ""
 "Error while sending the host name through MPI in sockets initialization.\n"
 msgstr ""
-"Erreur lors de l'envoi via MPI du nom de l'hôte en initialisant les "
-"sockets.\n"
 
 #: src/base/cs_syr3_comm.c:656
 msgid ""
 "Error while sending the port number through MPI in sockets initialization.\n"
 msgstr ""
-"Erreur lors de l'envoi via MPI du numéro du port en initialisant les "
-"sockets.\n"
 
 #: src/base/cs_syr3_comm.c:666
 msgid "MPI is needed for socket initialization.\n"
-msgstr "Besoin de MPI lors de l'initialisation des sockets.\n"
+msgstr ""
 
 #: src/base/cs_syr3_comm.c:734
 msgid ""
 "Attempt to connect to the communication port with\n"
 "an unknown message format\n"
 msgstr ""
-"Tentative de connexion au port de communication avec\n"
-"un format de message non reconnu\n"
 
 #: src/base/cs_syr3_comm.c:753
 #, c-format
@@ -4719,11 +4080,6 @@ msgid ""
 "magic string read:     \"%s\"\n"
 "magic string expected: \"%s\"\n"
 msgstr ""
-"Erreur à l'initialisation de la communication : \"%s\".\n"
-"Le format de l'interface n'est pas à la bonne version.\n"
-"La chaîne magique repère la version du format d'interface :\n"
-"chaîne magique lue      : \"%s\"\n"
-"chaîne magique actuelle : \"%s\"\n"
 
 #: src/base/cs_syr3_comm.c:780
 #, c-format
@@ -4731,8 +4087,6 @@ msgid ""
 "Communication %s):\n"
 "Error closing the socket.\n"
 msgstr ""
-"Communication %s) :\n"
-"Erreur à la fermeture du socket.\n"
 
 #: src/base/cs_syr3_comm.c:800
 #, c-format
@@ -4740,8 +4094,6 @@ msgid ""
 "\n"
 "Message received on \"%s\":\n"
 msgstr ""
-"\n"
-"Message reçu sur \"%s\" :\n"
 
 #: src/base/cs_syr3_comm.c:803
 #, c-format
@@ -4749,8 +4101,6 @@ msgid ""
 "\n"
 "Message sent on \"%s\":\n"
 msgstr ""
-"\n"
-"Message envoyé sur \"%s\" :\n"
 
 #: src/base/cs_syr3_comm.c:825
 #, c-format
@@ -4758,8 +4108,6 @@ msgid ""
 "    section name:          \"%s\"\n"
 "    number of elements:    %d\n"
 msgstr ""
-"    nom de la rubrique :    \"%s\"\n"
-"    nombre d'éléments :     %d\n"
 
 #: src/base/cs_syr3_comm.c:1017
 #, c-format
@@ -4767,8 +4115,6 @@ msgid ""
 "\n"
 "  Opening communication:  %s ..."
 msgstr ""
-"\n"
-"  Ouverture de la communication :  %s ..."
 
 #: src/base/cs_syr3_comm.c:1063
 #, c-format
@@ -4776,25 +4122,21 @@ msgid ""
 "\n"
 "  Closing communication:  %s\n"
 msgstr ""
-"\n"
-"  Fermeture de la communication :  %s\n"
 
 #: src/base/cs_syr3_comm.c:1536 src/base/cs_syr3_comm.c:1574
 #: src/base/cs_syr3_comm.c:1578 src/base/cs_syr3_comm.c:1586
 msgid "Initialization error for socket communication support.\n"
-msgstr "Erreur d'initialisation du support de communication par socket.\n"
+msgstr ""
 
 #: src/base/cs_syr3_comm.c:1564
 msgid "Error obtaining computer's name"
-msgstr "Erreur de récupération du nom de la machine"
+msgstr ""
 
 #: src/base/cs_syr3_comm.c:1633
 msgid ""
 "\n"
 "Closing socket...\t [ok]\n"
 msgstr ""
-"\n"
-"Fermeture du socket ...\t [ok]\n"
 
 #: src/base/cs_syr3_coupling.c:228
 #, c-format
@@ -4802,40 +4144,32 @@ msgid ""
 "\n"
 "Extracting \"%s\" mesh\n"
 msgstr ""
-"\n"
-"Extraction du maillage \"%s\"\n"
 
 #: src/base/cs_syr3_coupling.c:263
 msgid ""
 "\n"
 " *** Renumbering of the boundary faces list    ..."
 msgstr ""
-"\n"
-" *** Renumerotation de la liste des faces de bord    ..."
 
 #: src/base/cs_syr3_coupling.c:827 src/base/cs_syr4_coupling.c:623
 msgid "Wall T"
-msgstr "T Paroi"
+msgstr ""
 
 #: src/base/cs_syr3_coupling.c:837 src/base/cs_syr4_coupling.c:623
 msgid "Flux"
-msgstr "Flux"
+msgstr ""
 
 #: src/base/cs_syr3_coupling.c:1096
 msgid ""
 "Coupling with SYRTHES impossible.\n"
 "No selection criteria for faces to couple."
 msgstr ""
-"Couplage avec SYRTHES impossible.\n"
-"Aucun critère de sélection pour les faces à coupler."
 
 #: src/base/cs_syr3_coupling.c:1223
 msgid ""
 "\n"
 "Structures associated with SYRTHES 3 coupling freed.\n"
 msgstr ""
-"\n"
-"Libération des structures associées au couplage avec SYRTHES 3.\n"
 
 #: src/base/cs_syr3_coupling.c:1253 src/base/cs_syr4_coupling.c:976
 #, c-format
@@ -4844,31 +4178,26 @@ msgid ""
 " ** Processing the mesh for SYRTHES coupling \"%d\"\n"
 "\n"
 msgstr ""
-"\n"
-" ** Traitement du maillage pour le couplage SYRTHES \"%d\"\n"
-"\n"
 
 #: src/base/cs_syr3_coupling.c:1275
 msgid ""
 "Coupling with SYRTHES impossible.\n"
 "No face to couple.\n"
 msgstr ""
-"Couplage avec SYRTHES impossible.\n"
-"Aucune face à coupler.\n"
 
 #: src/base/cs_syr3_coupling.c:1283
 #, c-format
 msgid "Triangulation of the extracted mesh (%d faces)  ..."
-msgstr "Triangulation du maillage extrait (%d faces)  ..."
+msgstr ""
 
 #: src/base/cs_syr3_coupling.c:1296
 #, c-format
 msgid "Splitting the extracted mesh in edges (%d faces)  ..."
-msgstr "Décomposition en arêtes du maillage extrait (%d faces)  ..."
+msgstr ""
 
 #: src/base/cs_syr3_coupling.c:1311
 msgid "Error triangulating the extracted mesh before sending to SYRTHES.\n"
-msgstr "Erreur lors du découpage du maillage extrait avant envoi à Syrthes.\n"
+msgstr ""
 
 #: src/base/cs_syr3_coupling.c:1405
 #, c-format
@@ -4876,8 +4205,6 @@ msgid ""
 "\n"
 "Extracted mesh built of %d triangles"
 msgstr ""
-"\n"
-"Maillage extrait composé de %d triangles"
 
 #: src/base/cs_syr3_coupling.c:1407
 #, c-format
@@ -4885,21 +4212,19 @@ msgid ""
 "\n"
 "Extracted mesh built of %d edges"
 msgstr ""
-"\n"
-"Maillage extrait composé de %d arêtes"
 
 #: src/base/cs_syr3_coupling.c:1411
 #, c-format
 msgid " and %d vertices (locally)\n"
-msgstr " et %d sommets (localement)\n"
+msgstr ""
 
 #: src/base/cs_syr3_coupling.c:1491
 msgid "\tInterpolation from vertices to elements            ..."
-msgstr "\tInterpolation des sommets vers les éléments           ..."
+msgstr ""
 
 #: src/base/cs_syr3_coupling.c:1580
 msgid "\tInterpolation from elements to vertices            ..."
-msgstr "\tInterpolation des éléments sur les sommets            ..."
+msgstr ""
 
 #: src/base/cs_syr3_messages.c:157 src/base/cs_syr4_coupling.c:933
 #, c-format
@@ -4910,11 +4235,6 @@ msgid ""
 "      received message: \"%s\"\n"
 "========================================================\n"
 msgstr ""
-"========================================================\n"
-"   ** Arret par demande de SYRTHES\n"
-"      ----------------------------\n"
-"      message recu : \"%s\"\n"
-"========================================================\n"
 
 #: src/base/cs_syr3_messages.c:172
 #, c-format
@@ -4926,19 +4246,13 @@ msgid ""
 "      expected message: cmd:iter:start \n"
 "========================================================\n"
 msgstr ""
-"========================================================\n"
-"   ** Message inattendu dans cs_syr3_messages_test_iter\n"
-"      -------------------------------------------------\n"
-"      message reçu :    \"%s\"\n"
-"      message attendu : cmd:iter:start\n"
-"========================================================\n"
 
 #: src/base/cs_syr3_messages.c:276 src/base/cs_syr3_messages.c:359
 #: src/base/cs_syr_coupling.c:793 src/base/cs_syr_coupling.c:834
 #: src/base/cs_syr_coupling.c:873 src/base/cs_syr_coupling.c:912
 #, c-format
 msgid "SYRTHES coupling number %d impossible; there are %d couplings"
-msgstr "Numéro de couplage SYRTHES %d impossible ;  on a %d couplages"
+msgstr ""
 
 #: src/base/cs_syr3_messages.c:307
 #, c-format
@@ -4947,32 +4261,27 @@ msgid ""
 " expected \"%s\" (%d elements, type %d)\n"
 " received \"%s\" (%d elements, type %d)\n"
 msgstr ""
-"Message inatendu dans le couplage SYRTHES %d :\n"
-" on attendait \"%s\" (%d éléments, type %d)\n"
-" on a reçu    \"%s\"(%d éléments, type %d)\n"
 
 #: src/base/cs_syr4_coupling.c:200
 #, c-format
 msgid " SYRTHES coupling %d: initializing MPI communication ... "
-msgstr " Couplage SYRTHES %d : initialisation de la communication MPI ..."
+msgstr ""
 
 #: src/base/cs_syr4_coupling.c:349
 msgid ""
 "\n"
 "Extracting coupled mesh             ..."
 msgstr ""
-"\n"
-"Extraction du maillage couplé           ..."
 
 #: src/base/cs_syr4_coupling.c:357
 #, c-format
 msgid "SYRTHES_cells_%d"
-msgstr "Cellules_SYRTHES_%d"
+msgstr ""
 
 #: src/base/cs_syr4_coupling.c:378
 #, c-format
 msgid "SYRTHES_faces_%d"
-msgstr "Faces_SYRTHES_%d"
+msgstr ""
 
 #: src/base/cs_syr4_coupling.c:405
 #, c-format
@@ -4981,53 +4290,41 @@ msgid ""
 " \"%s\"\n"
 " leads to an empty mesh for SYRTHES coupling.\n"
 msgstr ""
-" Le critère de sélection :\n"
-" \"%s\"\n"
-" produit un maillage vide pour le couplage SYRTHES.\n"
 
 #: src/base/cs_syr4_coupling.c:420
 msgid "Projecting the extracted mesh to 2D ..."
-msgstr "Projection 2D du maillage extrait  ..."
+msgstr ""
 
 #: src/base/cs_syr4_coupling.c:428
 msgid "Error projecting the extracted mesh."
-msgstr "Erreur lors de la projection du maillage extrait."
+msgstr ""
 
 #: src/base/cs_syr4_coupling.c:455
 #, c-format
 msgid ""
 "\n"
-"Extracted mesh built of %lu elements.\n"
+"Extracted mesh built of %llu elements.\n"
 msgstr ""
-"\n"
-"Maillage extrait composé de %lu éléments.\n"
 
 #: src/base/cs_syr4_coupling.c:506
 #, c-format
 msgid ""
 "Coupling with SYRTHES impossible:\n"
-"%lu element centers from mesh \"%s\"\n"
+"%llu element centers from mesh \"%s\"\n"
 "not located on SYRTHES mesh."
 msgstr ""
-"Couplage avec SYRTHES impossible :\n"
-"%lu centres d'éléments du maillage \"%s\"\n"
-"non localisés sur le maillage SYRTHES."
 
 #: src/base/cs_syr4_coupling.c:762
 msgid ""
 "Coupling with SYRTHES impossible.\n"
 "No selection criteria for faces or cells to couple."
 msgstr ""
-"Couplage avec SYRTHES impossible.\n"
-"Aucun critère de sélection pour les faces ou les cellules à coupler."
 
 #: src/base/cs_syr4_coupling.c:830
 msgid ""
 "\n"
 "Structures associated with SYRTHES 4 coupling freed.\n"
 msgstr ""
-"\n"
-"Libération des structures associées au couplage avec SYRTHES 4.\n"
 
 #: src/base/cs_syr4_coupling.c:877
 #, c-format
@@ -5039,12 +4336,6 @@ msgid ""
 "      SYRTHES options:      \"%s\"\n"
 "========================================================\n"
 msgstr ""
-"========================================================\n"
-"   ** Options de couplage avec SYRTHES incompatibles :\n"
-"      ------------------------------------------------ \n"
-"      Options Code_Saturne : \"%s\"\n"
-"      Options SYRTHES      : \"%s\"\n"
-"========================================================\n"
 
 #: src/base/cs_syr4_coupling.c:948
 #, c-format
@@ -5056,12 +4347,6 @@ msgid ""
 "      expected message: cmd:iter:start \n"
 "========================================================\n"
 msgstr ""
-"========================================================\n"
-"   ** Message inattendu dans cs_syr4_messages_test_iter\n"
-"      -------------------------------------------------\n"
-"      message reçu :    \"%s\"\n"
-"      message attendu : cmd:iter:start\n"
-"========================================================\n"
 
 #: src/base/cs_syr4_coupling.c:1007
 #, c-format
@@ -5069,8 +4354,6 @@ msgid ""
 " Message received from SYRTHES: \"%s\"\n"
 " indicates an error or is unexpected."
 msgstr ""
-" Le message reçu de SYRTHES: \"%s\"\n"
-" indique une erreur ou est inattendu."
 
 #: src/base/cs_syr4_coupling.c:1012
 #, c-format
@@ -5079,9 +4362,6 @@ msgid ""
 " ** Mesh located for SYRTHES coupling \"%d\".\n"
 "\n"
 msgstr ""
-"\n"
-" ** Localisation du maillage pour le couplage SYRTHES \"%d\".\n"
-"\n"
 
 #: src/base/cs_syr_coupling.c:192
 #, c-format
@@ -5092,11 +4372,6 @@ msgid ""
 "   local number:             %d\n"
 "\n"
 msgstr ""
-" Couplage SYRTHES :\n"
-"   id de couplage :             %d\n"
-"   nom local :                  \"%s\"\n"
-"   numéro local :               %d\n"
-"\n"
 
 #: src/base/cs_syr_coupling.c:309
 #, c-format
@@ -5112,24 +4387,12 @@ msgid ""
 "   number of MPI ranks:      %d\n"
 "\n"
 msgstr ""
-" Couplage SYRTHES :\n"
-"   id de couplage :             %d\n"
-"   version :                    \"%s\"\n"
-"   nom local :                  \"%s\"\n"
-"   nom d'application distante : \"%s\"\n"
-"   numéro local :               %d\n"
-"   numéro d'application MPI :   %d\n"
-"   rang racine MPI :            %d\n"
-"   nombre de rangs MPI :        %d\n"
-"\n"
 
 #: src/base/cs_syr_coupling.c:1080
 msgid ""
 "At least 1 SYRTHES coupling was defined for which\n"
 "no communication with a SYRTHES instance is possible."
 msgstr ""
-"Au moins 1 couplage SYRTHES a été défini pour lequel\n"
-"aucune communication avec une instance de SYRTHES n'est possible."
 
 #: src/base/cs_tpar1d.c:444
 #, c-format
@@ -5137,9 +4400,6 @@ msgid ""
 "Abort while opening the 1D-wall thermal module restart file in read mode.\n"
 "Verify the existence and the name of the restart file: %s\n"
 msgstr ""
-"Arret à l'ouverture en lecture du fichier suite du module thermique 1D en "
-"paroi.\n"
-"Vérifier l'existence et le nom du fichier suite: %s \n"
 
 #: src/base/cs_tpar1d.c:461 src/ctwr/cs_ctwr.c:672
 msgid ""
@@ -5147,9 +4407,6 @@ msgid ""
 "The number of boundary faces has been modified\n"
 "Verify that the restart file corresponds to the present study.\n"
 msgstr ""
-"Arret de lecture du fichier suite du modulethermique 1D en paroi.\n"
-"Le nombre de faces de bord a été modifié\n"
-"Vérifier que le fichier suite correspond bien au cas traité.\n"
 
 #: src/base/cs_tpar1d.c:486
 #, c-format
@@ -5165,16 +4422,6 @@ msgid ""
 "Verify that the restart file corresponds to a\n"
 "restart file for the 1D-wall thermal module.\n"
 msgstr ""
-"ATTENTION : ARRET A LA LECTURE DU FICHIER SUITE\n"
-"*********                  MODULE THERMIQUE 1D EN PAROI\n"
-"      TYPE DE FICHIER INCORRECT\n"
-"\n"
-"Le fichier %s ne semble pas etre un fichier\n"
-"suite de module thermique 1D en paroi.\n"
-"Le calcul ne peut etre execute.\n"
-"\n"
-"Verifier que le fichier suite utilise correspond bien\n"
-"a un fichier suite de module thermique 1D en paroi.\n"
 
 #: src/base/cs_tpar1d.c:525 src/base/cs_tpar1d.c:613 src/base/cs_tpar1d.c:667
 #: src/base/cs_tpar1d.c:703
@@ -5185,10 +4432,6 @@ msgid ""
 "<%s>\n"
 "The calculation will not be run.\n"
 msgstr ""
-"Problème à la lecture de la rubrique dans le fichier suite du module "
-"thermique 1D en paroi:\n"
-"<%s>\n"
-"Le calcul ne sera pas executé.\n"
 
 #: src/base/cs_tpar1d.c:544
 #, c-format
@@ -5208,20 +4451,6 @@ msgid ""
 "restart file for the 1D-wall thermal module.\n"
 "Verify uspt1d.\n"
 msgstr ""
-"ATTENTION : LECTURE DU FICHIER SUITE\n"
-"*********   MODULE THERMIQUE 1D EN PAROI\n"
-"      DONNEES AMONT ET ACTUELLES DIFFERENTES\n"
-"\n"
-"Le nombre de faces avec module thermique 1D a été\n"
-"modifié.\n"
-"AMONT  : %d faces de bord au total\n"
-"ACTUEL : %d faces de bord au total\n"
-"\n"
-"Le calcul ne peut être exécuté.\n"
-"\n"
-"Vérifier que le fichier suite utilisé correspond bien\n"
-"au cas traité.\n"
-"Vérifier uspt1d.\n"
 
 #: src/base/cs_tpar1d.c:570
 msgid ""
@@ -5241,21 +4470,6 @@ msgid ""
 "(refer to the user manual for the specificities\n"
 "of the test on IFPT1D)"
 msgstr ""
-"ATTENTION : LECTURE DU FICHIER SUITE\n"
-"*********   MODULE THERMIQUE 1D EN PAROI\n"
-"    DONNEES AMONT ET ACTUELLES DIFFERENTES\n"
-"\n"
-"IFPT1D ou NPPT1D a été modifié par rapport au\n"
-"fichier suite sur au moins une face avec module\n"
-"thermique 1D.\n"
-"\n"
-"Le calcul ne peut être executé.\n"
-"\n"
-"Vérifier que le fichier suite utilisé correspond bien\n"
-"au cas traité.\n"
-"Vérifier uspt1d\n"
-"(se reporter à la documentation utilisateur pour les\n"
-"spécificités du test sur IFPT1D)"
 
 #: src/base/cs_tpar1d.c:626
 msgid ""
@@ -5273,19 +4487,6 @@ msgid ""
 "the present study.\n"
 "Verify uspt1d\n"
 msgstr ""
-"ATTENTION : LECTURE DU FICHIER SUITE\n"
-"*********   MODULE THERMIQUE 1D EN PAROI\n"
-"      DONNEES AMONT ET ACTUELLES DIFFERENTES\n"
-"\n"
-"Le paramètre EPPT1D a été modifié par rapport au fichier\n"
-"fichier suite sur au moins une face avec module\n"
-"thermique 1D.\n"
-"\n"
-"Le calcul ne peut être exécuté.\n"
-"\n"
-"Vérifier que le fichier suite utilisé correspond bien\n"
-"au cas traité.\n"
-"Vérifier uspt1d.\n"
 
 #: src/base/cs_tpar1d.c:722
 msgid ""
@@ -5303,19 +4504,6 @@ msgid ""
 "the present study\n"
 "Verify uspt1d\n"
 msgstr ""
-"ATTENTION : LECTURE DU FICHIER SUITE\n"
-"*********   MODULE THERMIQUE 1D EN PAROI \n"
-"      DONNEES AMONT ET ACTUELLES DIFFERENTES\n"
-"\n"
-"Le parametre RGPT1D a été modifié par rapport au fichier\n"
-"fichier suite sur au moins une face avec module\n"
-"thermique 1D.\n"
-"\n"
-"Le calcul ne peut être exécuté.\n"
-"\n"
-"Vérifier que le fichier suite utilise correspond bien\n"
-"au cas traité.\n"
-"Verifier uspt1d.\n"
 
 #: src/base/cs_tpar1d.c:768
 #, c-format
@@ -5324,9 +4512,6 @@ msgid ""
 "for the 1D-wall thermal module:\n"
 "<%s>\n"
 msgstr ""
-"Problème à la lecture de la rubrique dans le fichier suite du module "
-"thermique 1D en paroi:\n"
-"<%s>\n"
 
 #: src/base/cs_tpar1d.c:837
 #, c-format
@@ -5334,9 +4519,6 @@ msgid ""
 "Abort while opening the 1D-wall thermal module restart file in write mode.\n"
 "Verify the existence and the name of the restart file: %s\n"
 msgstr ""
-"Arret à l''ouverture en écriture du fichier suite du module thermique 1D en "
-"paroi.\n"
-"Vérifier l''existence et le nom du fichier suite: %s \n"
 
 #: src/ctwr/cs_ctwr.c:477
 #, c-format
@@ -5344,8 +4526,6 @@ msgid ""
 "Abort while opening the cooling tower module restart file in write mode.\n"
 "Verify the existence and the name of the restart file: %s\n"
 msgstr ""
-"Arret à l'ouverture en écriture du fichier suite aéroréfrigérants.\n"
-"Vérifier l''existence et le nom du fichier suite: %s \n"
 
 #: src/ctwr/cs_ctwr.c:655
 #, c-format
@@ -5354,8 +4534,6 @@ msgid ""
 "mode.\n"
 "Verify the existence and the name of the restart file: %s\n"
 msgstr ""
-"Arret à l'ouverture en lecture du fichier suite aéroréfrigérants.\n"
-"Vérifier l'existence et le nom du fichier suite: %s \n"
 
 #: src/ctwr/cs_ctwr.c:722 src/ctwr/cs_ctwr.c:793 src/ctwr/cs_ctwr.c:861
 #: src/ctwr/cs_ctwr.c:891 src/ctwr/cs_ctwr.c:921
@@ -5366,10 +4544,6 @@ msgid ""
 "<%s>\n"
 "The calculation will not be run.\n"
 msgstr ""
-"Problème à la lecture de la rubrique dans le fichier suite du module "
-"aéroréfrigérants :\n"
-"<%s>\n"
-"Le calcul ne sera pas executé.\n"
 
 #: src/ctwr/cs_ctwr.c:730
 #, c-format
@@ -5413,20 +4587,6 @@ msgid ""
 "restart file for the cooling tower  module.\n"
 "Verify usctdz.\n"
 msgstr ""
-"ATTENTION : LECTURE DU FICHIER SUITE\n"
-"*********   MODULE AEROREFRIGERANTS\n"
-"      DONNEES AMONT ET ACTUELLES DIFFERENTES\n"
-"\n"
-"Le nombre de noeuds sur les maillages verticaux\n"
-"pour le maillage eau a été modifié.\n"
-"AMONT  : %d noeuds\n"
-"ACTUEL : %d noeuds\n"
-"\n"
-"Le calcul ne peut être exécuté.\n"
-"\n"
-"Vérifier que le fichier suite utilisé correspond bien\n"
-"au cas traité.\n"
-"Vérifier usctdz.\n"
 
 #: src/ctwr/cs_ctwr.c:801
 #, c-format
@@ -5474,11 +4634,11 @@ msgstr ""
 
 #: src/ctwr/cs_ctwr_halo.c:1523
 msgid "    Updating the vertex -> faces connectivity\n"
-msgstr "    Mise à jour de la connectivité faces -> cellules\n"
+msgstr ""
 
 #: src/ctwr/cs_ctwr_halo.c:1555
 msgid "    Distant halo definition\n"
-msgstr "    Création du halo distant\n"
+msgstr ""
 
 #: src/ctwr/cs_ctwr_mesh.c:1198
 msgid " Creating halos\n"
@@ -5494,10 +4654,7 @@ msgid ""
 "overflow |%g| > %g\n"
 "Verify the bounding box for your data."
 msgstr ""
-"Dépassement |%g| > %g\n"
-"Vérifiez la boite englobante pour vos données."
 
 #: src/lagr/cs_lagr.c:464
 msgid "IEEE 754 arithmetic is not supported by the current architecture."
 msgstr ""
-"L'arithmétique IEEE 754 n'est pas respectée par l'architecture courante."
diff --git a/src/Makefile.in b/src/Makefile.in
index 26debbe..ff5deaf 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -70,15 +70,26 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/cs_config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -124,6 +135,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -147,6 +159,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -198,6 +211,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -254,6 +268,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -291,7 +306,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
diff --git a/src/apps/Makefile.in b/src/apps/Makefile.in
index df92c25..3cb91f6 100644
--- a/src/apps/Makefile.in
+++ b/src/apps/Makefile.in
@@ -75,9 +75,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -122,7 +127,10 @@ libsaturne_la_DEPENDENCIES = $(top_builddir)/src/base/libcshot.la \
 	$(top_builddir)/src/rayt/libcsrayt.la
 am_libsaturne_la_OBJECTS = cs_solver.lo
 libsaturne_la_OBJECTS = $(am_libsaturne_la_OBJECTS)
-libsaturne_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libsaturne_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
 	$(libsaturne_la_LDFLAGS) $(LDFLAGS) -o $@
 PROGRAMS = $(bin_PROGRAMS)
@@ -136,13 +144,26 @@ am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_$(V))
+am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
+am__v_CC_0 = @echo "  CC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_$(V))
+am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_CCLD_0 = @echo "  CCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libsaturne_la_SOURCES) $(cs_solver_SOURCES)
 DIST_SOURCES = $(libsaturne_la_SOURCES) $(cs_solver_SOURCES)
 ETAGS = etags
@@ -150,6 +171,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -173,6 +195,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -224,6 +247,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -280,6 +304,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -317,7 +342,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -450,7 +474,7 @@ clean-libLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libsaturne.la: $(libsaturne_la_OBJECTS) $(libsaturne_la_DEPENDENCIES) 
-	$(libsaturne_la_LINK) -rpath $(libdir) $(libsaturne_la_OBJECTS) $(libsaturne_la_LIBADD) $(LIBS)
+	$(AM_V_CCLD)$(libsaturne_la_LINK) -rpath $(libdir) $(libsaturne_la_OBJECTS) $(libsaturne_la_LIBADD) $(LIBS)
 install-binPROGRAMS: $(bin_PROGRAMS)
 	@$(NORMAL_INSTALL)
 	test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)"
@@ -496,7 +520,7 @@ clean-binPROGRAMS:
 	rm -f $$list
 cs_solver$(EXEEXT): $(cs_solver_OBJECTS) $(cs_solver_DEPENDENCIES) 
 	@rm -f cs_solver$(EXEEXT)
-	$(LINK) $(cs_solver_OBJECTS) $(cs_solver_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(cs_solver_OBJECTS) $(cs_solver_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -507,22 +531,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_solver.Plo at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
diff --git a/src/apps/cs_solver.c b/src/apps/cs_solver.c
index 361c92a..19ff074 100644
--- a/src/apps/cs_solver.c
+++ b/src/apps/cs_solver.c
@@ -70,10 +70,6 @@
 #include <bft_printf.h>
 #include <bft_timer.h>
 
-#if !defined(_GNU_SOURCE)
-#include <bft_fp_trap.h>
-#endif
-
 /*----------------------------------------------------------------------------
  * FVM library headers
  *----------------------------------------------------------------------------*/
@@ -204,6 +200,13 @@ cs_run(void)
   cs_glob_mesh_builder = cs_mesh_builder_create();
   cs_glob_mesh_quantities = cs_mesh_quantities_create();
 
+  /* Define joining and periodicity parameters if requested
+     Must be done before initi1 for the sake of verification */
+
+  CS_PROCF (usjoin, USJOIN)();
+
+  CS_PROCF (usperi, USPERI)();
+
   /* Call main calculation initialization function or help */
 
   _verif = (opts.verif == true || opts.benchmark > 0) ? 1 : 0;
@@ -247,9 +250,7 @@ cs_run(void)
 
   cs_post_init_main_writer();
 
-  /* Join meshes if necessary */
-
-  CS_PROCF (usjoin, USJOIN)();
+  /* Join meshes / build periodicity links if necessary */
 
   cs_join_all();
 
@@ -575,8 +576,6 @@ main(int    argc,
       /* To revert to initial behavior: fesetenv(&_fenv_old); */
     }
   }
-#else
-  bft_fp_trap_set();
 #endif
 
   /* Initialize memory management and signals */
diff --git a/src/atmo/Makefile.in b/src/atmo/Makefile.in
index ca19260..9066d94 100644
--- a/src/atmo/Makefile.in
+++ b/src/atmo/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -91,17 +96,32 @@ am_libcsatmo_la_OBJECTS = atini1.lo atiniv.lo atlecm.lo atmcls.lo \
 	atphyv.lo atprke.lo atprop.lo attycl.lo atvarp.lo intprf.lo \
 	mematm.lo usatcl.lo usati1.lo usativ.lo
 libcsatmo_la_OBJECTS = $(am_libcsatmo_la_OBJECTS)
-libcsatmo_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcsatmo_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcsatmo_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcsatmo_la_SOURCES)
 DIST_SOURCES = $(libcsatmo_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -134,6 +154,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -157,6 +178,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -208,6 +230,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -264,6 +287,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -301,7 +325,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -402,7 +425,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcsatmo.la: $(libcsatmo_la_OBJECTS) $(libcsatmo_la_DEPENDENCIES) 
-	$(libcsatmo_la_LINK)  $(libcsatmo_la_OBJECTS) $(libcsatmo_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcsatmo_la_LINK)  $(libcsatmo_la_OBJECTS) $(libcsatmo_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -411,22 +434,28 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 usatcl.lo: $(top_srcdir)/users/atmo/usatcl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usatcl.lo `test -f '$(top_srcdir)/users/atmo/usatcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/atmo/usatcl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usatcl.lo `test -f '$(top_srcdir)/users/atmo/usatcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/atmo/usatcl.f90
 
 usati1.lo: $(top_srcdir)/users/atmo/usati1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usati1.lo `test -f '$(top_srcdir)/users/atmo/usati1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/atmo/usati1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usati1.lo `test -f '$(top_srcdir)/users/atmo/usati1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/atmo/usati1.f90
 
 usativ.lo: $(top_srcdir)/users/atmo/usativ.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usativ.lo `test -f '$(top_srcdir)/users/atmo/usativ.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/atmo/usativ.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usativ.lo `test -f '$(top_srcdir)/users/atmo/usativ.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/atmo/usativ.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/atmo/atiniv.f90 b/src/atmo/atiniv.f90
index 1473aec..7dd530f 100644
--- a/src/atmo/atiniv.f90
+++ b/src/atmo/atiniv.f90
@@ -229,12 +229,17 @@ endif
 ! 3. Dry atmosphere: default initialization of potential temperature
 !===============================================================================
 
-if (ippmod(iatmos).eq.1) then
-  ! The thermal scalar is potential temperature
-  iphas = 1
-  do iel = 1, ncel
-    rtp(iel,isca(iscalt(iphas))) = t0(iphas)
-  enddo
+! Only if the simulation is not a restart from another one
+if (isuite.eq.0) then
+
+  if (ippmod(iatmos).eq.1) then
+    ! The thermal scalar is potential temperature
+    iphas = 1
+    do iel = 1, ncel
+      rtp(iel,isca(iscalt(iphas))) = t0(iphas)
+    enddo
+  endif
+
 endif
 
 !===============================================================================
diff --git a/src/atmo/atmcls.f90 b/src/atmo/atmcls.f90
index fddc3e4..e39f5a8 100644
--- a/src/atmo/atmcls.f90
+++ b/src/atmo/atmcls.f90
@@ -275,7 +275,6 @@ actt = xkappa/log((distbf+rugt)/rugt)
 ! NB: rib =0 if thermal flux conditions are imposed and tpot1 not defined
 if (abs(utau).le.epzero.or.icodcl(ifac,isca(iscalt(iphas))).eq.3) then
  rib = 0.d0
- if (abs(utau).le.epzero) utau = epzero
 else
  rib = 2.d0*gredu*distbf*(tpotv2-tpotv1)/(tpotv1+tpotv2)/utau/utau
 endif
@@ -300,7 +299,7 @@ endif
   if (abs(fh).le.epzero) fh = epzero
 
   cfnnu = 1.d0/sqrt(fm)
-  cfnns = sqrt(fm)/fh
+  cfnns = fh/sqrt(fm)
   if ((1.d0-rib).gt.epzero)then
     cfnnk = sqrt(1.d0-rib)  ! +correction with turbulent Prandtl
     cfnne = (1.d0-rib)/sqrt(fm)
diff --git a/src/atmo/atphyv.f90 b/src/atmo/atphyv.f90
index 71816f4..ebcc1a6 100644
--- a/src/atmo/atphyv.f90
+++ b/src/atmo/atphyv.f90
@@ -250,6 +250,13 @@ idebia = idbia0
 idebra = idbra0
 
 
+! This routine computes the density and the thermodynamic temperature.
+! The computations require the pressure profile which is here taken from
+! the meteo file. If no meteo file is used, the user should
+! give the laws for RHO and T in usphyv.f90
+
+if (imeteo.eq.0) return
+
 !===============================================================================
 
 ! --- Boucle sur les phases : debut
diff --git a/src/atmo/atprke.f90 b/src/atmo/atprke.f90
index b22d1e3..2c30199 100644
--- a/src/atmo/atprke.f90
+++ b/src/atmo/atprke.f90
@@ -187,10 +187,11 @@ integer         iel
 integer         itpp , icltpp
 integer         iccocg, inc
 integer         iivar, iphydp
-integer         nswrgp, epsrgp, imligp
-integer         iwarnp, climgp, extrap
+integer         nswrgp, imligp
+integer         iwarnp
 
 double precision gravke, prdtur
+double precision epsrgp, climgp, extrap
 
 
 !
@@ -225,7 +226,7 @@ if (ippmod(iatmos).eq.1) then
   climgp = climgr(itpp)
   extrap = extrag(itpp)
 
-  iivar = 0
+  iivar = itpp
 
   iphydp = 0
   call grdcel                                                     &
diff --git a/src/atmo/attycl.f90 b/src/atmo/attycl.f90
index 064cac0..d07734c 100644
--- a/src/atmo/attycl.f90
+++ b/src/atmo/attycl.f90
@@ -302,7 +302,9 @@ do ifac = 1, nfabor
         if (itypfb(ifac,iphas).eq.0) itypfb(ifac,iphas) = isolib
       else
         if (itypfb(ifac,iphas).eq.0) itypfb(ifac,iphas) = ientre
+      endif
 
+      if (itypfb(ifac,iphas).eq.ientre) then
 
         if (rcodcl(ifac,iu(iphas),1).gt.rinfin*0.5d0)             &
            rcodcl(ifac,iu(iphas),1) = xuent
diff --git a/src/base/Makefile.am b/src/base/Makefile.am
index 35d15e0..4eab2d2 100644
--- a/src/base/Makefile.am
+++ b/src/base/Makefile.am
@@ -2,7 +2,7 @@
 #   This file is part of the Code_Saturne Kernel, element of the
 #   Code_Saturne CFD tool.
 #
-#   Copyright (C) 2009 EDF S.A., France
+#   Copyright (C) 2009-2010 EDF S.A., France
 #
 #   The Code_Saturne Kernel is free software; you can redistribute it
 #   and/or modify it under the terms of the GNU General Public License
@@ -82,6 +82,7 @@ $(top_srcdir)/include/base/cs_join.h \
 $(top_srcdir)/include/base/cs_join_intersect.h \
 $(top_srcdir)/include/base/cs_join_merge.h \
 $(top_srcdir)/include/base/cs_join_mesh.h \
+$(top_srcdir)/include/base/cs_join_perio.h \
 $(top_srcdir)/include/base/cs_join_post.h \
 $(top_srcdir)/include/base/cs_join_set.h \
 $(top_srcdir)/include/base/cs_join_split.h \
@@ -242,6 +243,8 @@ cs_join_f2c.f90 \
 cs_join_intersect.c \
 cs_join_merge.c \
 cs_join_mesh.c \
+cs_join_perio.c \
+cs_join_perio_f2c.f90 \
 cs_join_post.c \
 cs_join_set.c \
 cs_join_split.c \
@@ -423,6 +426,7 @@ $(top_srcdir)/users/base/uskpdc.f90 \
 $(top_srcdir)/users/base/usmodg.f90 \
 $(top_srcdir)/users/base/usmpst.f90 \
 $(top_srcdir)/users/base/usnpst.f90 \
+$(top_srcdir)/users/base/usperi.f90 \
 $(top_srcdir)/users/base/usphyv.f90 \
 $(top_srcdir)/users/base/usproj.f90 \
 $(top_srcdir)/users/base/uspt1d.f90 \
@@ -459,6 +463,7 @@ $(top_srcdir)/users/base/uskpdc.f90 \
 $(top_srcdir)/users/base/usmodg.f90 \
 $(top_srcdir)/users/base/usmpst.f90 \
 $(top_srcdir)/users/base/usnpst.f90 \
+$(top_srcdir)/users/base/usperi.f90 \
 $(top_srcdir)/users/base/usphyv.f90 \
 $(top_srcdir)/users/base/usproj.f90 \
 $(top_srcdir)/users/base/uspt1d.f90 \
diff --git a/src/base/Makefile.in b/src/base/Makefile.in
index ebf5c6a..aa56109 100644
--- a/src/base/Makefile.in
+++ b/src/base/Makefile.in
@@ -19,7 +19,7 @@
 #   This file is part of the Code_Saturne Kernel, element of the
 #   Code_Saturne CFD tool.
 #
-#   Copyright (C) 2009 EDF S.A., France
+#   Copyright (C) 2009-2010 EDF S.A., France
 #
 #   The Code_Saturne Kernel is free software; you can redistribute it
 #   and/or modify it under the terms of the GNU General Public License
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -103,8 +108,9 @@ am_libcsbase_la_OBJECTS = alelap.lo alemaj.lo altycl.lo armtps.lo \
 	cs_gui_radiative_transfer.lo cs_gui_specific_physics.lo \
 	cs_gui_util.lo cs_halo.lo csinit.lo cs_io.lo cs_join.lo \
 	cs_join_f2c.lo cs_join_intersect.lo cs_join_merge.lo \
-	cs_join_mesh.lo cs_join_post.lo cs_join_set.lo \
-	cs_join_split.lo cs_join_update.lo cs_join_util.lo cs_mesh.lo \
+	cs_join_mesh.lo cs_join_perio.lo cs_join_perio_f2c.lo \
+	cs_join_post.lo cs_join_set.lo cs_join_split.lo \
+	cs_join_update.lo cs_join_util.lo cs_mesh.lo \
 	cs_mesh_coherency.lo cs_mesh_connect.lo cs_mesh_halo.lo \
 	cs_mesh_quality.lo cs_mesh_quantities.lo cs_mesh_solcom.lo \
 	cs_mesh_warping.lo cs_multigrid.lo cs_numbering.lo cs_opts.lo \
@@ -137,11 +143,14 @@ am_libcsbase_la_OBJECTS = alelap.lo alemaj.lo altycl.lo armtps.lo \
 	vorin0.lo vorini.lo vorlgv.lo vorpre.lo vortex.lo vorver.lo \
 	vorvit.lo zufall.lo usalcl.lo usalin.lo usaste.lo usclim.lo \
 	usdpst.lo ushist.lo usini1.lo usiniv.lo usjoin.lo uskpdc.lo \
-	usmodg.lo usmpst.lo usnpst.lo usphyv.lo usproj.lo uspt1d.lo \
-	ussatc.lo ussmag.lo usstru.lo ussyrc.lo usthht.lo ustmgr.lo \
-	ustske.lo ustskw.lo ustsma.lo ustsns.lo ustsri.lo ustssc.lo \
-	ustsv2.lo usvima.lo usvist.lo usvort.lo usvpst.lo
+	usmodg.lo usmpst.lo usnpst.lo usperi.lo usphyv.lo usproj.lo \
+	uspt1d.lo ussatc.lo ussmag.lo usstru.lo ussyrc.lo usthht.lo \
+	ustmgr.lo ustske.lo ustskw.lo ustsma.lo ustsns.lo ustsri.lo \
+	ustssc.lo ustsv2.lo usvima.lo usvist.lo usvort.lo usvpst.lo
 libcsbase_la_OBJECTS = $(am_libcsbase_la_OBJECTS)
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
 libcshot_la_LIBADD =
 am_libcshot_la_OBJECTS = libcshot_la-cs_benchmark.lo \
 	libcshot_la-cs_blas.lo libcshot_la-cs_matrix.lo \
@@ -150,7 +159,7 @@ am_libcshot_la_OBJECTS = libcshot_la-cs_benchmark.lo \
 	libcshot_la-prods3.lo libcshot_la-prodsc.lo \
 	libcshot_la-promav.lo
 libcshot_la_OBJECTS = $(am_libcshot_la_OBJECTS)
-libcshot_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+libcshot_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(libcshot_la_FCFLAGS) \
 	$(FCFLAGS) $(libcshot_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
@@ -159,20 +168,39 @@ am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_$(V))
+am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
+am__v_CC_0 = @echo "  CC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_$(V))
+am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_CCLD_0 = @echo "  CCLD  " $@;
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcsbase_la_SOURCES) $(libcshot_la_SOURCES)
 DIST_SOURCES = $(libcsbase_la_SOURCES) $(libcshot_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -205,6 +233,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -228,6 +257,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -279,6 +309,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -335,6 +366,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -372,7 +404,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -459,6 +490,7 @@ $(top_srcdir)/include/base/cs_join.h \
 $(top_srcdir)/include/base/cs_join_intersect.h \
 $(top_srcdir)/include/base/cs_join_merge.h \
 $(top_srcdir)/include/base/cs_join_mesh.h \
+$(top_srcdir)/include/base/cs_join_perio.h \
 $(top_srcdir)/include/base/cs_join_post.h \
 $(top_srcdir)/include/base/cs_join_set.h \
 $(top_srcdir)/include/base/cs_join_split.h \
@@ -567,15 +599,16 @@ libcsbase_la_SOURCES = alelap.f90 alemaj.f90 altycl.f90 armtps.f90 \
 	cs_gui_radiative_transfer.c cs_gui_specific_physics.c \
 	cs_gui_util.c cs_halo.c csinit.f90 cs_io.c cs_join.c \
 	cs_join_f2c.f90 cs_join_intersect.c cs_join_merge.c \
-	cs_join_mesh.c cs_join_post.c cs_join_set.c cs_join_split.c \
-	cs_join_update.c cs_join_util.c cs_mesh.c cs_mesh_coherency.c \
-	cs_mesh_connect.c cs_mesh_halo.c cs_mesh_quality.c \
-	cs_mesh_quantities.c cs_mesh_solcom.c cs_mesh_warping.c \
-	cs_multigrid.c cs_numbering.c cs_opts.c cs_parall.c cs_perio.c \
-	cs_post.c cs_post_f2c.f90 cs_preprocessor_data.c \
-	cs_proxy_comm.c cs_renumber.c cs_restart.c cs_sat_coupling.c \
-	cs_sat_f2c.f90 cs_search.c cs_selector.c cs_selector_f2c.f90 \
-	cs_sort.c cs_syr3_comm.c cs_syr3_coupling.c cs_syr3_messages.c \
+	cs_join_mesh.c cs_join_perio.c cs_join_perio_f2c.f90 \
+	cs_join_post.c cs_join_set.c cs_join_split.c cs_join_update.c \
+	cs_join_util.c cs_mesh.c cs_mesh_coherency.c cs_mesh_connect.c \
+	cs_mesh_halo.c cs_mesh_quality.c cs_mesh_quantities.c \
+	cs_mesh_solcom.c cs_mesh_warping.c cs_multigrid.c \
+	cs_numbering.c cs_opts.c cs_parall.c cs_perio.c cs_post.c \
+	cs_post_f2c.f90 cs_preprocessor_data.c cs_proxy_comm.c \
+	cs_renumber.c cs_restart.c cs_sat_coupling.c cs_sat_f2c.f90 \
+	cs_search.c cs_selector.c cs_selector_f2c.f90 cs_sort.c \
+	cs_syr3_comm.c cs_syr3_coupling.c cs_syr3_messages.c \
 	cs_syr4_coupling.c cs_syr_coupling.c cs_syr_f2c.f90 \
 	cs_tpar1d.c cs_ventil.c csprnt.f90 distpr.f90 distyp.f90 \
 	divmas.f90 divrij.f90 dttvar.f90 dvvpst.f90 ecrava.f90 \
@@ -616,6 +649,7 @@ libcsbase_la_SOURCES = alelap.f90 alemaj.f90 altycl.f90 armtps.f90 \
 	$(top_srcdir)/users/base/usmodg.f90 \
 	$(top_srcdir)/users/base/usmpst.f90 \
 	$(top_srcdir)/users/base/usnpst.f90 \
+	$(top_srcdir)/users/base/usperi.f90 \
 	$(top_srcdir)/users/base/usphyv.f90 \
 	$(top_srcdir)/users/base/usproj.f90 \
 	$(top_srcdir)/users/base/uspt1d.f90 \
@@ -651,6 +685,7 @@ $(top_srcdir)/users/base/uskpdc.f90 \
 $(top_srcdir)/users/base/usmodg.f90 \
 $(top_srcdir)/users/base/usmpst.f90 \
 $(top_srcdir)/users/base/usnpst.f90 \
+$(top_srcdir)/users/base/usperi.f90 \
 $(top_srcdir)/users/base/usphyv.f90 \
 $(top_srcdir)/users/base/usproj.f90 \
 $(top_srcdir)/users/base/uspt1d.f90 \
@@ -716,9 +751,9 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcsbase.la: $(libcsbase_la_OBJECTS) $(libcsbase_la_DEPENDENCIES) 
-	$(FCLINK)  $(libcsbase_la_OBJECTS) $(libcsbase_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(FCLINK)  $(libcsbase_la_OBJECTS) $(libcsbase_la_LIBADD) $(LIBS)
 libcshot.la: $(libcshot_la_OBJECTS) $(libcshot_la_DEPENDENCIES) 
-	$(libcshot_la_LINK)  $(libcshot_la_OBJECTS) $(libcshot_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcshot_la_LINK)  $(libcshot_la_OBJECTS) $(libcshot_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -750,6 +785,7 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_join_intersect.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_join_merge.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_join_mesh.Plo at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_join_perio.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_join_post.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_join_set.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_join_split.Plo at am__quote@
@@ -792,179 +828,232 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/tremai.Plo at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
 
 libcshot_la-cs_benchmark.lo: cs_benchmark.c
- at am__fastdepCC_TRUE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_benchmark.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_benchmark.Tpo -c -o libcshot_la-cs_benchmark.lo `test -f 'cs_benchmark.c' || echo '$(srcdir)/'`cs_benchmark.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/libcshot_la-cs_benchmark.Tpo $(DEPDIR)/libcshot_la-cs_benchmark.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_benchmark.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_benchmark.Tpo -c -o libcshot_la-cs_benchmark.lo `test -f 'cs_benchmark.c' || echo '$(srcdir)/'`cs_benchmark.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libcshot_la-cs_benchmark.Tpo $(DEPDIR)/libcshot_la-cs_benchmark.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='cs_benchmark.c' object='libcshot_la-cs_benchmark.lo' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_benchmark.lo `test -f 'cs_benchmark.c' || echo '$(srcdir)/'`cs_benchmark.c
+ at am__fastdepCC_FALSE@	$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_benchmark.lo `test -f 'cs_benchmark.c' || echo '$(srcdir)/'`cs_benchmark.c
 
 libcshot_la-cs_blas.lo: cs_blas.c
- at am__fastdepCC_TRUE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_blas.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_blas.Tpo -c -o libcshot_la-cs_blas.lo `test -f 'cs_blas.c' || echo '$(srcdir)/'`cs_blas.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/libcshot_la-cs_blas.Tpo $(DEPDIR)/libcshot_la-cs_blas.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_blas.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_blas.Tpo -c -o libcshot_la-cs_blas.lo `test -f 'cs_blas.c' || echo '$(srcdir)/'`cs_blas.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libcshot_la-cs_blas.Tpo $(DEPDIR)/libcshot_la-cs_blas.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='cs_blas.c' object='libcshot_la-cs_blas.lo' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_blas.lo `test -f 'cs_blas.c' || echo '$(srcdir)/'`cs_blas.c
+ at am__fastdepCC_FALSE@	$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_blas.lo `test -f 'cs_blas.c' || echo '$(srcdir)/'`cs_blas.c
 
 libcshot_la-cs_matrix.lo: cs_matrix.c
- at am__fastdepCC_TRUE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_matrix.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_matrix.Tpo -c -o libcshot_la-cs_matrix.lo `test -f 'cs_matrix.c' || echo '$(srcdir)/'`cs_matrix.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/libcshot_la-cs_matrix.Tpo $(DEPDIR)/libcshot_la-cs_matrix.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_matrix.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_matrix.Tpo -c -o libcshot_la-cs_matrix.lo `test -f 'cs_matrix.c' || echo '$(srcdir)/'`cs_matrix.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libcshot_la-cs_matrix.Tpo $(DEPDIR)/libcshot_la-cs_matrix.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='cs_matrix.c' object='libcshot_la-cs_matrix.lo' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_matrix.lo `test -f 'cs_matrix.c' || echo '$(srcdir)/'`cs_matrix.c
+ at am__fastdepCC_FALSE@	$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_matrix.lo `test -f 'cs_matrix.c' || echo '$(srcdir)/'`cs_matrix.c
 
 libcshot_la-cs_sles.lo: cs_sles.c
- at am__fastdepCC_TRUE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_sles.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_sles.Tpo -c -o libcshot_la-cs_sles.lo `test -f 'cs_sles.c' || echo '$(srcdir)/'`cs_sles.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/libcshot_la-cs_sles.Tpo $(DEPDIR)/libcshot_la-cs_sles.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -MT libcshot_la-cs_sles.lo -MD -MP -MF $(DEPDIR)/libcshot_la-cs_sles.Tpo -c -o libcshot_la-cs_sles.lo `test -f 'cs_sles.c' || echo '$(srcdir)/'`cs_sles.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libcshot_la-cs_sles.Tpo $(DEPDIR)/libcshot_la-cs_sles.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='cs_sles.c' object='libcshot_la-cs_sles.lo' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_sles.lo `test -f 'cs_sles.c' || echo '$(srcdir)/'`cs_sles.c
+ at am__fastdepCC_FALSE@	$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcshot_la_CFLAGS) $(CFLAGS) -c -o libcshot_la-cs_sles.lo `test -f 'cs_sles.c' || echo '$(srcdir)/'`cs_sles.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 usalcl.lo: $(top_srcdir)/users/base/usalcl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usalcl.lo `test -f '$(top_srcdir)/users/base/usalcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usalcl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usalcl.lo `test -f '$(top_srcdir)/users/base/usalcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usalcl.f90
 
 usalin.lo: $(top_srcdir)/users/base/usalin.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usalin.lo `test -f '$(top_srcdir)/users/base/usalin.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usalin.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usalin.lo `test -f '$(top_srcdir)/users/base/usalin.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usalin.f90
 
 usaste.lo: $(top_srcdir)/users/base/usaste.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usaste.lo `test -f '$(top_srcdir)/users/base/usaste.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usaste.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usaste.lo `test -f '$(top_srcdir)/users/base/usaste.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usaste.f90
 
 usclim.lo: $(top_srcdir)/users/base/usclim.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usclim.lo `test -f '$(top_srcdir)/users/base/usclim.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usclim.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usclim.lo `test -f '$(top_srcdir)/users/base/usclim.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usclim.f90
 
 usdpst.lo: $(top_srcdir)/users/base/usdpst.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usdpst.lo `test -f '$(top_srcdir)/users/base/usdpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usdpst.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usdpst.lo `test -f '$(top_srcdir)/users/base/usdpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usdpst.f90
 
 ushist.lo: $(top_srcdir)/users/base/ushist.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ushist.lo `test -f '$(top_srcdir)/users/base/ushist.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ushist.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ushist.lo `test -f '$(top_srcdir)/users/base/ushist.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ushist.f90
 
 usini1.lo: $(top_srcdir)/users/base/usini1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usini1.lo `test -f '$(top_srcdir)/users/base/usini1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usini1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usini1.lo `test -f '$(top_srcdir)/users/base/usini1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usini1.f90
 
 usiniv.lo: $(top_srcdir)/users/base/usiniv.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usiniv.lo `test -f '$(top_srcdir)/users/base/usiniv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usiniv.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usiniv.lo `test -f '$(top_srcdir)/users/base/usiniv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usiniv.f90
 
 usjoin.lo: $(top_srcdir)/users/base/usjoin.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usjoin.lo `test -f '$(top_srcdir)/users/base/usjoin.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usjoin.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usjoin.lo `test -f '$(top_srcdir)/users/base/usjoin.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usjoin.f90
 
 uskpdc.lo: $(top_srcdir)/users/base/uskpdc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uskpdc.lo `test -f '$(top_srcdir)/users/base/uskpdc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/uskpdc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uskpdc.lo `test -f '$(top_srcdir)/users/base/uskpdc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/uskpdc.f90
 
 usmodg.lo: $(top_srcdir)/users/base/usmodg.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usmodg.lo `test -f '$(top_srcdir)/users/base/usmodg.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usmodg.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usmodg.lo `test -f '$(top_srcdir)/users/base/usmodg.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usmodg.f90
 
 usmpst.lo: $(top_srcdir)/users/base/usmpst.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usmpst.lo `test -f '$(top_srcdir)/users/base/usmpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usmpst.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usmpst.lo `test -f '$(top_srcdir)/users/base/usmpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usmpst.f90
 
 usnpst.lo: $(top_srcdir)/users/base/usnpst.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usnpst.lo `test -f '$(top_srcdir)/users/base/usnpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usnpst.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usnpst.lo `test -f '$(top_srcdir)/users/base/usnpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usnpst.f90
+
+usperi.lo: $(top_srcdir)/users/base/usperi.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usperi.lo `test -f '$(top_srcdir)/users/base/usperi.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usperi.f90
 
 usphyv.lo: $(top_srcdir)/users/base/usphyv.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usphyv.lo `test -f '$(top_srcdir)/users/base/usphyv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usphyv.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usphyv.lo `test -f '$(top_srcdir)/users/base/usphyv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usphyv.f90
 
 usproj.lo: $(top_srcdir)/users/base/usproj.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usproj.lo `test -f '$(top_srcdir)/users/base/usproj.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usproj.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usproj.lo `test -f '$(top_srcdir)/users/base/usproj.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usproj.f90
 
 uspt1d.lo: $(top_srcdir)/users/base/uspt1d.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uspt1d.lo `test -f '$(top_srcdir)/users/base/uspt1d.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/uspt1d.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uspt1d.lo `test -f '$(top_srcdir)/users/base/uspt1d.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/uspt1d.f90
 
 ussatc.lo: $(top_srcdir)/users/base/ussatc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ussatc.lo `test -f '$(top_srcdir)/users/base/ussatc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ussatc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ussatc.lo `test -f '$(top_srcdir)/users/base/ussatc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ussatc.f90
 
 ussmag.lo: $(top_srcdir)/users/base/ussmag.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ussmag.lo `test -f '$(top_srcdir)/users/base/ussmag.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ussmag.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ussmag.lo `test -f '$(top_srcdir)/users/base/ussmag.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ussmag.f90
 
 usstru.lo: $(top_srcdir)/users/base/usstru.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usstru.lo `test -f '$(top_srcdir)/users/base/usstru.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usstru.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usstru.lo `test -f '$(top_srcdir)/users/base/usstru.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usstru.f90
 
 ussyrc.lo: $(top_srcdir)/users/base/ussyrc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ussyrc.lo `test -f '$(top_srcdir)/users/base/ussyrc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ussyrc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ussyrc.lo `test -f '$(top_srcdir)/users/base/ussyrc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ussyrc.f90
 
 usthht.lo: $(top_srcdir)/users/base/usthht.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usthht.lo `test -f '$(top_srcdir)/users/base/usthht.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usthht.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usthht.lo `test -f '$(top_srcdir)/users/base/usthht.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usthht.f90
 
 ustmgr.lo: $(top_srcdir)/users/base/ustmgr.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustmgr.lo `test -f '$(top_srcdir)/users/base/ustmgr.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustmgr.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustmgr.lo `test -f '$(top_srcdir)/users/base/ustmgr.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustmgr.f90
 
 ustske.lo: $(top_srcdir)/users/base/ustske.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustske.lo `test -f '$(top_srcdir)/users/base/ustske.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustske.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustske.lo `test -f '$(top_srcdir)/users/base/ustske.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustske.f90
 
 ustskw.lo: $(top_srcdir)/users/base/ustskw.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustskw.lo `test -f '$(top_srcdir)/users/base/ustskw.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustskw.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustskw.lo `test -f '$(top_srcdir)/users/base/ustskw.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustskw.f90
 
 ustsma.lo: $(top_srcdir)/users/base/ustsma.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsma.lo `test -f '$(top_srcdir)/users/base/ustsma.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsma.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsma.lo `test -f '$(top_srcdir)/users/base/ustsma.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsma.f90
 
 ustsns.lo: $(top_srcdir)/users/base/ustsns.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsns.lo `test -f '$(top_srcdir)/users/base/ustsns.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsns.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsns.lo `test -f '$(top_srcdir)/users/base/ustsns.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsns.f90
 
 ustsri.lo: $(top_srcdir)/users/base/ustsri.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsri.lo `test -f '$(top_srcdir)/users/base/ustsri.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsri.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsri.lo `test -f '$(top_srcdir)/users/base/ustsri.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsri.f90
 
 ustssc.lo: $(top_srcdir)/users/base/ustssc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustssc.lo `test -f '$(top_srcdir)/users/base/ustssc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustssc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustssc.lo `test -f '$(top_srcdir)/users/base/ustssc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustssc.f90
 
 ustsv2.lo: $(top_srcdir)/users/base/ustsv2.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsv2.lo `test -f '$(top_srcdir)/users/base/ustsv2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsv2.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o ustsv2.lo `test -f '$(top_srcdir)/users/base/ustsv2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/ustsv2.f90
 
 usvima.lo: $(top_srcdir)/users/base/usvima.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvima.lo `test -f '$(top_srcdir)/users/base/usvima.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvima.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvima.lo `test -f '$(top_srcdir)/users/base/usvima.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvima.f90
 
 usvist.lo: $(top_srcdir)/users/base/usvist.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvist.lo `test -f '$(top_srcdir)/users/base/usvist.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvist.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvist.lo `test -f '$(top_srcdir)/users/base/usvist.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvist.f90
 
 usvort.lo: $(top_srcdir)/users/base/usvort.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvort.lo `test -f '$(top_srcdir)/users/base/usvort.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvort.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvort.lo `test -f '$(top_srcdir)/users/base/usvort.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvort.f90
 
 usvpst.lo: $(top_srcdir)/users/base/usvpst.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvpst.lo `test -f '$(top_srcdir)/users/base/usvpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvpst.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usvpst.lo `test -f '$(top_srcdir)/users/base/usvpst.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/base/usvpst.f90
 
 libcshot_la-gradmc.lo: gradmc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-gradmc.lo `test -f 'gradmc.f90' || echo '$(srcdir)/'`gradmc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-gradmc.lo `test -f 'gradmc.f90' || echo '$(srcdir)/'`gradmc.f90
 
 libcshot_la-gradrc.lo: gradrc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-gradrc.lo `test -f 'gradrc.f90' || echo '$(srcdir)/'`gradrc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-gradrc.lo `test -f 'gradrc.f90' || echo '$(srcdir)/'`gradrc.f90
 
 libcshot_la-prods2.lo: prods2.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-prods2.lo `test -f 'prods2.f90' || echo '$(srcdir)/'`prods2.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-prods2.lo `test -f 'prods2.f90' || echo '$(srcdir)/'`prods2.f90
 
 libcshot_la-prods3.lo: prods3.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-prods3.lo `test -f 'prods3.f90' || echo '$(srcdir)/'`prods3.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-prods3.lo `test -f 'prods3.f90' || echo '$(srcdir)/'`prods3.f90
 
 libcshot_la-prodsc.lo: prodsc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-prodsc.lo `test -f 'prodsc.f90' || echo '$(srcdir)/'`prodsc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-prodsc.lo `test -f 'prodsc.f90' || echo '$(srcdir)/'`prodsc.f90
 
 libcshot_la-promav.lo: promav.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-promav.lo `test -f 'promav.f90' || echo '$(srcdir)/'`promav.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(libcshot_la_FCFLAGS) $(FCFLAGS) -c -o libcshot_la-promav.lo `test -f 'promav.f90' || echo '$(srcdir)/'`promav.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/base/clptrg.f90 b/src/base/clptrg.f90
index 571924c..b86c165 100644
--- a/src/base/clptrg.f90
+++ b/src/base/clptrg.f90
@@ -181,6 +181,7 @@ include "ppppar.h"
 include "ppthch.h"
 include "ppincl.h"
 include "radiat.h"
+include "cplsat.h"
 
 !===============================================================================
 
@@ -251,7 +252,7 @@ double precision und0, deuxd0
 double precision eloglo(3,3), alpha(6,6)
 double precision rcodcx, rcodcy, rcodcz, rcodsn
 double precision visclc, visctc, romc  , distbf, srfbnf, cpscv
-double precision distbf0,rugd,rugt,ydep,act,uiptfn,uiptfx
+double precision distbf0,rugd,rugt,ydep,act
 
 !===============================================================================
 
@@ -418,7 +419,7 @@ do ifac = 1, nfabor
 !     Si on n'est pas en ALE, on force la vitesse de deplacement
 !       de la face a etre tangentielle (et on met a jour rcodcl
 !       pour une utilisation eventuelle)
-    if (iale.eq.0) then
+    if (iale.eq.0.and.imobil.eq.0) then
       rcodsn = rcodcx*rnx+rcodcy*rny+rcodcz*rnz
       rcodcx = rcodcx -rcodsn*rnx
       rcodcy = rcodcy -rcodsn*rny
@@ -561,6 +562,8 @@ do ifac = 1, nfabor
 ! 2. VITESSES DE FROTTEMENT
 !==========================================================================
 
+   if (abs(utau).le.epzero) utau = epzero
+
 ! RUGD : rugosite de paroi pour les variables dynamiques
 !        seule la valeur stockee pour IU est utilisee
    rugd=rcodcl(ifac,iuiph,3)
@@ -690,8 +693,6 @@ do ifac = 1, nfabor
 
       if(uiptn.lt.-epzero) iuiptn = iuiptn + 1
 
-      uiptfx = max(uiptnf,uiptfx)
-      uiptfn = min(uiptnf,uiptfn)
       uetmax = max(uet,uetmax)
       uetmin = min(uet,uetmin)
       ukmax = max(uk,ukmax)
diff --git a/src/base/clptur.f90 b/src/base/clptur.f90
index 12e40f9..1ad027e 100644
--- a/src/base/clptur.f90
+++ b/src/base/clptur.f90
@@ -416,7 +416,7 @@ do ifac = 1, nfabor
 !     Si on n'est pas en ALE, on force la vitesse de deplacement
 !       de la face a etre tangentielle (et on met a jour rcodcl
 !       pour une utilisation eventuelle)
-    if (iale.eq.0.or.imobil.eq.0) then
+    if (iale.eq.0.and.imobil.eq.0) then
       rcodsn = rcodcx*rnx+rcodcy*rny+rcodcz*rnz
       rcodcx = rcodcx -rcodsn*rnx
       rcodcy = rcodcy -rcodsn*rny
diff --git a/src/base/cs_ast_coupling.c b/src/base/cs_ast_coupling.c
index ea6e202..9393513 100644
--- a/src/base/cs_ast_coupling.c
+++ b/src/base/cs_ast_coupling.c
@@ -228,6 +228,7 @@ void CS_PROCF(astgeo, ASTGEO)
 
   }
 
+  ifs_mesh = fvm_nodal_destroy(ifs_mesh);
 
   /* TODO: Adapter l'algo parallel en sequentiel */
 
@@ -415,6 +416,8 @@ void CS_PROCF(astcin, ASTCIN)
   BFT_MALLOC(parent_num, n_nodes, cs_int_t);
   fvm_nodal_get_parent_num(mesh_ifs, 0, parent_num);
 
+  mesh_ifs = fvm_nodal_destroy(mesh_ifs);
+
   /* On remplit dans DEPALE les valeurs de deplacement aux noeuds
      couples a deplacement impose */
 
diff --git a/src/base/cs_base.c b/src/base/cs_base.c
index 69a9fdf..6e163a4 100644
--- a/src/base/cs_base.c
+++ b/src/base/cs_base.c
@@ -315,7 +315,7 @@ _cs_base_err_vprintf(const char  *format,
         sprintf(nom_fic_err, "error_n%04d", cs_glob_rank_id + 1);
     }
 
-    stderr = freopen(nom_fic_err, "w", stderr);
+    freopen(nom_fic_err, "w", stderr);
 
     initialized = true;
   }
@@ -424,12 +424,12 @@ _error_mem_summary(void)
   /* Available memory usage information */
 
   _cs_base_err_printf
-    (_("Theoretical current allocated memory:   %lu kB\n"),
-     (unsigned long)(bft_mem_size_current()));
+    (_("Theoretical current allocated memory:   %llu kB\n"),
+     (unsigned long long)(bft_mem_size_current()));
 
   _cs_base_err_printf
-    (_("Theoretical maximum allocated memory:   %lu kB\n"),
-     (unsigned long)(bft_mem_size_max()));
+    (_("Theoretical maximum allocated memory:   %llu kB\n"),
+     (unsigned long long)(bft_mem_size_max()));
 
   if (bft_mem_usage_initialized() == 1) {
 
@@ -438,16 +438,16 @@ _error_mem_summary(void)
     mem_usage = bft_mem_usage_max_pr_size();
     if (mem_usage > 0)
       _cs_base_err_printf
-        (_("Maximum program memory measure:         %lu kB\n"),
-         (unsigned long)mem_usage);
+        (_("Maximum program memory measure:         %llu kB\n"),
+         (unsigned long long)mem_usage);
 
     /* Current measured memory */
 
     mem_usage = bft_mem_usage_pr_size();
     if (mem_usage > 0)
       _cs_base_err_printf
-        (_("Current program memory measure:         %lu kB\n"),
-         (unsigned long)mem_usage);
+        (_("Current program memory measure:         %llu kB\n"),
+         (unsigned long long)mem_usage);
   }
 }
 
@@ -1115,9 +1115,9 @@ cs_base_mem_fin(void)
       val_in[ind_bil].val = valreal[ind_bil];
       val_in[ind_bil].rank = cs_glob_rank_id;
     }
-    MPI_Reduce(&val_in, &val_min, 2, MPI_DOUBLE_INT, MPI_MINLOC,
+    MPI_Reduce(val_in, val_min, 2, MPI_DOUBLE_INT, MPI_MINLOC,
                0, cs_glob_mpi_comm);
-    MPI_Reduce(&val_in, &val_max, 2, MPI_DOUBLE_INT, MPI_MAXLOC,
+    MPI_Reduce(val_in, val_max, 2, MPI_DOUBLE_INT, MPI_MAXLOC,
                0, cs_glob_mpi_comm);
     if (cs_glob_rank_id == 0) {
       for (ind_bil = 0; ind_bil < 2; ind_bil++) {
@@ -1206,12 +1206,12 @@ cs_base_mem_fin(void)
 
     bft_printf(_("\n"
                  "  Fortran work arrays memory use:\n"
-                 "   %-12lu integers needed (maximum reached in %s)\n"
-                 "   %-12lu reals    needed (maximum reached in %s)\n\n"
+                 "   %-12llu integers needed (maximum reached in %s)\n"
+                 "   %-12llu reals    needed (maximum reached in %s)\n\n"
                  "   Local maximum work memory requested %12.3f %cb\n"
                  "                                  used %12.3f %cb\n"),
-               (unsigned long)_cs_glob_mem_ia_peak, _cs_glob_srt_ia_peak,
-               (unsigned long)_cs_glob_mem_ra_peak, _cs_glob_srt_ra_peak,
+               (unsigned long long)_cs_glob_mem_ia_peak, _cs_glob_srt_ia_peak,
+               (unsigned long long)_cs_glob_mem_ra_peak, _cs_glob_srt_ra_peak,
                wk_size[0], unite[wk_unit[0]],
                wk_size[1], unite[wk_unit[1]]);
 
@@ -1396,7 +1396,7 @@ cs_base_system_info(void)
   bft_printf("  %s%s\n", _("Processor:         "), bft_sys_info_cpu());
 
   if (ram > 0)
-    bft_printf("  %s%lu\n", _("Memory:            "), (unsigned long)ram);
+    bft_printf("  %s%llu\n", _("Memory:            "), (unsigned long long)ram);
 
   if (str_user != NULL) {
     bft_printf("  %s%s\n", _("User:              "), str_user);
diff --git a/src/base/cs_benchmark.c b/src/base/cs_benchmark.c
index 65fdc88..461c62c 100644
--- a/src/base/cs_benchmark.c
+++ b/src/base/cs_benchmark.c
@@ -937,7 +937,7 @@ _matrix_vector_test(int                    n_runs,
                     cs_real_t             *restrict x,
                     cs_real_t             *restrict y)
 {
-  cs_int_t ii, jj;
+  cs_int_t ii;
   double wt, cpu;
   int    run_id;
   long   n_ops, n_ops_glob;
@@ -984,8 +984,8 @@ _matrix_vector_test(int                    n_runs,
                               y);
     test_sum += y[n_cells-1];
 #if 0
-    for (jj = 0; jj < n_cells; jj++)
-      bft_printf("y[%d] = %12.4f\n", jj, y[jj]);
+    for (ii = 0; ii < n_cells; ii++)
+      bft_printf("y[%d] = %12.4f\n", ii, y[ii]);
 #endif
   }
 
diff --git a/src/base/cs_boundary_conditions.c b/src/base/cs_boundary_conditions.c
index d832976..7a1dfe0 100644
--- a/src/base/cs_boundary_conditions.c
+++ b/src/base/cs_boundary_conditions.c
@@ -307,9 +307,9 @@ cs_boundary_conditions_error(int             n_phases,
         bft_printf(_("\nPhase %d:\n  "), phase_id + 1);
 
       bft_printf(_("\nFirst face with boundary condition definition error\n"
-                   "  (out of %lu)\n"
+                   "  (out of %llu)\n"
                    "  has boundary condition type %d, center (%g, %g, %g)\n\n"),
-                 (unsigned long)n_errors , abs(err_face_type),
+                 (unsigned long long)n_errors , abs(err_face_type),
                  err_face_coo[0], err_face_coo[1], err_face_coo[2]);
     }
 
diff --git a/src/base/cs_ext_neighborhood.c b/src/base/cs_ext_neighborhood.c
index b3aa0ee..0e89c49 100644
--- a/src/base/cs_ext_neighborhood.c
+++ b/src/base/cs_ext_neighborhood.c
@@ -58,6 +58,8 @@
 #include <bft_mem.h>
 #include <bft_printf.h>
 
+#include <fvm_parall.h>
+
 /*----------------------------------------------------------------------------
  *  Local headers
  *----------------------------------------------------------------------------*/
@@ -950,7 +952,7 @@ void
 CS_PROCF (redvse, REDVSE) (const cs_real_t  *anomax)
 {
   cs_int_t  i, face_id, cell_id, cell_i, cell_j;
-  size_t  init_cell_cells_connect_size;
+  fvm_gnum_t  init_cell_cells_connect_size;
 
   cs_real_t  v_ij[3];
   cs_real_t  face_normal[3];
@@ -958,7 +960,7 @@ CS_PROCF (redvse, REDVSE) (const cs_real_t  *anomax)
   cs_real_t  dprod;
   double     ratio;
 
-  cs_int_t  n_deleted_cells = 0;
+  fvm_gnum_t  n_deleted_cells = 0;
   cs_int_t  previous_idx = 0, new_idx = -1;
 
   cs_mesh_t  *mesh = cs_glob_mesh;
@@ -1140,13 +1142,12 @@ CS_PROCF (redvse, REDVSE) (const cs_real_t  *anomax)
 
       if (cs_glob_n_ranks > 1) {
 
-        unsigned long count_g[2];
-        unsigned long count_l[2];
+        fvm_gnum_t count_g[2], count_l[2];
 
         count_l[0] = init_cell_cells_connect_size;
         count_l[1] = n_deleted_cells;
 
-        MPI_Allreduce(count_l, count_g, 2, MPI_UNSIGNED_LONG,
+        MPI_Allreduce(count_l, count_g, 2, FVM_MPI_GNUM,
                       MPI_SUM, cs_glob_mpi_comm);
 
         init_cell_cells_connect_size = count_g[0];
@@ -1163,12 +1164,12 @@ CS_PROCF (redvse, REDVSE) (const cs_real_t  *anomax)
            " Extended neighborhood reduced by non-orthogonality\n"
            " --------------------------------------------------\n"
            "\n"
-           " Size of complete cell-cell connectivity: %12lu\n"
-           " Size of filtered cell-cell conectivity:  %12lu\n"
-           " %lu connections removed, for a ratio of %4.2g %% used\n"),
-         (unsigned long)init_cell_cells_connect_size,
-         (unsigned long)(init_cell_cells_connect_size - n_deleted_cells),
-         (unsigned long)n_deleted_cells,
+           " Size of complete cell-cell connectivity: %12llu\n"
+           " Size of filtered cell-cell conectivity:  %12llu\n"
+           " %llu connections removed, for a ratio of %4.2g %% used\n"),
+         (unsigned long long)init_cell_cells_connect_size,
+         (unsigned long long)(init_cell_cells_connect_size - n_deleted_cells),
+         (unsigned long long)n_deleted_cells,
          ratio);
 
 #if 0 /* For debugging purpose */
diff --git a/src/base/cs_gui.c b/src/base/cs_gui.c
index 2d8b46b..0a11ee8 100644
--- a/src/base/cs_gui.c
+++ b/src/base/cs_gui.c
@@ -2615,6 +2615,9 @@ void CS_PROCF (csturb, CSTURB) (int    *const iturb,
   else if (cs_gui_strcmp(model, "LES_dynamique")){
      iturb[iphas] = 41;
    }
+  else if (cs_gui_strcmp(model, "LES_WALE")){
+     iturb[iphas] = 42;
+   }
   else if (cs_gui_strcmp(model, "v2f-phi")){
      iturb[iphas] = 50;
      cs_gui_advanced_options_turbulence("scale_model", &ideuch[iphas]);
@@ -4685,9 +4688,9 @@ void CS_PROCF(uikpdc, UIKPDC)(const int*   iappel,
                 for (j = 0; j < cells; j++)
                 {
                     iel = cells_list[j];
-                    vit = rtpa[vars->rtp[1]*(*ncelet) + iel] * rtpa[vars->rtp[1]*(*ncelet) + iel] \
-                        + rtpa[vars->rtp[2]*(*ncelet) + iel] * rtpa[vars->rtp[2]*(*ncelet) + iel] \
-                        + rtpa[vars->rtp[3]*(*ncelet) + iel] * rtpa[vars->rtp[3]*(*ncelet) + iel] ;
+                    vit = rtpa[vars->rtp[1]*(*ncelet) + iel-1] * rtpa[vars->rtp[1]*(*ncelet) + iel-1] \
+                        + rtpa[vars->rtp[2]*(*ncelet) + iel-1] * rtpa[vars->rtp[2]*(*ncelet) + iel-1] \
+                        + rtpa[vars->rtp[3]*(*ncelet) + iel-1] * rtpa[vars->rtp[3]*(*ncelet) + iel-1] ;
                     vit = sqrt(vit);
                     ckupdc[0 * ncepdp[*iphas-1] + ielpdc] = 0.5 * c11 * vit;
                     ckupdc[1 * ncepdp[*iphas-1] + ielpdc] = 0.5 * c22 * vit;
@@ -4922,7 +4925,7 @@ void CS_PROCF(uiphyv, UIPHYV)(const cs_int_t  *const ncel,
             propce[ipccp * (*ncelet) + iel] = mei_tree_lookup(ev_cp, "cp");
         }
 
-        mei_tree_destroy(ev_rho);
+        mei_tree_destroy(ev_cp);
     }
 
     /* law for thermal conductivity */
diff --git a/src/base/cs_gui_boundary_conditions.c b/src/base/cs_gui_boundary_conditions.c
index 7a83ec9..374bb2c 100644
--- a/src/base/cs_gui_boundary_conditions.c
+++ b/src/base/cs_gui_boundary_conditions.c
@@ -1187,7 +1187,7 @@ void CS_PROCF (uiclim, UICLIM)(const    int *const ntcabs,
     int zones = 0;
     int izone, ith_zone, zone_nbr;
     int ifac, ifbr;
-    int i, k, ivar, icharb, iclass, iwall;
+    int i, ivar, icharb, iclass, iwall;
     double norm = 0.;
     double X[3];
     int *faces_list = NULL;
@@ -1540,7 +1540,7 @@ void CS_PROCF (uiclim, UICLIM)(const    int *const ntcabs,
                         if (   cs_gui_strcmp(vars->model_value, "dry")
                             || cs_gui_strcmp(vars->model_value, "humid"))
                         {
-                            rcodcl[3 * (*nfabor * (vars->nvar)) + vars->rtp[2] * (*nfabor) + ifbr]
+                            rcodcl[2 * (*nfabor * (vars->nvar)) + vars->rtp[2] * (*nfabor) + ifbr]
                             = boundaries->rough[izone];
                         }
                      }
diff --git a/src/base/cs_io.c b/src/base/cs_io.c
index e46a7be..94750d9 100644
--- a/src/base/cs_io.c
+++ b/src/base/cs_io.c
@@ -605,7 +605,7 @@ _file_open(cs_io_t     *cs_io,
 
   /* Create interface file descriptor */
 
-#if defined(HAVE_MPI)
+#if defined(FVM_HAVE_MPI)
   cs_io->f = fvm_file_open(name, f_mode, hints, comm);
 #else
   cs_io->f = fvm_file_open(name, f_mode, hints);
@@ -804,7 +804,7 @@ _file_legacy_restart_open(cs_io_t    *inp,
 
   /* Create interface file descriptor */
 
-#if defined(HAVE_MPI)
+#if defined(FVM_HAVE_MPI)
   inp->f = fvm_file_open(name, FVM_FILE_MODE_READ, FVM_FILE_NO_MPI_IO, comm);
 #else
   inp->f = fvm_file_open(name, FVM_FILE_MODE_READ, 0);
@@ -1075,7 +1075,7 @@ _file_reopen_read(cs_io_t   *inp,
 
     inp->index->f[i] = fvm_file_free(inp->index->f[i]);
 
-#if defined(HAVE_MPI)
+#if defined(FVM_HAVE_MPI)
     inp->index->f[i] = fvm_file_open(tmpname, FVM_FILE_MODE_READ, hints, comm);
 #else
     inp->index->f[i] = fvm_file_open(tmpname, FVM_FILE_MODE_READ, hints);
@@ -1157,8 +1157,8 @@ _echo_header(const char      *sec_name,
   /* Instructions */
 
   bft_printf(_("    section name:           \"%s\"\n"
-               "    number of elements:     %lu\n"),
-             sec_name, (unsigned long)n_elts);
+               "    number of elements:     %llu\n"),
+             sec_name, (unsigned long long)n_elts);
 
   if (n_elts > 0) {
 
@@ -1230,11 +1230,11 @@ _echo_data(size_t           echo,
            fvm_datatype_t   elt_type,
            const void      *elts)
 {
-  fvm_gnum_t  i;
   fvm_gnum_t  num_shift = 1;
   size_t  _n_elts = n_elts;
   fvm_file_off_t  echo_start = 0;
   fvm_file_off_t  echo_end = 0;
+  fvm_file_off_t  i;
   const char *_loc_glob[] = {N_(" (local)"), ""};
   const char *loc_glob = _loc_glob[1];
 
@@ -1279,8 +1279,8 @@ _echo_data(size_t           echo,
         const fvm_lnum_t *_elts = elts;
 
         for (i = echo_start ; i < echo_end ; i++)
-          bft_printf("    %10lu : %12d\n",
-                     (unsigned long)(i + num_shift), *(_elts + i));
+          bft_printf("    %10llu : %12d\n",
+                     (unsigned long long)(i + num_shift), *(_elts + i));
       }
       break;
 
@@ -1290,9 +1290,9 @@ _echo_data(size_t           echo,
         const fvm_gnum_t *_elts = elts;
 
         for (i = echo_start ; i < echo_end ; i++)
-          bft_printf("    %10lu : %12lu\n",
-                     (unsigned long)(i + num_shift),
-                     (unsigned long)*(_elts + i));
+          bft_printf("    %10llu : %12llu\n",
+                     (unsigned long long)(i + num_shift),
+                     (unsigned long long)*(_elts + i));
       }
       break;
 
@@ -1302,8 +1302,8 @@ _echo_data(size_t           echo,
         const cs_real_t *_elts = elts;
 
         for (i = echo_start ; i < echo_end ; i++)
-          bft_printf("    %10lu : %12.5e\n",
-                     (unsigned long)(i + num_shift), *(_elts + i));
+          bft_printf("    %10llu : %12.5e\n",
+                     (unsigned long long)(i + num_shift), *(_elts + i));
       }
       break;
 
@@ -1313,11 +1313,11 @@ _echo_data(size_t           echo,
 
         for (i = echo_start ; i < echo_end ; i++) {
           if (*(_elts + i) != '\0')
-            bft_printf("    %10lu : '%c'\n",
-                       (unsigned long)(i + num_shift), *(_elts + i));
+            bft_printf("    %10llu : '%c'\n",
+                       (unsigned long long)(i + num_shift), *(_elts + i));
           else
-            bft_printf("    %10lu : '\\0'\n",
-                       (unsigned long)(i + num_shift));
+            bft_printf("    %10llu : '\\0'\n",
+                       (unsigned long long)(i + num_shift));
         }
       }
       break;
@@ -1583,7 +1583,7 @@ _cs_io_read_body(const cs_io_sec_header_t  *header,
 
   assert(header->n_vals == inp->n_vals);
 
-  assert(global_num_end <= header->n_vals + 1);
+  assert(global_num_end <= (fvm_gnum_t)header->n_vals + 1);
 
   /* Choose global or block mode */
 
@@ -1809,8 +1809,8 @@ _write_padding(size_t    align,
 
       if (pad_size != n_written)
         bft_error(__FILE__, __LINE__, 0,
-                  _("Error writing %lu bytes to file \"%s\"."),
-                  (unsigned long)pad_size, fvm_file_get_name(outp->f));
+                  _("Error writing %llu bytes to file \"%s\"."),
+                  (unsigned long long)pad_size, fvm_file_get_name(outp->f));
     }
   }
 }
@@ -1937,7 +1937,7 @@ _write_header(const char      *sec_name,
       break;
     case FVM_INT64:
       outp->type_name[0] = 'i';
-      outp->type_name[1] = '4';
+      outp->type_name[1] = '8';
       break;
     case FVM_UINT32:
       outp->type_name[0] = 'u';
@@ -1945,7 +1945,7 @@ _write_header(const char      *sec_name,
       break;
     case FVM_UINT64:
       outp->type_name[0] = 'u';
-      outp->type_name[1] = '4';
+      outp->type_name[1] = '8';
       break;
     case FVM_CHAR:
       outp->type_name[0] = 'c';
@@ -1986,8 +1986,8 @@ _write_header(const char      *sec_name,
 
   if (write_size != (fvm_file_off_t)n_written)
     bft_error(__FILE__, __LINE__, 0,
-              _("Error writing %lu bytes to file \"%s\"."),
-              (unsigned long)write_size, fvm_file_get_name(outp->f));
+              _("Error writing %llu bytes to file \"%s\"."),
+              (unsigned long long)write_size, fvm_file_get_name(outp->f));
 
   if (outp->echo >= CS_IO_ECHO_HEADERS)
     _echo_header(sec_name, n_vals, elt_type);
@@ -2009,9 +2009,10 @@ _dump_index(const cs_io_sec_index_t  *idx)
 
   assert(idx != NULL);
 
-  bft_printf(_(" %lu indexed records:\n"
+  bft_printf(_(" %llu indexed records:\n"
                "   (name, n_vals, location_id, index_id, n_loc_vals, type, "
-               "embed, file_id, offset)\n\n"), (unsigned long)(idx->size));
+               "embed, file_id, offset)\n\n"),
+             (unsigned long long)(idx->size));
 
   for (ii = 0; ii < idx->size; ii++) {
 
@@ -2022,8 +2023,8 @@ _dump_index(const cs_io_sec_index_t  *idx)
     if (h_vals[5] > 0)
       embed = 'y';
 
-    bft_printf(_(" %40s %10lu %2u %2u %2u %6s %c %2u %ld\n"),
-               name, (unsigned long)(h_vals[0]),
+    bft_printf(_(" %40s %10llu %2u %2u %2u %6s %c %2u %ld\n"),
+               name, (unsigned long long)(h_vals[0]),
                (unsigned)(h_vals[1]), (unsigned)(h_vals[2]),
                (unsigned)(h_vals[3]), fvm_datatype_name[h_vals[6]],
                embed, (unsigned)(h_vals[7]),
@@ -2528,13 +2529,17 @@ cs_io_read_header(cs_io_t             *inp,
 
     header->elt_type = _type_read_to_elt_type(header->type_read);
   }
+  else {
+    header->type_read = FVM_DATATYPE_NULL;
+    header->elt_type = FVM_DATATYPE_NULL;
+  }
 
   /* Possible echo */
 
   if (inp->echo >= CS_IO_ECHO_HEADERS)
     _echo_header(header->sec_name,
                  header->n_vals,
-                 header->elt_type);
+                 header->type_read);
 
   return 0;
 }
@@ -2934,9 +2939,9 @@ cs_io_read_index_block(cs_io_sec_header_t  *header,
   if (   header->n_vals != 0 && header->n_vals != global_num_end
       && cs_io->echo > CS_IO_ECHO_HEADERS)
     bft_printf(_("    first element for next rank:\n"
-                 "    %10lu : %12d\n"),
-               (unsigned long)(global_num_end),
-               (unsigned long)retval[global_num_end - global_num_start]);
+                 "    %10llu : %12llu\n"),
+               (unsigned long long)(global_num_end),
+               (unsigned long long)retval[global_num_end - global_num_start]);
 
 #endif /* defined(HAVE_MPI) */
 
@@ -2998,8 +3003,8 @@ cs_io_write_global(const char      *sec_name,
 
     if (n_vals != n_written)
       bft_error(__FILE__, __LINE__, 0,
-                _("Error writing %lu bytes to file \"%s\"."),
-                (unsigned long)n_vals, fvm_file_get_name(outp->f));
+                _("Error writing %llu bytes to file \"%s\"."),
+                (unsigned long long)n_vals, fvm_file_get_name(outp->f));
 
   }
 
@@ -3085,8 +3090,8 @@ cs_io_write_block_buffer(const char      *sec_name,
 
   if (n_vals != n_written)
     bft_error(__FILE__, __LINE__, 0,
-              _("Error writing %lu bytes to file \"%s\"."),
-              (unsigned long)n_vals, fvm_file_get_name(outp->f));
+              _("Error writing %llu bytes to file \"%s\"."),
+              (unsigned long long)n_vals, fvm_file_get_name(outp->f));
 
   if (n_vals != 0 && outp->echo > CS_IO_ECHO_HEADERS)
     _echo_data(outp->echo, n_g_vals,
diff --git a/src/base/cs_join.c b/src/base/cs_join.c
index 13317ec..0515913 100644
--- a/src/base/cs_join.c
+++ b/src/base/cs_join.c
@@ -68,6 +68,7 @@
 #include "cs_join_merge.h"
 #include "cs_join_mesh.h"
 #include "cs_join_post.h"
+#include "cs_join_perio.h"
 #include "cs_join_set.h"
 #include "cs_join_split.h"
 #include "cs_join_update.h"
@@ -83,722 +84,130 @@
 
 BEGIN_C_DECLS
 
-/*=============================================================================
- * Local Structure Definitions
- *===========================================================================*/
-
-/*============================================================================
- * Static global variables
- *===========================================================================*/
-
-int  cs_glob_n_joinings = 0;
-
-cs_join_t  **cs_glob_join_array = NULL;
-
 /*============================================================================
  * Private function definitions
  *===========================================================================*/
 
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
 /*----------------------------------------------------------------------------
- * Compute the cross product of two vectors.
- *
- * parameters:
- *  v1     <--  first vector
- *  v2     <--  second vector
- *  result -->  cross product v1xv2
- *
- * returns:
- *  the resulting cross product (v1 x v2)
- *---------------------------------------------------------------------------*/
-
-inline static void
-_cross_product(double   v1[],
-               double   v2[],
-               double   result[])
-{
-  result[0] = v1[1] * v2[2] - v2[1] * v1[2];
-  result[1] = v2[0] * v1[2] - v1[0] * v2[2];
-  result[2] = v1[0] * v2[1] - v2[0] * v1[1];
-}
-
-/*----------------------------------------------------------------------------
- * Compute the dot product of two vectors.
- *
- * parameters:
- *  v1     <--  first vector
- *  v2     <--  second vector
- *
- * returns:
- *  the resulting dot product (v1.v2)
- *---------------------------------------------------------------------------*/
-
-inline static double
-_dot_product(double   v1[],
-             double   v2[])
-{
-  int  i;
-  double  result = 0.0;
-
-  for (i = 0; i < 3; i++)
-    result += v1[i] * v2[i];
-
-  return result;
-}
-
-/*----------------------------------------------------------------------------
- * Get the norm of a vector.
- *
- * parameters:
- *  v      <->  vector to work with.
- *---------------------------------------------------------------------------*/
-
-inline static double
-_norm(double   v[])
-{
-  return  sqrt(_dot_product(v, v));
-}
-
-/*----------------------------------------------------------------------------
- * Compute the distance between two vertices.
- *
- * parameters:
- *   id         <-- local id of the vertex to deal with
- *   quantities <-- array keeping edge vector and its length
- *
- * returns:
- *   sinus in radian between edges sharing vertex id
- *---------------------------------------------------------------------------*/
-
-inline static double
-_compute_sinus(int           id,
-               const double  quantities[])
-{
-  int  i;
-
-  double  sinus;
-  double  norm_a, norm_b, a[3], b[3], c[3];
-
-  for (i = 0; i < 3; i++) {
-    a[i] = -quantities[4*id+i];
-    b[i] = quantities[4*(id+1)+i];
-  }
-
-  norm_a = quantities[4*id+3];
-  norm_b = quantities[4*(id+1)+3];
-
-  _cross_product(a, b, c);
-
-  sinus = _norm(c) / (norm_a * norm_b);
-
-  return sinus;
-}
-
-/*----------------------------------------------------------------------------
- * Compute the distance between two vertices.
- *
- * parameters:
- *   a <-- coordinates of the first vertex.
- *   b <-- coordinates of the second vertex.
- *
- * returns:
- *   distance between a and b.
- *---------------------------------------------------------------------------*/
-
-inline static double
-_compute_length(const double  a[3],
-                const double  b[3])
-{
-  double  length;
-
-  length = sqrt(  (b[0] - a[0])*(b[0] - a[0])
-                + (b[1] - a[1])*(b[1] - a[1])
-                + (b[2] - a[2])*(b[2] - a[2]));
-
-  return length;
-}
-
-/*----------------------------------------------------------------------------
- * Compute tolerance (mode 2)
- * tolerance = min[ edge length * sinus(v1v2) * fraction]
+ * Dump a cs_mesh_t structure into a file for debugging purpose
  *
  * parameters:
- *   vertex_coords    <--  coordinates of vertices.
- *   vertex_tolerance <->  local tolerance affected to each vertex and
- *                         to be updated
- *   n_faces          <--  number of selected faces
- *   face_lst         <--  list of faces selected to compute the tolerance
- *   f2v_idx          <--  "face -> vertex" connect. index
- *   f2v_lst          <--  "face -> vertex" connect. list
- *   fraction         <--  parameter used to compute the tolerance
+ *   join_num    <-- join number
+ *   basename    <-- string
+ *   mesh        <-- pointer to cs_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 static void
-_compute_tolerance2(const cs_real_t   vtx_coords[],
-                    double            vtx_tolerance[],
-                    const cs_int_t    n_faces,
-                    const cs_int_t    face_lst[],
-                    const cs_int_t    f2v_idx[],
-                    const cs_int_t    f2v_lst[],
-                    double            fraction)
+_dump_mesh(const  int          join_num,
+           const  char         basename[],
+           const  cs_mesh_t   *mesh)
 {
-  int  i, j, k, coord;
-  double  tolerance, sinus;
-  double  a[3], b[3];
-
-  int   n_max_face_vertices = 0;
-  int  *face_connect = NULL;
-  double  *edge_quantities = NULL;
-
-  for (i = 0; i < n_faces; i++) {
-    int  fid = face_lst[i] - 1;
-    n_max_face_vertices = CS_MAX(n_max_face_vertices,
-                                 f2v_idx[fid+1] - f2v_idx[fid]);
-  }
-
-  BFT_MALLOC(face_connect, n_max_face_vertices + 1, int);
-  BFT_MALLOC(edge_quantities, 4 * (n_max_face_vertices + 1), double);
-
-  for (i = 0; i < n_faces; i++) {
-
-    int  face_id = face_lst[i] - 1;
-    int  start = f2v_idx[face_id] - 1;
-    int  end = f2v_idx[face_id + 1] - 1;
-    int  n_face_vertices = end - start;
-
-    /* Keep face connect */
-
-    for (k = 0, j = start; j < end; j++, k++)
-      face_connect[k] = f2v_lst[j] - 1;
-    face_connect[k] = f2v_lst[start] - 1;
-
-    /* Keep edge lengths and edge vectors:
-        - edge_quantities[4*k+0..2] = edge vector
-        - edge_quantities[4*k+3] = edge length */
-
-    for (k = 0; k < n_face_vertices; k++) {
-
-      for (coord = 0; coord < 3; coord++) {
-        a[coord] = vtx_coords[3*face_connect[k] + coord];
-        b[coord] = vtx_coords[3*face_connect[k+1] + coord];
-        edge_quantities[4*(k+1)+coord] = b[coord] - a[coord];
-      }
-      edge_quantities[4*(k+1)+3] = _compute_length(a, b);
-
-    }
-
-    for (coord = 0; coord < 4; coord++)
-      edge_quantities[coord] = edge_quantities[4*k+coord];
-
-    /* Loop on the vertices of the face to update tolerance on
-       each vertex */
-
-    for (k = 0; k < n_face_vertices; k++) {
-
-      int  vid = face_connect[k];
-
-      tolerance = fraction * CS_MIN(edge_quantities[4*k+3],
-                                    edge_quantities[4*(k+1)+3]);
-      sinus = _compute_sinus(k, edge_quantities);
-
-      vtx_tolerance[vid] = FVM_MIN(vtx_tolerance[vid], sinus*tolerance);
-
-    }
-
-  } /* End of loop on faces */
-
-  BFT_FREE(face_connect);
-  BFT_FREE(edge_quantities);
-
+  int  base_len, len;
+  FILE  *dbg_file = NULL;
+  char  *filename = NULL;
+
+  base_len = strlen(basename);
+  len = strlen("JoinDBG__.dat")+1+4+2+base_len;
+  BFT_MALLOC(filename, len, char);
+  sprintf(filename, "Join%02dDBG_%s_%04d.dat",
+          join_num, basename, fvm_parall_get_rank());
+  dbg_file = fopen(filename, "w");
+
+  cs_mesh_dump_file(dbg_file, mesh);
+
+  fflush(dbg_file);
+  BFT_FREE(filename);
+  fclose(dbg_file);
 }
 
 /*----------------------------------------------------------------------------
- * Compute tolerance (mode 1)
- * tolerance = shortest edge length * fraction
+ * Dump a cs_join_gset_t structure into a file for debugging purpose
  *
  * parameters:
- *   vertex_coords    <--  coordinates of vertices.
- *   vertex_tolerance <->  local tolerance affected to each vertex and
- *                         to be updated
- *   n_faces          <--  number of selected faces
- *   face_lst         <--  list of faces selected to compute the tolerance
- *   face_vtx_idx     <--  "face -> vertex" connect. index
- *   face_vtx_lst     <--  "face -> vertex" connect. list
- *   fraction         <--  parameter used to compute the tolerance
+ *   join_num    <-- join number
+ *   basename    <-- string
+ *   set         <-- pointer to cs_join_gset_t structure
  *---------------------------------------------------------------------------*/
 
 static void
-_compute_tolerance1(const cs_real_t   vtx_coords[],
-                    double            vtx_tolerance[],
-                    const cs_int_t    n_faces,
-                    const cs_int_t    face_lst[],
-                    const cs_int_t    face_vtx_idx[],
-                    const cs_int_t    face_vtx_lst[],
-                    double            fraction)
+_dump_gset(const  int               join_num,
+           const  char              basename[],
+           const  cs_join_gset_t   *set)
 {
-  cs_int_t  i, j, k, start, end, face_id, vtx_id1, vtx_id2;
-  double  length, tolerance;
-  double  a[3], b[3];
-
-  for (i = 0; i < n_faces; i++) {
-
-    face_id = face_lst[i] - 1;
-    start = face_vtx_idx[face_id] - 1;
-    end = face_vtx_idx[face_id + 1] - 1;
-
-    /* Loop on the vertices of the face */
-
-    for (j = start; j < end - 1; j++) {
-
-      vtx_id1 = face_vtx_lst[j] - 1;
-      vtx_id2 = face_vtx_lst[j+1] - 1;
-
-      for (k = 0; k < 3; k++) {
-        a[k] = vtx_coords[3*vtx_id1 + k];
-        b[k] = vtx_coords[3*vtx_id2 + k];
-      }
-
-      length = _compute_length(a, b);
-      tolerance = length * fraction;
-      vtx_tolerance[vtx_id1] = FVM_MIN(vtx_tolerance[vtx_id1], tolerance);
-      vtx_tolerance[vtx_id2] = FVM_MIN(vtx_tolerance[vtx_id2], tolerance);
-
-    }
-
-    /* Case end - start */
-
-    vtx_id1 = face_vtx_lst[end-1] - 1;
-    vtx_id2 = face_vtx_lst[start] - 1;
-
-    for (k = 0; k < 3; k++) {
-      a[k] = vtx_coords[3*vtx_id1 + k];
-      b[k] = vtx_coords[3*vtx_id2 + k];
-    }
-
-    length = _compute_length(a, b);
-    tolerance = length * fraction;
-    vtx_tolerance[vtx_id1] = FVM_MIN(vtx_tolerance[vtx_id1], tolerance);
-    vtx_tolerance[vtx_id2] = FVM_MIN(vtx_tolerance[vtx_id2], tolerance);
-
-  } /* End of loop on faces */
-
+  int  base_len, len;
+  FILE  *dbg_file = NULL;
+  char  *filename = NULL;
+
+  base_len = strlen(basename);
+  len = strlen("JoinDBG__.dat")+1+4+2+base_len;
+  BFT_MALLOC(filename, len, char);
+  sprintf(filename, "Join%02dDBG_%s_%04d.dat",
+          join_num, basename, fvm_parall_get_rank());
+  dbg_file = fopen(filename, "w");
+
+  cs_join_gset_dump(dbg_file, set);
+
+  fflush(dbg_file);
+  BFT_FREE(filename);
+  fclose(dbg_file);
 }
+#endif
 
 /*----------------------------------------------------------------------------
- * Define for each vertex a tolerance which is the radius of the
- * sphere in which the vertex can be fused with another vertex.
- * This tolerance is computed from the given list of faces (interior or border)
- *
- * parameters:
- *   param            <--  set of user-defined parameters for the joining
- *   vertex_coords    <--  coordinates of vertices.
- *   vertex_tolerance <->  local tolerance affected to each vertex and
- *                         to be updated
- *   n_faces          <--  number of selected faces
- *   face_lst         <--  list of faces selected to compute the tolerance
- *   face_vtx_idx     <--  "face -> vertex" connect. index
- *   face_vtx_lst     <--  "face -> vertex" connect. list
- *---------------------------------------------------------------------------*/
-
-static void
-_get_local_tolerance(cs_join_param_t  param,
-                     const cs_real_t  vtx_coords[],
-                     double           vtx_tolerance[],
-                     const cs_int_t   n_faces,
-                     const cs_int_t   face_lst[],
-                     const cs_int_t   face_vtx_idx[],
-                     const cs_int_t   face_vtx_lst[])
-{
-
-  if (param.tcm % 10 == 1) {
-
-    /* tol = min(edge length * fraction) */
-
-    _compute_tolerance1(vtx_coords,
-                        vtx_tolerance,
-                        n_faces,
-                        face_lst,
-                        face_vtx_idx,
-                        face_vtx_lst,
-                        param.fraction);
-
-  }
-  else if (param.tcm % 10 == 2) {
-
-    /* tol = min(edge length * sin(v1v2) * fraction) */
-
-    _compute_tolerance2(vtx_coords,
-                        vtx_tolerance,
-                        n_faces,
-                        face_lst,
-                        face_vtx_idx,
-                        face_vtx_lst,
-                        param.fraction);
-
-  }
-  else
-    bft_error(__FILE__, __LINE__, 0,
-              _("  Tolerance computation mode (%d) is not defined\n"));
-
-}
-
-#if defined(HAVE_MPI)
-
-/*----------------------------------------------------------------------------
- * Exchange local vertex tolerances to get a global vertex tolerance.
+ * Build a structure keeping data about entities selection and modify mesh
+ * in case of periodicity.
  *
  * parameters:
- *   n_vertices        <-- number of local selected vertices
- *   select_vtx_io_num <-- fvm_io_num_t structure for the selected vertices
- *   vertex_data       <-> data associated to each selected vertex
+ *   this_join  <-- pointer to a cs_join_t structure
+ *   mesh       <-> pointer to cs_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 static void
-_get_global_tolerance(cs_int_t             n_vertices,
-                      const fvm_io_num_t  *select_vtx_io_num,
-                      cs_join_vertex_t     vtx_data[])
-{
-  cs_int_t  i, rank, vtx_id, block_size, shift;
-  fvm_gnum_t  first_vtx_gnum;
-
-  double  *g_vtx_tolerance = NULL, *send_list = NULL, *recv_list = NULL;
-  cs_int_t  *send_count = NULL, *recv_count = NULL;
-  cs_int_t  *send_shift = NULL, *recv_shift = NULL;
-  fvm_gnum_t  *send_glist = NULL, *recv_glist = NULL;
-  fvm_gnum_t  n_g_vertices = fvm_io_num_get_global_count(select_vtx_io_num);
-  const fvm_gnum_t  *io_gnum = fvm_io_num_get_global_num(select_vtx_io_num);
-
-  MPI_Comm  mpi_comm = cs_glob_mpi_comm;
-  const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
-  const int  n_ranks = cs_glob_n_ranks;
-
-  /* Define a fvm_io_num_t structure on vertices */
-
-  block_size = n_g_vertices / n_ranks;
-  if (n_g_vertices % n_ranks > 0)
-    block_size += 1;
-
-  /* Count the number of vertices to send to each rank */
-  /* ------------------------------------------------- */
-
-  BFT_MALLOC(send_count, n_ranks, int);
-  BFT_MALLOC(recv_count, n_ranks, int);
-  BFT_MALLOC(send_shift, n_ranks + 1, int);
-  BFT_MALLOC(recv_shift, n_ranks + 1, int);
-
-  send_shift[0] = 0;
-  recv_shift[0] = 0;
-
-  for (rank = 0; rank < n_ranks; rank++)
-    send_count[rank] = 0;
-
-  for (i = 0; i < n_vertices; i++) {
-    rank = (io_gnum[i] - 1)/block_size;
-    send_count[rank] += 1;
-  }
-
-  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, mpi_comm);
-
-  for (rank = 0; rank < n_ranks; rank++) {
-    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
-    recv_shift[rank + 1] = recv_shift[rank] + recv_count[rank];
-  }
-
-  assert(send_shift[n_ranks] == n_vertices);
-
-  /* Send the global numbering for each vertex */
-  /* ----------------------------------------- */
-
-  BFT_MALLOC(send_glist, n_vertices, fvm_gnum_t);
-  BFT_MALLOC(recv_glist, recv_shift[n_ranks], fvm_gnum_t);
-
-  for (rank = 0; rank < n_ranks; rank++)
-    send_count[rank] = 0;
-
-  for (i = 0; i < n_vertices; i++) {
-    rank = (io_gnum[i] - 1)/block_size;
-    shift = send_shift[rank] + send_count[rank];
-    send_count[rank] += 1;
-    send_glist[shift] = io_gnum[i];
-  }
-
-  MPI_Alltoallv(send_glist, send_count, send_shift, FVM_MPI_GNUM,
-                recv_glist, recv_count, recv_shift, FVM_MPI_GNUM, mpi_comm);
-
-  /* Send the vertex tolerance for each vertex */
-  /* ----------------------------------------- */
-
-  BFT_MALLOC(send_list, n_vertices, double);
-  BFT_MALLOC(recv_list, recv_shift[n_ranks], double);
-
-  for (rank = 0; rank < n_ranks; rank++)
-    send_count[rank] = 0;
-
-  for (i = 0; i < n_vertices; i++) {
-    rank = (io_gnum[i] - 1)/block_size;
-    shift = send_shift[rank] + send_count[rank];
-    send_count[rank] += 1;
-    send_list[shift] = vtx_data[i].tolerance;
-  }
-
-  MPI_Alltoallv(send_list, send_count, send_shift, MPI_DOUBLE,
-                recv_list, recv_count, recv_shift, MPI_DOUBLE, mpi_comm);
-
-  /* Define the global tolerance array */
-
-  BFT_MALLOC(g_vtx_tolerance, block_size, double);
-
-  for (i = 0; i < block_size; i++)
-    g_vtx_tolerance[i] = DBL_MAX;
-
-  first_vtx_gnum = block_size * local_rank + 1;
-
-  for (i = 0; i < recv_shift[n_ranks]; i++) {
-    vtx_id = recv_glist[i] - first_vtx_gnum;
-    g_vtx_tolerance[vtx_id] = FVM_MIN(g_vtx_tolerance[vtx_id], recv_list[i]);
-  }
-
-  /* Replace local vertex tolerance by the new computed global tolerance */
-
-  for (i = 0; i < recv_shift[n_ranks]; i++) {
-    vtx_id = recv_glist[i] - first_vtx_gnum;
-    recv_list[i] = g_vtx_tolerance[vtx_id];
-  }
-
-  MPI_Alltoallv(recv_list, recv_count, recv_shift, MPI_DOUBLE,
-                send_list, send_count, send_shift, MPI_DOUBLE, mpi_comm);
-
-  for (rank = 0; rank < n_ranks; rank++)
-    send_count[rank] = 0;
-
-  for (i = 0; i < n_vertices; i++) {
-    rank = (io_gnum[i] - 1)/block_size;
-    shift = send_shift[rank] + send_count[rank];
-    send_count[rank] += 1;
-    vtx_data[i].tolerance = send_list[shift];
-  }
-
-  /* Free memory */
-
-  BFT_FREE(recv_glist);
-  BFT_FREE(send_glist);
-  BFT_FREE(send_list);
-  BFT_FREE(recv_list);
-  BFT_FREE(recv_count);
-  BFT_FREE(send_count);
-  BFT_FREE(recv_shift);
-  BFT_FREE(send_shift);
-  BFT_FREE(g_vtx_tolerance);
-}
-
-#endif /* HAVE_MPI */
-
-/*----------------------------------------------------------------------------
- * Define a cs_join_mesh_t structure from a selection of faces and its
- * related vertices.
- *
- * parameters:
- *   name       <-- mesh name of the resulting cs_join_mesh_t structure
- *   param      <-- set of user-defined parameters for the joining
- *   selection  <-> selected entities
- *   b_f2v_idx  <-- border "face -> vertex" connectivity index
- *   b_f2v_lst  <-- border "face -> vertex" connectivity
- *   i_f2v_idx  <-- interior "face -> vertex" connectivity index
- *   i_f2v_lst  <-- interior "face -> vertex" connectivity
- *   n_vertices <-- number of vertices in the parent mesh
- *   vtx_coord  <-- coordinates of vertices in parent mesh
- *   vtx_gnum   <-- global numbering of vertices
- *---------------------------------------------------------------------------*/
-
-static cs_join_mesh_t *
-_extract_mesh(const char              *name,
-              const cs_join_param_t    param,
-              cs_join_select_t        *selection,
-              const cs_int_t           b_f2v_idx[],
-              const cs_int_t           b_f2v_lst[],
-              const cs_int_t           i_f2v_idx[],
-              const cs_int_t           i_f2v_lst[],
-              const cs_int_t           n_vertices,
-              const cs_real_t          vtx_coord[],
-              const fvm_gnum_t         vtx_gnum[])
+_select_entities(cs_join_t   *this_join,
+                 cs_mesh_t   *mesh)
 {
-  int  i;
-  double  clock_start, clock_end, cpu_start, cpu_end;
-
-  double  *vtx_tolerance = NULL;
-  cs_join_vertex_t  *vtx_data = NULL;
-  cs_join_mesh_t  *join_mesh = NULL;
-
-  const int  n_ranks = cs_glob_n_ranks;
-
-  clock_start = bft_timer_wtime();
-  cpu_start = bft_timer_cpu_time();
-
-  /*
-     Define a tolerance around each vertex in the selection list.
-     Tolerance is the radius of the sphere in which the vertex can be merged
-     with another vertex. Radius is the min(fraction * edge_length) on all
-     edges connected to a vertex.
-     Store all data about a vertex in a cs_join_vertex_t structure.
-  */
-
-  if (param.fraction >= 1.0 || param.fraction < 0.0)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Incompatible value for the \"fraction\" parameter.\n"
-                "Value must be lower than 1.0 or greater than 0.0\n"
-                "The current value is : %f\n"), param.fraction);
-
-  if (selection->n_vertices > 0) {
-
-    BFT_MALLOC(vtx_tolerance, n_vertices, double);
-
-    /* Compute the tolerance for each vertex of the mesh */
-
-    if (param.fraction > 0.0) {
-
-      for (i = 0; i < n_vertices; i++)
-        vtx_tolerance[i] = DBL_MAX;
-
-      /* Define local tolerance */
-
-      _get_local_tolerance(param,
-                           vtx_coord,
-                           vtx_tolerance,
-                           selection->n_faces,
-                           selection->faces,
-                           b_f2v_idx,
-                           b_f2v_lst);
-
-      if (param.tcm / 10 == 0) {
-
-        /* Update local tolerance with adjacent border faces */
-
-        _get_local_tolerance(param,
-                             vtx_coord,
-                             vtx_tolerance,
-                             selection->n_b_adj_faces,
-                             selection->b_adj_faces,
-                             b_f2v_idx,
-                             b_f2v_lst);
-
-        /* Update local tolerance with adjacent interior faces */
-
-        _get_local_tolerance(param,
-                             vtx_coord,
-                             vtx_tolerance,
-                             selection->n_i_adj_faces,
-                             selection->i_adj_faces,
-                             i_f2v_idx,
-                             i_f2v_lst);
-
-      } /* Include adjacent faces in the computation of the vertex tolerance */
-
-    } /* End if tolerance > 0.0 */
-
-    else
-      for (i = 0; i < n_vertices; i++)
-        vtx_tolerance[i] = 0.0;
-
-
-    /* Initialize vtx_data array */
-
-    BFT_MALLOC(vtx_data, selection->n_vertices, cs_join_vertex_t);
-
-    for (i = 0; i < selection->n_vertices; i++) {
-
-      cs_int_t  vtx_id = selection->vertices[i]-1;
-
-      if (n_ranks > 1)
-        vtx_data[i].gnum = vtx_gnum[vtx_id];
-      else
-        vtx_data[i].gnum = vtx_id + 1;
-
-      vtx_data[i].coord[0] = vtx_coord[3*vtx_id];
-      vtx_data[i].coord[1] = vtx_coord[3*vtx_id+1];
-      vtx_data[i].coord[2] = vtx_coord[3*vtx_id+2];
-
-      vtx_data[i].tolerance = vtx_tolerance[vtx_id];
-
-    }
-
-    BFT_FREE(vtx_tolerance);
-
-  } /* End if selection->n_vertices > 0 */
-
-#if 1 && defined(DEBUG) && !defined(NDEBUG)   /* Sanity check */
-  for (i = 0; i < selection->n_vertices; i++)
-    if (vtx_data[i].tolerance > (DBL_MAX - 1.))
-      bft_error(__FILE__, __LINE__, 0,
-                _("Incompatible value for the \"vertex tolerance\" parameter\n"
-                  "Value must be lower than DBL_MAX and current value is : %f"
-                  " (global numbering : %u)\n"),
-                vtx_data[i].tolerance, vtx_data[i].gnum);
-#endif
-
-  /* Parallel treatment : synchro over the ranks */
-
-#if defined(HAVE_MPI)
-
-  if (n_ranks > 1) {
-
-    /* Global number of selected vertices and associated
-       fvm_io_num_t structure */
-
-    fvm_io_num_t  *select_vtx_io_num = fvm_io_num_create(selection->vertices,
-                                                         vtx_gnum,
-                                                         selection->n_vertices,
-                                                         0);
-
-    selection->n_g_vertices = fvm_io_num_get_global_count(select_vtx_io_num);
+  cs_real_t  *b_face_cog = NULL, *b_face_normal = NULL;
+  cs_join_param_t   param = this_join->param;
 
-    _get_global_tolerance(selection->n_vertices,
-                          select_vtx_io_num,
-                          vtx_data);
+  const char   *selection_criteria = this_join->criteria;
 
-    if (param.verbosity > 1)
-      bft_printf(_("  Global number of selected vertices: %11lu\n\n"),
-                 (unsigned long)(selection->n_g_vertices));
+  cs_mesh_init_group_classes(mesh);
 
-    fvm_io_num_destroy(select_vtx_io_num);
+  cs_mesh_quantities_b_faces(mesh, &b_face_cog, &b_face_normal);
 
-  }
+  cs_glob_mesh->select_b_faces = fvm_selector_create(mesh->dim,
+                                                     mesh->n_b_faces,
+                                                     mesh->class_defs,
+                                                     mesh->b_face_family,
+                                                     1,
+                                                     b_face_cog,
+                                                     b_face_normal);
 
-#endif /* defined(HAVE_MPI) */
+  /* Get selected faces for this joining and define the related
+     cs_join_face_select_t structure.
+     - Compute the global number of selected faces
+     - Get the adjacent faces, ... */
 
-  /* Define the join mesh structure from the selected faces and the
-     related vtx_data on selected vertices */
+  this_join->selection = cs_join_select_create(selection_criteria,
+                                               param.verbosity);
 
-  join_mesh = cs_join_mesh_create_from_extract(name,
-                                               selection->n_faces,
-                                               selection->n_g_faces,
-                                               selection->faces,
-                                               selection->compact_face_gnum,
-                                               b_f2v_idx,
-                                               b_f2v_lst,
-                                               selection->n_vertices,
-                                               selection->n_g_vertices,
-                                               selection->vertices,
-                                               vtx_data);
+  /* Free arrays and structures needed for selection */
 
-  if (param.verbosity > 0)
-    cs_join_mesh_minmax_tol(param, join_mesh);
-
-  /* Free memory */
+  BFT_FREE(b_face_cog);
+  BFT_FREE(b_face_normal);
 
-  BFT_FREE(vtx_data);
+  mesh->class_defs = fvm_group_class_set_destroy(mesh->class_defs);
 
-  clock_end = bft_timer_wtime();
-  cpu_end = bft_timer_cpu_time();
-
-  if (param.verbosity > 2)
-    bft_printf(_("\n    Definition of local joining mesh:\n"
-                 "        wall clock time:            %10.3g\n"
-                 "        CPU time:                   %10.3g\n"),
-               clock_end - clock_start, cpu_end - cpu_start);
+  if (mesh->select_b_faces != NULL)
+    mesh->select_b_faces = fvm_selector_destroy(mesh->select_b_faces);
+  if (mesh->class_defs != NULL)
+    mesh->class_defs = fvm_group_class_set_destroy(mesh->class_defs);
 
-  if (param.verbosity > 2)
-    cs_join_post_dump_mesh("LocalMesh", join_mesh, param);
+  /* Return selection struct. */
 
-  return  join_mesh;
+  bft_printf(_("\n  Element selection successfully done.\n"));
+  bft_printf_flush();
 }
 
 /*----------------------------------------------------------------------------
@@ -939,35 +348,35 @@ _get_work_struct(cs_join_param_t         param,
  * Build several structures useful to join faces.
  *
  * parameters:
- *   join_param         <-- set of parameters for the joining operation
- *   join_selection     <-> list of implied entities in the joining operation
+ *   this_join          <-- pointer to a cs_join_t structure
  *   mesh               <-- pointer of pointer to cs_mesh_t structure
- *   p_loc_join_mesh    --> local cs_join_mesh_t structure based on local face
+ *   p_loc_jmesh        --> local cs_join_mesh_t structure based on local face
  *                          selection
- *   p_work_join_mesh   --> distributed and balanced cs_join_mesh_t structure
+ *   p_work_jmesh       --> distributed and balanced cs_join_mesh_t structure
  *                          based on the global face selection
- *   p_work_join_edges  --> edges definition related to work_join_mesh
- *   p_work_face_normal --> unitary normal for the faces of work_join_mesh
+ *   p_work_join_edges  --> edges definition related to work_jmesh
+ *   p_work_face_normal --> unitary normal for the faces of work_jmesh
  *   p_edge_edge_vis    --> list of all potential intersections between edges
  *---------------------------------------------------------------------------*/
 
 static void
-_build_join_structures(cs_join_param_t           join_param,
-                       cs_join_select_t         *join_selection,
-                       const cs_mesh_t          *mesh,
-                       cs_join_mesh_t          **p_loc_join_mesh,
-                       cs_join_mesh_t          **p_work_join_mesh,
-                       cs_join_edges_t         **p_work_join_edges,
-                       cs_real_t                *p_work_face_normal[],
-                       cs_join_gset_t          **p_edge_edge_vis)
+_build_join_structures(cs_join_t            *this_join,
+                       const cs_mesh_t      *mesh,
+                       cs_join_mesh_t     **p_loc_jmesh,
+                       cs_join_mesh_t     **p_work_jmesh,
+                       cs_join_edges_t    **p_work_join_edges,
+                       cs_real_t           *p_work_face_normal[],
+                       cs_join_gset_t     **p_edge_edge_vis)
 {
   double  clock_start, clock_end, cpu_start, cpu_end;
 
   char  *mesh_name = NULL;
   cs_real_t  *work_face_normal = NULL;
   cs_join_gset_t  *edge_edge_vis = NULL;
-  cs_join_mesh_t  *loc_mesh = NULL, *work_mesh = NULL;
+  cs_join_mesh_t  *loc_jmesh = NULL, *work_jmesh = NULL;
   cs_join_edges_t  *work_edges = NULL;
+  cs_join_param_t  param = this_join->param;
+  cs_join_select_t  *selection = this_join->selection;
 
   clock_start = bft_timer_wtime();
   cpu_start = bft_timer_cpu_time();
@@ -983,16 +392,36 @@ _build_join_structures(cs_join_param_t           join_param,
     sprintf(mesh_name,"%s", "LocalMesh");
   }
 
-  loc_mesh = _extract_mesh(mesh_name,
-                           join_param,
-                           join_selection,
-                           mesh->b_face_vtx_idx,
-                           mesh->b_face_vtx_lst,
-                           mesh->i_face_vtx_idx,
-                           mesh->i_face_vtx_lst,
-                           mesh->n_vertices,
-                           mesh->vtx_coord,
-                           mesh->global_vtx_num);
+  loc_jmesh = cs_join_mesh_create_from_select(mesh_name,
+                                              param,
+                                              selection,
+                                              mesh->b_face_vtx_idx,
+                                              mesh->b_face_vtx_lst,
+                                              mesh->i_face_vtx_idx,
+                                              mesh->i_face_vtx_lst,
+                                              mesh->n_vertices,
+                                              mesh->vtx_coord,
+                                              mesh->global_vtx_num);
+
+  if (param.perio_num > 0)
+    cs_join_perio_apply(this_join, loc_jmesh, mesh);
+
+  if (param.verbosity > 0)
+    cs_join_mesh_minmax_tol(param, loc_jmesh);
+
+  clock_end = bft_timer_wtime();
+  cpu_end = bft_timer_cpu_time();
+
+  if (param.verbosity > 2) {
+
+    bft_printf(_("\n    Definition of local joining mesh:\n"
+                 "        wall clock time:            %10.3g\n"
+                 "        CPU time:                   %10.3g\n"),
+               clock_end - clock_start, cpu_end - cpu_start);
+
+    cs_join_post_dump_mesh("LocalMesh", loc_jmesh, param);
+
+  }
 
   /* Partial free memory */
 
@@ -1015,10 +444,10 @@ _build_join_structures(cs_join_param_t           join_param,
     between these edges through an edge-edge visibility.
   */
 
-  _get_work_struct(join_param,
-                   join_selection->compact_rank_index,
-                   loc_mesh,
-                   &work_mesh,
+  _get_work_struct(param,
+                   selection->compact_rank_index,
+                   loc_jmesh,
+                   &work_jmesh,
                    &work_edges,
                    &work_face_normal,
                    &edge_edge_vis);
@@ -1026,7 +455,7 @@ _build_join_structures(cs_join_param_t           join_param,
   clock_end = bft_timer_wtime();
   cpu_end = bft_timer_cpu_time();
 
-  if (join_param.verbosity > 1)
+  if (param.verbosity > 1)
     bft_printf(_("\n  Definition of structures for the joining algorithm:\n"
                  "      wall clock time:            %10.3g\n"
                  "      CPU time:                   %10.3g\n"),
@@ -1035,15 +464,14 @@ _build_join_structures(cs_join_param_t           join_param,
 
   /* Return pointers */
 
-  *p_loc_join_mesh = loc_mesh;
-  *p_work_join_mesh = work_mesh;
+  *p_loc_jmesh = loc_jmesh;
+  *p_work_jmesh = work_jmesh;
   *p_work_join_edges = work_edges;
   *p_edge_edge_vis = edge_edge_vis;
   *p_work_face_normal = work_face_normal;
 
 }
 
-
 /*----------------------------------------------------------------------------
  * From real intersection between edges, define new vertices and/or
  * update old vertices.
@@ -1054,13 +482,12 @@ _build_join_structures(cs_join_param_t           join_param,
  * possible equivalences between vertices.
  *
  * parameters:
- *   param                <--  set of user-defined parameter for the joining
- *   work_join_mesh       <->  pointer to a cs_join_mesh_t structure
+ *   this_join            <--  pointer to a cs_join_t structure
+ *   work_jmesh           <->  pointer to a cs_join_mesh_t structure
  *   work_join_edges      <--  pointer to a cs_join_edges_t structure
  *   p_edge_edge_vis      <->  pointer to a cs_join_glist_t structure
  *                             (freed here)
- *   n_g_ifm_vertices     <--  global number of vertices on the full mesh before
- *                             joining. Use to create the new glob. vertex num.
+ *   init_max_vtx_gnum    <--  initial max. global numbering for vertices
  *   p_n_g_new_vertices   -->  global number of vertices created during the
  *                             intersection of edges
  *   p_vtx_eset           -->  structure storing equivalences between vertices
@@ -1071,11 +498,11 @@ _build_join_structures(cs_join_param_t           join_param,
  *---------------------------------------------------------------------------*/
 
 static void
-_intersect_edges(cs_join_param_t          param,
-                 cs_join_mesh_t          *work_join_mesh,
+_intersect_edges(cs_join_t               *this_join,
+                 cs_join_mesh_t          *work_jmesh,
                  const cs_join_edges_t   *work_join_edges,
                  cs_join_gset_t         **p_edge_edge_vis,
-                 fvm_gnum_t               n_g_ifm_vertices,
+                 fvm_gnum_t               init_max_vtx_gnum,
                  fvm_gnum_t              *p_n_g_new_vertices,
                  cs_join_eset_t         **p_vtx_eset,
                  cs_join_inter_edges_t  **p_inter_edges)
@@ -1087,6 +514,7 @@ _intersect_edges(cs_join_param_t          param,
   cs_join_inter_edges_t  *inter_edges = NULL;
   cs_join_eset_t  *vtx_eset = NULL;
   cs_join_inter_set_t  *inter_set = NULL;
+  cs_join_param_t  param = this_join->param;
 
   const int  n_ranks = cs_glob_n_ranks;
 
@@ -1105,14 +533,14 @@ _intersect_edges(cs_join_param_t          param,
   join_type = cs_join_intersect_edges(param,
                                       *p_edge_edge_vis,
                                       work_join_edges,
-                                      work_join_mesh,
+                                      work_jmesh,
                                       &vtx_eset,
                                       &inter_set);
 
   cs_join_gset_destroy(p_edge_edge_vis);
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG) /* Dump structures after inter. */
-  cs_join_inter_set_dump(inter_set, work_join_edges, work_join_mesh);
+  cs_join_inter_set_dump(inter_set, work_join_edges, work_jmesh);
 #endif
 
   /* Synchronize join_type */
@@ -1120,119 +548,404 @@ _intersect_edges(cs_join_param_t          param,
 #if defined(HAVE_MPI)
   if (n_ranks > 1) {
 
-    int  tag = (join_type == CS_JOIN_TYPE_CONFORM ? 0 : 1);
-    int  sync_tag = tag;
+    int  tag = (join_type == CS_JOIN_TYPE_CONFORM ? 0 : 1);
+    int  sync_tag = tag;
+
+    MPI_Allreduce(&tag, &sync_tag, 1, MPI_INT, MPI_MAX, cs_glob_mpi_comm);
+
+    if (sync_tag == 0)
+      join_type = CS_JOIN_TYPE_CONFORM;
+    else
+      join_type = CS_JOIN_TYPE_NO_CONFORM;
+
+  }
+#endif
+
+  if (join_type == CS_JOIN_TYPE_CONFORM) {
+
+    bft_printf(_("\n  Joining operation is conforming.\n"));
+    bft_printf_flush();
+
+    inter_set = cs_join_inter_set_destroy(inter_set);
+
+  }
+  else {
+
+    assert(join_type == CS_JOIN_TYPE_NO_CONFORM);
+
+    bft_printf(_("\n  Joining operation is non-conforming.\n"));
+    bft_printf_flush();
+
+    /* Creation of new vertices. Update list of equivalent vertices.
+       Associate to each intersection a vertex (old or created) */
+
+    cs_join_create_new_vertices(param.verbosity,
+                                work_join_edges,
+                                work_jmesh,
+                                inter_set,
+                                init_max_vtx_gnum,
+                                &n_g_new_vertices,
+                                &vtx_eset);
+
+    inter_edges = cs_join_inter_edges_define(work_join_edges, inter_set);
+    inter_set = cs_join_inter_set_destroy(inter_set);
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG) /* Dump structures after inter. */
+    cs_join_inter_edges_dump(inter_edges, work_join_edges, work_jmesh);
+#endif
+
+    /* Synchronize inter_edges structure definition */
+
+#if defined(HAVE_MPI)
+    if (n_ranks > 1 ) {
+
+      cs_join_inter_edges_t  *sync_block = NULL;
+
+      sync_block = cs_join_inter_edges_part_to_block(work_jmesh,
+                                                     work_join_edges,
+                                                     inter_edges);
+
+      cs_join_inter_edges_block_to_part(work_join_edges->n_g_edges,
+                                        sync_block,
+                                        inter_edges);
+
+      /* Add new vertices to edge and mesh description if necessary */
+
+      cs_join_intersect_update_struct(param.verbosity,
+                                      work_join_edges,
+                                      work_jmesh,
+                                      &inter_edges);
+
+      sync_block = cs_join_inter_edges_destroy(sync_block);
+
+      cs_join_mesh_sync_vertices(work_jmesh);
+
+    }
+#endif
+
+    /* Find if there are new equivalences between vertices on a same edge */
+
+    cs_join_add_equiv_from_edges(param,
+                                 work_jmesh,
+                                 work_join_edges,
+                                 inter_edges,
+                                 vtx_eset);
+
+  } /* no conform joining operation */
+
+  /* Order and delete redundant equivalences */
+
+  cs_join_eset_clean(&vtx_eset);
+
+  /* Memory management: final state for vtx_eset (no more equiv. to get) */
+
+  vtx_eset->n_max_equiv = vtx_eset->n_equiv;
+  BFT_REALLOC(vtx_eset->equiv_couple, 2*vtx_eset->n_equiv, cs_int_t);
+
+  clock_end = bft_timer_wtime();
+  cpu_end = bft_timer_cpu_time();
+
+  if (param.verbosity > 0)
+    bft_printf(_("\n"
+                 "  Edge intersections and vertex creation:\n"
+                 "    wall clock time:            %10.3g\n"
+                 "    CPU time:                   %10.3g\n"),
+               clock_end - clock_start, cpu_end - cpu_start);
+
+  /* Returns pointers */
+
+  *p_vtx_eset = vtx_eset;
+  *p_inter_edges = inter_edges;
+  *p_n_g_new_vertices = n_g_new_vertices;
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG) /* Dump structures after inter. */
+  cs_join_inter_edges_dump(inter_edges, work_join_edges, work_jmesh);
+#endif
+
+}
+
+#if defined(HAVE_MPI)
+
+/*----------------------------------------------------------------------------
+ * Retrieve the local new global numbering for the initial vertices from
+ * the new vertex global numbering defined by block.
+ *
+ * parameters:
+ *   param              <-- set of user-defined parameter
+ *   select             <-- pointer to a cs_join_select_t structure
+ *   mesh               <-- pointer of pointer to cs_mesh_t structure
+ *   init_max_vtx_gnum  <--  initial max. global numbering for vertices
+ *   p_o2n_vtx_gnum     <-> in:  array on blocks on the new global vertex
+ *                          out: local array on the new global vertex
+ *---------------------------------------------------------------------------*/
+
+static void
+_get_local_o2n_vtx_gnum(cs_join_param_t    param,
+                        cs_join_select_t  *select,
+                        cs_mesh_t         *mesh,
+                        fvm_gnum_t         init_max_vtx_gnum,
+                        fvm_gnum_t        *p_o2n_vtx_gnum[])
+{
+  cs_int_t  i, shift, rank;
+
+  cs_int_t  *send_shift = NULL, *recv_shift = NULL;
+  cs_int_t  *send_count = NULL, *recv_count = NULL;
+  fvm_gnum_t  *send_glist = NULL, *recv_glist = NULL;
+  fvm_gnum_t  *new_gnum_by_block = *p_o2n_vtx_gnum;
+  fvm_gnum_t  *new_local_gnum = NULL;
+
+  const int  n_ranks = cs_glob_n_ranks;
+  const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
+
+  cs_join_block_info_t  block_info = cs_join_get_block_info(init_max_vtx_gnum,
+                                                            n_ranks,
+                                                            local_rank);
+
+  MPI_Comm  mpi_comm = cs_glob_mpi_comm;
+
+  if (param.perio_num > 0)
+    BFT_MALLOC(new_local_gnum, mesh->n_vertices + select->n_vertices,
+               fvm_gnum_t);
+  else
+    BFT_MALLOC(new_local_gnum, mesh->n_vertices, fvm_gnum_t);
+
+  /* Request the new vtx gnum related to the initial vtx gnum */
+
+  BFT_MALLOC(send_count, n_ranks, cs_int_t);
+  BFT_MALLOC(recv_count, n_ranks, cs_int_t);
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  for (i = 0; i < mesh->n_vertices; i++) {
+    rank = (mesh->global_vtx_num[i] - 1)/block_info.size;
+    send_count[rank] += 1;
+  }
+
+  if (param.perio_num > 0) {
+
+    for (i = 0; i < select->n_vertices; i++) {
+      rank = (select->per_v_couples[2*i+1] - 1)/block_info.size;
+      send_count[rank] += 1;
+    }
+
+  }
+
+  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, mpi_comm);
+
+  BFT_MALLOC(send_shift, n_ranks + 1, cs_int_t);
+  BFT_MALLOC(recv_shift, n_ranks + 1, cs_int_t);
+
+  send_shift[0] = 0;
+  recv_shift[0] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++) {
+    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
+    recv_shift[rank + 1] = recv_shift[rank] + recv_count[rank];
+  }
+
+  /* Build send_list */
+
+  BFT_MALLOC(send_glist, send_shift[n_ranks], fvm_gnum_t);
+  BFT_MALLOC(recv_glist, recv_shift[n_ranks], fvm_gnum_t);
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  for (i = 0; i < mesh->n_vertices; i++) {
+
+    rank = (mesh->global_vtx_num[i] - 1)/block_info.size;
+    shift = send_shift[rank] + send_count[rank];
+    send_glist[shift] = mesh->global_vtx_num[i];  /* Old global number */
+    send_count[rank] += 1;
+
+  }
+
+  if (param.perio_num > 0) {
+
+    for (i = 0; i < select->n_vertices; i++) {
+      rank = (select->per_v_couples[2*i+1] - 1)/block_info.size;
+      shift = send_shift[rank] + send_count[rank];
+      send_glist[shift] = select->per_v_couples[2*i+1]; /* Old global num. */
+      send_count[rank] += 1;
+    }
+
+  }
+
+  MPI_Alltoallv(send_glist, send_count, send_shift, FVM_MPI_GNUM,
+                recv_glist, recv_count, recv_shift, FVM_MPI_GNUM,
+                mpi_comm);
+
+  /* Send back to the original rank the new global vertex number */
+
+  for (rank = 0; rank < n_ranks; rank++) {
+
+    for (i = recv_shift[rank]; i < recv_shift[rank+1]; i++) {
+      shift = recv_glist[i] - block_info.first_gnum;
+      recv_glist[i] = new_gnum_by_block[shift];
+    }
+
+  } /* End of loop on ranks */
+
+  MPI_Alltoallv(recv_glist, recv_count, recv_shift, FVM_MPI_GNUM,
+                send_glist, send_count, send_shift, FVM_MPI_GNUM,
+                mpi_comm);
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
 
-    MPI_Allreduce(&tag, &sync_tag, 1, MPI_INT, MPI_MAX, cs_glob_mpi_comm);
+  for (i = 0; i < mesh->n_vertices; i++) {
 
-    if (sync_tag == 0)
-      join_type = CS_JOIN_TYPE_CONFORM;
-    else
-      join_type = CS_JOIN_TYPE_NO_CONFORM;
+    rank = (mesh->global_vtx_num[i] - 1)/block_info.size;
+    shift = send_shift[rank] + send_count[rank];
+    new_local_gnum[i] = send_glist[shift];  /* New global number */
+    send_count[rank] += 1;
 
   }
-#endif
-
-  if (join_type == CS_JOIN_TYPE_CONFORM) {
 
-    bft_printf(_("\n  Joining operation is conforming.\n"));
-    bft_printf_flush();
+  if (param.perio_num > 0) {
 
-    inter_set = cs_join_inter_set_destroy(inter_set);
+    for (i = 0; i < select->n_vertices; i++) {
+      rank = (select->per_v_couples[2*i+1] - 1)/block_info.size;
+      shift = send_shift[rank] + send_count[rank];
+      new_local_gnum[mesh->n_vertices + i] = send_glist[shift]; /* New glob num. */
+      send_count[rank] += 1;
+    }
 
   }
-  else {
 
-    assert(join_type == CS_JOIN_TYPE_NO_CONFORM);
+  BFT_FREE(send_count);
+  BFT_FREE(send_shift);
+  BFT_FREE(send_glist);
+  BFT_FREE(recv_glist);
+  BFT_FREE(recv_count);
+  BFT_FREE(recv_shift);
+  BFT_FREE(new_gnum_by_block);
 
-    bft_printf(_("\n  Joining operation is non-conforming.\n"));
-    bft_printf_flush();
+  /* Return pointer */
 
-    /* Creation of new vertices. Update list of equivalent vertices.
-       Associate to each intersection a vertex (old or created) */
+  *p_o2n_vtx_gnum = new_local_gnum;
+}
 
-    cs_join_create_new_vertices(param.verbosity,
-                                work_join_edges,
-                                work_join_mesh,
-                                inter_set,
-                                n_g_ifm_vertices,
-                                &n_g_new_vertices,
-                                &vtx_eset);
+#endif
 
-    inter_edges = cs_join_inter_edges_define(work_join_edges, inter_set);
-    inter_set = cs_join_inter_set_destroy(inter_set);
+/*----------------------------------------------------------------------------
+ * Define o2n_vtx_gnum for the current rank and in case of periodic apply
+ * changes from periodic faces to original faces. Update also per_v_couples
+ *
+ * parameters:
+ *  this_join          <-- pointer to a cs_join_t structure
+ *  mesh               <-- pointer to a cs_mesh_t structure
+ *  local_jmesh        <-> pointer to a local cs_join_mesh_t structure
+ *  p_work_jmesh       <-> distributed join mesh struct. on which operations
+ *                         take place
+ *   p_work_edges      <-> join edges struct. related to work_jmesh
+ *  n_g_new_vertices   <-- global number of vertices created with the
+ *                         intersection of edges
+ *  init_max_vtx_gnum  <-- initial max. global numbering for vertices
+ *  o2n_vtx_gnum       <-> in:  array on blocks on the new global vertex
+ *                         out: local array on the new global vertex
+ *---------------------------------------------------------------------------*/
+static void
+_prepare_update_after_merge(cs_join_t          *this_join,
+                            cs_mesh_t          *mesh,
+                            cs_join_mesh_t     *local_jmesh,
+                            cs_join_mesh_t    **p_work_jmesh,
+                            cs_join_edges_t   **p_work_edges,
+                            fvm_gnum_t          n_g_new_vertices,
+                            fvm_gnum_t          init_max_vtx_gnum,
+                            fvm_gnum_t         *p_o2n_vtx_gnum[])
+{
+  int  i, select_id, shift;
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG) /* Dump structures after inter. */
-    cs_join_inter_edges_dump(inter_edges, work_join_edges, work_join_mesh);
-#endif
+  fvm_gnum_t  *o2n_vtx_gnum = *p_o2n_vtx_gnum;
+  cs_join_mesh_t  *work_jmesh = *p_work_jmesh;
+  cs_join_edges_t  *work_edges = *p_work_edges;
+  cs_join_select_t  *selection = this_join->selection;
+  cs_join_param_t  param = this_join->param;
 
-    /* Synchronize inter_edges structure definition */
+  const cs_int_t  n_ranks = cs_glob_n_ranks;
 
-#if defined(HAVE_MPI)
-    if (n_ranks > 1 ) {
+  /* Build an array keeping relation between old/new global vertex num. */
 
-      cs_join_inter_edges_t  *sync_block = NULL;
+  if (n_ranks == 1) {
 
-      sync_block = cs_join_inter_edges_part_to_block(work_join_mesh,
-                                                     work_join_edges,
-                                                     inter_edges);
+    fvm_gnum_t  *loc_vtx_gnum = NULL;
 
-      cs_join_inter_edges_block_to_part(work_join_edges->n_g_edges,
-                                        sync_block,
-                                        inter_edges);
+    BFT_MALLOC(loc_vtx_gnum, mesh->n_vertices, fvm_gnum_t);
 
-      /* Add new vertices to edge description if necessary */
+    /* Initialize array */
 
-      cs_join_intersect_update_struct(work_join_edges,
-                                      work_join_mesh,
-                                      &inter_edges);
+    for (i = 0; i < mesh->n_vertices; i++)
+      loc_vtx_gnum[i] = i+1;
 
-      sync_block = cs_join_inter_edges_destroy(sync_block);
+    /* Update value for selected vertices */
 
-      cs_join_mesh_sync_vertices(work_join_mesh);
+    for (i = 0, select_id = 0;
+         i < mesh->n_vertices && select_id < selection->n_vertices; i++) {
+
+      if (i + 1 == selection->vertices[select_id]) /* Is a selected vertex */
+        loc_vtx_gnum[i] = o2n_vtx_gnum[select_id++];
 
     }
-#endif
 
-    /* Find if there are new equivalences between vertices on a same edge */
+    if (param.perio_num > 0) { /* Update per_v_couples */
 
-    cs_join_add_equiv_from_edges(param,
-                                 work_join_mesh,
-                                 work_join_edges,
-                                 inter_edges,
-                                 vtx_eset);
+      assert(selection->n_vertices == selection->n_couples);
 
-  } /* no conform joining operation */
+      for (i = 0; i < selection->n_vertices; i++) {
+        shift = selection->n_vertices + i;
+        selection->per_v_couples[2*i] = o2n_vtx_gnum[i];
+        selection->per_v_couples[2*i+1] = o2n_vtx_gnum[shift];
+      }
 
-  /* Order and delete redundant equivalences */
+    }
 
-  cs_join_eset_clean(&vtx_eset);
+    BFT_FREE(o2n_vtx_gnum);
+    o2n_vtx_gnum = loc_vtx_gnum; /* Without periodic vertices and for
+                                    all vertices in cs_mesh_t structure */
 
-  /* Memory management: final state for vtx_eset (no more equiv. to get) */
+  } /* End if serial mode */
 
-  vtx_eset->n_max_equiv = vtx_eset->n_equiv;
-  BFT_REALLOC(vtx_eset->equiv_couple, 2*vtx_eset->n_equiv, cs_int_t);
+#if defined(HAVE_MPI)
+  if (n_ranks > 1) {
 
-  clock_end = bft_timer_wtime();
-  cpu_end = bft_timer_cpu_time();
+    _get_local_o2n_vtx_gnum(param,
+                            selection,
+                            mesh,
+                            init_max_vtx_gnum,
+                            &o2n_vtx_gnum);
 
-  if (param.verbosity > 0)
-    bft_printf(_("\n"
-                 "  Edge intersections and vertex creation:\n"
-                 "    wall clock time:            %10.3g\n"
-                 "    CPU time:                   %10.3g\n"),
-               clock_end - clock_start, cpu_end - cpu_start);
+    if (param.perio_num > 0) {
 
-  /* Returns pointers */
+      for (i = 0; i < selection->n_vertices; i++) {
+        select_id = selection->vertices[i] - 1;
+        shift = i + mesh->n_vertices;
+        selection->per_v_couples[2*i] = o2n_vtx_gnum[select_id];
+        selection->per_v_couples[2*i+1] = o2n_vtx_gnum[shift];
+      }
 
-  *p_vtx_eset = vtx_eset;
-  *p_inter_edges = inter_edges;
-  *p_n_g_new_vertices = n_g_new_vertices;
+      BFT_REALLOC(o2n_vtx_gnum, mesh->n_vertices, fvm_gnum_t);
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG) /* Dump structures after inter. */
-  cs_join_inter_edges_dump(inter_edges, work_join_edges, work_join_mesh);
+    }
+
+  }
 #endif
 
+  if (param.perio_num > 0)
+    cs_join_perio_merge_back(this_join,
+                             local_jmesh,
+                             &work_jmesh,
+                             &work_edges,
+                             init_max_vtx_gnum,
+                             n_g_new_vertices);
+
+  /* Return pointer */
+
+  *p_o2n_vtx_gnum = o2n_vtx_gnum;
+  *p_work_jmesh = work_jmesh;
+  *p_work_edges = work_edges;
+
 }
 
 /*----------------------------------------------------------------------------
@@ -1240,12 +953,9 @@ _intersect_edges(cs_join_param_t          param,
  * Update local and work structures after the merge step.
  *
  * parameters:
- *  param                <--  set of user-defined parameter for the joining
- *  join_select          <--  list of all implied entities in the
- *                            joining operation
+ *  this_join            <--  pointer to a cs_join_t structure
  *  n_iwm_vertices       <--  initial number of vertices in work struct.
- *  n_g_ifm_vertices     <--  initial global number of vertices for the full
- *                            mesh
+ *  init_max_vtx_gnum    <--  initial max. global numbering for vertices
  *  n_g_new_vertices     <--  global number of vertices created with the
  *                            intersection of edges
  *  rank_face_gnum_index <--  index on face global numering to determine the
@@ -1255,38 +965,39 @@ _intersect_edges(cs_join_param_t          param,
  *                            other in their tolerance
  *  inter_edges          <--  structure storing the definition of new vertices
  *                            on initial edges.
- *  p_work               <->  pointer to a cs_join_mesh_t structure
- *  p_edges              <->  pointer to a cs_join_edges_t structure
- *  p_local_join_mesh    <->  pointer to a cs_join_mesh_t structure
+ *  p_work_jmesh         <->  pointer to a cs_join_mesh_t structure
+ *  p_work_join_edges    <->  pointer to a cs_join_edges_t structure
+ *  p_local_jmesh        <->  pointer to a cs_join_mesh_t structure
  *  mesh                 <->  pointer to a cs_mesh_t struct. to update
  *---------------------------------------------------------------------------*/
 
 static void
-_merge_vertices(cs_join_param_t           param,
-                cs_join_select_t         *join_select,
+_merge_vertices(cs_join_t                *this_join,
                 cs_int_t                  n_iwm_vertices,
-                fvm_gnum_t                n_g_ifm_vertices,
+                fvm_gnum_t                init_max_vtx_gnum,
                 fvm_gnum_t                n_g_new_vertices,
                 cs_join_eset_t           *vtx_eset,
                 cs_join_inter_edges_t    *inter_edges,
-                cs_join_mesh_t          **p_work_join_mesh,
+                cs_join_mesh_t          **p_work_jmesh,
                 cs_join_edges_t         **p_work_join_edges,
-                cs_join_mesh_t          **p_local_join_mesh,
+                cs_join_mesh_t          **p_local_jmesh,
                 cs_mesh_t                *mesh)
 {
   int  i;
   double  clock_start, clock_end, cpu_start, cpu_end;
 
-  fvm_gnum_t  n_g_ai_vertices = n_g_ifm_vertices + n_g_new_vertices;
-  fvm_gnum_t  *rank_face_gnum_index = join_select->compact_rank_index;
+  fvm_gnum_t  new_max_vtx_gnum = init_max_vtx_gnum + n_g_new_vertices;
   fvm_gnum_t  *iwm_vtx_gnum = NULL;
   fvm_gnum_t  *o2n_vtx_gnum = NULL;
-  cs_join_mesh_t  *local_join_mesh = *p_local_join_mesh;
-  cs_join_mesh_t  *work_join_mesh = *p_work_join_mesh;
+  cs_join_mesh_t  *local_jmesh = *p_local_jmesh;
+  cs_join_mesh_t  *work_jmesh = *p_work_jmesh;
   cs_join_edges_t  *work_join_edges = *p_work_join_edges;
+  cs_join_param_t  param = this_join->param;
+  cs_join_select_t  *selection = this_join->selection;
+  fvm_gnum_t  *rank_face_gnum_index = selection->compact_rank_index;
 
-  assert(local_join_mesh != NULL);
-  assert(work_join_mesh != NULL);
+  assert(local_jmesh != NULL);
+  assert(work_jmesh != NULL);
   assert(work_join_edges != NULL);
 
   clock_start = bft_timer_wtime();
@@ -1301,13 +1012,13 @@ _merge_vertices(cs_join_param_t           param,
   BFT_MALLOC(iwm_vtx_gnum, n_iwm_vertices, fvm_gnum_t);
 
   for (i = 0; i < n_iwm_vertices; i++)
-    iwm_vtx_gnum[i] = (work_join_mesh->vertices[i]).gnum;
+    iwm_vtx_gnum[i] = (work_jmesh->vertices[i]).gnum;
 
   /* Merge vertices */
 
   cs_join_merge_vertices(param,
-                         n_g_ai_vertices,  /* ai: after intersection */
-                         work_join_mesh,
+                         new_max_vtx_gnum,
+                         work_jmesh,
                          vtx_eset);
 
   cs_join_eset_destroy(&vtx_eset);
@@ -1317,14 +1028,14 @@ _merge_vertices(cs_join_param_t           param,
 
   cs_join_merge_update_struct(param,
                               n_iwm_vertices,
-                              n_g_ifm_vertices,
                               iwm_vtx_gnum,
+                              init_max_vtx_gnum,
                               rank_face_gnum_index,
-                              &work_join_mesh,
+                              &work_jmesh,
                               &work_join_edges,
                               &inter_edges,
-                              &local_join_mesh,
-                              &o2n_vtx_gnum);
+                              &local_jmesh,
+                              &o2n_vtx_gnum); /* Defined by slice in // */
 
   /* Free memory */
 
@@ -1334,21 +1045,43 @@ _merge_vertices(cs_join_param_t           param,
 
   /* Post if required and level of verbosity is reached */
 
-  if (param.verbosity > 2)
-    cs_join_post_dump_mesh("MergeWorkMesh", work_join_mesh, param);
+  if (param.verbosity > 3)
+    cs_join_post_dump_mesh("MergeBeforePerioWorkMesh", work_jmesh, param);
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-    cs_join_mesh_dump_edges(work_join_edges, work_join_mesh);
-#endif
+  /* Define o2n_vtx_gnum for the current rank and
+     apply back periodic transformation if needed */
+
+  _prepare_update_after_merge(this_join,
+                              mesh,
+                              local_jmesh,
+                              &work_jmesh,
+                              &work_join_edges,
+                              n_g_new_vertices,
+                              init_max_vtx_gnum,
+                              &o2n_vtx_gnum); /* Defined for the local rank */
 
   /* Update cs_mesh_t structure after the vertex merge */
 
   cs_join_update_mesh_after_merge(param,
-                                  join_select,
+                                  selection,
                                   o2n_vtx_gnum,       /* free inside */
-                                  local_join_mesh,
+                                  local_jmesh,
                                   mesh);
 
+  /* Clean meshes after update (empty edges, degenerated edges,  ...) */
+
+  cs_join_mesh_clean(work_jmesh, param.verbosity);
+  cs_join_mesh_clean(local_jmesh, param.verbosity);
+
+  /* Define a new cs_join_edges_t structure */
+
+  cs_join_mesh_destroy_edges(&work_join_edges);
+  work_join_edges = cs_join_mesh_define_edges(work_jmesh);
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  cs_join_mesh_dump_edges(work_join_edges, work_jmesh);
+#endif
+
   clock_end = bft_timer_wtime();
   cpu_end = bft_timer_cpu_time();
 
@@ -1360,43 +1093,111 @@ _merge_vertices(cs_join_param_t           param,
                clock_end - clock_start, cpu_end - cpu_start);
   bft_printf_flush();
 
+  /* Post if required and level of verbosity is reached */
+
+  if (param.verbosity > 2)
+    cs_join_post_dump_mesh("MergeWorkMesh", work_jmesh, param);
+
   /* Set return pointers */
 
-  *p_local_join_mesh = local_join_mesh;
-  *p_work_join_mesh = work_join_mesh;
+  *p_local_jmesh = local_jmesh;
+  *p_work_jmesh = work_jmesh;
   *p_work_join_edges = work_join_edges;
 }
 
 /*----------------------------------------------------------------------------
+ * Prepare mesh update after split operation. Invert face history and update
+ * local_jmesh in case of periodicity by applying back split operation.
+ *
+ * parameters:
+ *  this_join          <-- pointer to a cs_join_t structure
+ *  local_jmesh        <-> pointer to a local cs_join_mesh_t structure
+ *  mesh               <-- pointer to a cs_mesh_t structure
+ *  p_history          <-> pointer to the history of face splitting
+ *                         in: old -> new face links
+ *                         out: new -> old face links
+ *---------------------------------------------------------------------------*/
+static void
+_prepare_update_after_split(cs_join_t          *this_join,
+                            cs_join_mesh_t     *local_jmesh,
+                            cs_mesh_t          *mesh,
+                            cs_join_gset_t    **p_history)
+{
+  cs_join_param_t  param = this_join->param;
+  cs_join_gset_t  *o2n_hist = *p_history, *n2o_hist = NULL;
+
+  const cs_int_t  n_ranks = cs_glob_n_ranks;
+
+  /* Invert face historic */
+
+  n2o_hist = cs_join_gset_invert(o2n_hist);
+
+#if defined(HAVE_MPI)
+    if (n_ranks > 1) {
+
+      cs_join_gset_t  *n2o_sync_block = NULL;
+
+      MPI_Comm  mpi_comm = cs_glob_mpi_comm;
+
+      n2o_sync_block = cs_join_gset_block_sync(local_jmesh->n_g_faces,
+                                               n2o_hist,
+                                               mpi_comm);
+
+      cs_join_gset_block_update(local_jmesh->n_g_faces,
+                                n2o_sync_block,
+                                n2o_hist,
+                                mpi_comm);
+
+      cs_join_gset_destroy(&n2o_sync_block);
+
+    }
+#endif
+
+  /* Build an array keeping relation between old/new global vertex num. */
+
+  if (param.perio_num > 0)
+    cs_join_perio_split_back(this_join,
+                             local_jmesh,
+                             mesh,
+                             o2n_hist,
+                             &n2o_hist);
+
+  cs_join_gset_destroy(&o2n_hist);
+
+  /* Return pointer */
+
+  *p_history = n2o_hist;
+}
+
+/*----------------------------------------------------------------------------
  * Split faces and update cs_mesh_t structure.
  *
  * parameters:
- *  param                <--  set of user-defined parameter
- *  join_select          <--  list of all implied entities in the
- *                            joining operation
+ *  this_join            <-- pointer to a cs_join_t structure
  *  work_join_edges      <--  pointer to a cs_join_edges_t structure
  *  work_face_normal     <--  normal based on the original face definition
  *  rank_face_gnum_index <--  index on face global numering to determine the
  *                            related rank
- *  p_work_join_mesh     <->  pointer to a cs_join_mesh_t structure
- *  local_join_mesh      <--  pointer to a cs_join_mesh_t structure
+ *  p_work_jmesh         <->  pointer to a cs_join_mesh_t structure
+ *  local_jmesh          <--  pointer to a cs_join_mesh_t structure
  *  p_mesh               <->  pointer to cs_mesh_t struct.
  *---------------------------------------------------------------------------*/
 
 static void
-_split_faces(cs_join_param_t      param,
-             cs_join_select_t    *join_select,
+_split_faces(cs_join_t           *this_join,
              cs_join_edges_t     *work_join_edges,
              fvm_coord_t         *work_face_normal,
-             cs_join_mesh_t     **p_work_join_mesh,
-             cs_join_mesh_t      *local_join_mesh,
+             cs_join_mesh_t     **p_work_jmesh,
+             cs_join_mesh_t      *local_jmesh,
              cs_mesh_t          **p_mesh)
 {
   double  clock_start, clock_end, cpu_start, cpu_end;
 
-  fvm_gnum_t  *rank_face_gnum_index = join_select->compact_rank_index;
-  cs_join_gset_t  *old2new_hist = NULL;
   cs_mesh_t  *mesh = *p_mesh;
+  cs_join_gset_t  *history = NULL;
+  cs_join_param_t  param = this_join->param;
+  cs_join_select_t  *selection = this_join->selection;
+  fvm_gnum_t  *rank_face_gnum_index = selection->compact_rank_index;
 
   clock_start = bft_timer_wtime();
   cpu_start = bft_timer_cpu_time();
@@ -1404,22 +1205,28 @@ _split_faces(cs_join_param_t      param,
   cs_join_split_faces(param,
                       work_face_normal,
                       work_join_edges,
-                      p_work_join_mesh,
-                      &old2new_hist);
+                      p_work_jmesh,
+                      &history); /* old -> new */
 
   /* Send back to the original rank the new face description */
 
-  cs_join_split_update_struct(*p_work_join_mesh,
+  cs_join_split_update_struct(param,
+                              *p_work_jmesh,
                               rank_face_gnum_index,
-                              &old2new_hist,
-                              &local_join_mesh);
+                              &history, /* old -> new */
+                              &local_jmesh);
+
+  _prepare_update_after_split(this_join,
+                              local_jmesh,
+                              mesh,
+                              &history); /* in: old->new, out: new -> old */
 
   /* Update cs_mesh_t structure after the face splitting */
 
   cs_join_update_mesh_after_split(param,
-                                  join_select,
-                                  old2new_hist,
-                                  local_join_mesh,
+                                  selection,
+                                  history, /* new -> old */
+                                  local_jmesh,
                                   mesh);
 
   clock_end = bft_timer_wtime();
@@ -1438,35 +1245,11 @@ _split_faces(cs_join_param_t      param,
   /* Post if required and level of verbosity is reached */
 
   if (param.verbosity > 2)
-    cs_join_post_dump_mesh("SplitWorkMesh", *p_work_join_mesh, param);
+    cs_join_post_dump_mesh("SplitWorkMesh", *p_work_jmesh, param);
 
   /* Free memory */
 
-  cs_join_gset_destroy(&old2new_hist);
-}
-
-/*----------------------------------------------------------------------------
- * Delete all cs_join_t structures.
- *---------------------------------------------------------------------------*/
-
-static void
-_destroy_all_joinings(void)
-{
-  cs_int_t  i;
-
-  for (i = 0; i < cs_glob_n_joinings; i++) {
-
-    cs_join_t  *join = cs_glob_join_array[i];
-
-    BFT_FREE(join->criteria);
-    BFT_FREE(join);
-
-    cs_glob_join_array[i] = NULL;
-
-  } /* End of loop on cs_join_t structures */
-
-  cs_glob_n_joinings = 0;
-  BFT_FREE(cs_glob_join_array);
+  cs_join_gset_destroy(&history);
 
 }
 
@@ -1491,6 +1274,8 @@ void CS_PROCF(numjoi, NUMJOI)
 )
 {
   *numjoi = cs_glob_n_joinings;
+
+  return;
 }
 
 /*----------------------------------------------------------------------------
@@ -1571,7 +1356,6 @@ void CS_PROCF(setajp, SETAJP)
  cs_int_t    *tml,
  cs_int_t    *tmb,
  cs_real_t   *tmr
- CS_ARGF_SUPP_CHAINE
 )
 {
   cs_int_t  i, join_id = -1;
@@ -1613,14 +1397,14 @@ void CS_PROCF(setajp, SETAJP)
  *===========================================================================*/
 
 /*----------------------------------------------------------------------------
- * Create and initialize a cs_join_t structure.
+ * Add a cs_join_t structure to the list of pending joinings.
  *
  * parameters:
- *   join_number   <-- number related to the joining operation
- *   sel_criteria  <-- boundary face selection criteria
- *   fraction      <-- value of the fraction parameter
- *   plane         <-- value of the plane parameter
- *   verbosity     <-- level of verbosity required
+ *   join_number  <-- number related to the joining operation
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   verbosity    <-- level of verbosity required
  *---------------------------------------------------------------------------*/
 
 void
@@ -1630,10 +1414,6 @@ cs_join_add(int     join_number,
             float   plane,
             int     verbosity)
 {
-  size_t  l;
-
-  cs_join_t  *join = NULL;
-
   /* Check parameters value */
 
   if (fraction < 0.0 || fraction >= 1.0)
@@ -1650,153 +1430,22 @@ cs_join_add(int     join_number,
                 "  It must be between [0, 90] and is here: %f\n"),
               plane);
 
-   /* Allocate and initialize a cs_join_t structure */
+  /* Allocate and initialize a cs_join_t structure */
 
   BFT_REALLOC(cs_glob_join_array, cs_glob_n_joinings + 1, cs_join_t *);
-  BFT_MALLOC(join, 1, cs_join_t);
-
-  join->param = cs_join_param_define(join_number,
-                                     fraction,
-                                     plane,
-                                     verbosity);
-
-  /* Copy the selection criteria for future use */
 
-  l = strlen(sel_criteria);
-  BFT_MALLOC(join->criteria, l + 1, char);
-  strcpy(join->criteria, sel_criteria);
+  cs_glob_join_array[cs_glob_n_joinings] = cs_join_create(join_number,
+                                                          sel_criteria,
+                                                          fraction,
+                                                          plane,
+                                                          0, /* No perio. */
+                                                          verbosity);
 
-  /* Update global array */
-
-  cs_glob_join_array[cs_glob_n_joinings] = join;
+  cs_glob_join_count++; // Store number of joining (without periodic ones)
   cs_glob_n_joinings++;
 }
 
 /*----------------------------------------------------------------------------
- * Set advanced parameters to user-defined values.
- *
- * parameters:
- *   join           <-> pointer a to cs_join_t struct. to update
- *   mtf            <-- merge tolerance coefficient
- *   pmf            <-- pre-merge factor
- *   tcm            <-- tolerance computation mode
- *   icm            <-- intersection computation mode
- *   maxbrk         <-- max number of equivalences to break (merge step)
- *   max_sub_faces  <-- max. possible number of sub-faces by splitting a face
- *   tml            <-- tree max level
- *   tmb            <-- tree max boxes
- *   tmr            <-- tree max ratio
- *---------------------------------------------------------------------------*/
-
-void
-cs_join_set_advanced_param(cs_join_t   *join,
-                           cs_real_t    mtf,
-                           cs_real_t    pmf,
-                           cs_int_t     tcm,
-                           cs_int_t     icm,
-                           cs_int_t     maxbrk,
-                           cs_int_t     max_sub_faces,
-                           cs_int_t     tml,
-                           cs_int_t     tmb,
-                           cs_real_t    tmr)
-{
-  /* Deepest level reachable during tree building */
-
-  if (tml < 1)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for the tml parameter.\n"
-                "  It must be between > 0 and is here: %d\n"), tml);
-
-  join->param.tree_max_level = tml;
-
-  /* Max. number of boxes which can be related to a leaf of the tree
-     if level != tree_max_level */
-
-  if (tmb < 1)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for the tmb parameter.\n"
-                "  It must be between > 0 and is here: %d\n"), tmb);
-
-  join->param.tree_n_max_boxes = tmb;
-
-  /* Stop tree building if:
-     n_linked_boxes > tree_max_box_ratio*n_init_boxes */
-
-  if (tmr <= 0.0 )
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for the tmr parameter.\n"
-                "  It must be between > 0.0 and is here: %f\n"), tmr);
-
-  join->param.tree_max_box_ratio = tmr;
-
-  /* Coef. used to modify the tolerance associated to each vertex BEFORE the
-     merge operation.
-     If coef = 0.0 => no vertex merge
-     If coef < 1.0 => reduce vertex merge
-     If coef = 1.0 => no change
-     If coef > 1.0 => increase vertex merge */
-
-  if (mtf < 0.0)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for the merge tolerance factor.\n"
-                "  It must be positive or nul and not: %f\n"), mtf);
-
-  join->param.merge_tol_coef = mtf;
-
-   /* Maximum number of equivalence breaks */
-
-  if (maxbrk < 0)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for the max. number of tolerance breaks.\n"
-                "  It must be between >= 0 and not: %d\n"), maxbrk);
-
-  join->param.n_max_equiv_breaks = maxbrk;
-
-  /* Pre-merge factor. This parameter is used to define a limit
-     under which two vertices are merged before the merge step.
-     Tolerance limit for the pre-merge = pmf * fraction
-     Default value: 0.10 */
-
-  join->param.pre_merge_factor = pmf;
-
-  /* Tolerance computation mode */
-
-  if ( (tcm)%10 < 1 || (tcm)%10 > 2)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for the tcm parameter.\n"
-                "  It must be between 1, 2 or 11, 12 and here is: %d\n"), tcm);
-
-  join->param.tcm = tcm;
-
-  /* Intersection computation mode */
-
-  if (icm != 1 && icm != 2)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for icm parameter.\n"
-                "  It must be 1 or 2 and here is: %d\n"), icm);
-
-  join->param.icm = icm;
-
-  /* Maximum number of sub-faces */
-
-  if (max_sub_faces < 1)
-    bft_error(__FILE__, __LINE__, 0,
-              _("Mesh joining:"
-                "  Forbidden value for the maxsf parameter.\n"
-                "  It must be between > 0 and here is: %d\n"), max_sub_faces);
-
-  join->param.max_sub_faces = max_sub_faces;
-
-}
-
-/*----------------------------------------------------------------------------
  * Apply all the defined joining operations.
  *---------------------------------------------------------------------------*/
 
@@ -1807,7 +1456,6 @@ cs_join_all(void)
   double  clock_start, clock_end, cpu_start, cpu_end;
   double  full_clock_start, full_clock_end, full_cpu_start, full_cpu_end;
 
-  cs_real_t  *b_face_cog = NULL, *b_face_normal = NULL;
   cs_mesh_t  *mesh = cs_glob_mesh;
 
   if (cs_glob_n_joinings < 1)
@@ -1827,9 +1475,8 @@ cs_join_all(void)
 
   for (join_id = 0; join_id < cs_glob_n_joinings; join_id++) {
 
-    cs_join_t  *join_info = cs_glob_join_array[join_id];
-    cs_join_param_t  join_param = join_info->param;
-    cs_join_select_t  *join_select = NULL;
+    cs_join_t  *this_join = cs_glob_join_array[join_id];
+    cs_join_param_t  join_param = this_join->param;
 
     clock_start = bft_timer_wtime();  /* Start timer */
     cpu_start = bft_timer_cpu_time();
@@ -1837,8 +1484,12 @@ cs_join_all(void)
     /* Print information into listing file */
 
     bft_printf(_("\n -------------------------------------------------------\n"
-                 "  Joining number %d:\n\n"), join_id + 1);
-    bft_printf(_("  Selection criteria: \"%s\"\n"), join_info->criteria);
+                 "  Joining number %d:\n\n"), join_param.num);
+
+    if (join_param.perio_num > 0)
+      bft_printf(_("\n  Joining for periodicity: %d\n"), join_param.perio_num);
+
+    bft_printf(_("  Selection criteria: \"%s\"\n"), this_join->criteria);
 
     if (join_param.verbosity > 0) {
       bft_printf(_("\n"
@@ -1847,120 +1498,66 @@ cs_join_all(void)
                    "    Maximum angle between joined face planes: %8.5f\n\n"),
                  join_param.fraction, join_param.plane);
 
-      if (join_param.verbosity > 1)
-         bft_printf(_("  Advanced join parameters:\n"
-                      "    Deepest level reachable in tree building: %8d\n"
-                      "    Max boxes by leaf:                        %8d\n"
-                      "    Max ratio of linked boxes / init. boxes:  %8.5f\n"
-                      "    Merge step tolerance multiplier:          %8.5f\n"
-                      "    Pre-merge factor:                         %8.5f\n"
-                      "    Tolerance computation mode:               %8d\n"
-                      "    Intersection computation mode:            %8d\n"
-                      "    Max. number of equiv. breaks:             %8d\n"
-                      "    Max. number of subfaces by face:          %8d\n\n"),
-                    join_param.tree_max_level,
-                    join_param.tree_n_max_boxes,
-                    join_param.tree_max_box_ratio,
-                    join_param.merge_tol_coef,
-                    join_param.pre_merge_factor,
-                    join_param.tcm, join_param.icm,
-                    join_param.n_max_equiv_breaks,
-                    join_param.max_sub_faces);
+      bft_printf(_("  Advanced joining parameters:\n"
+                   "    Verbosity level:                          %8d\n"
+                   "    Deepest level reachable in tree building: %8d\n"
+                   "    Max boxes by leaf:                        %8d\n"
+                   "    Max ratio of linked boxes / init. boxes:  %8.5f\n"
+                   "    Merge step tolerance multiplier:          %8.5f\n"
+                   "    Pre-merge factor:                         %8.5f\n"
+                   "    Tolerance computation mode:               %8d\n"
+                   "    Intersection computation mode:            %8d\n"
+                   "    Max. number of equiv. breaks:             %8d\n"
+                   "    Max. number of subfaces by face:          %8d\n\n"),
+                 join_param.verbosity,
+                 join_param.tree_max_level,
+                 join_param.tree_n_max_boxes,
+                 join_param.tree_max_box_ratio,
+                 join_param.merge_tol_coef,
+                 join_param.pre_merge_factor,
+                 join_param.tcm, join_param.icm,
+                 join_param.n_max_equiv_breaks,
+                 join_param.max_sub_faces);
 
       cs_mesh_print_info(mesh, _(" Before joining"));
       bft_printf("\n");
     }
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
-    {
-      int  len;
-      FILE  *dbg_file = NULL;
-      char  *filename = NULL;
-
-      len = strlen("JoinDBG_InitMesh_.dat")+1+4+2;
-      BFT_MALLOC(filename, len, char);
-      sprintf(filename, "Join%02dDBG_InitMesh_%04d.dat",
-              join_id+1, fvm_parall_get_rank());
-      dbg_file = fopen(filename, "w");
-
-      cs_mesh_dump_file(dbg_file, mesh);
-
-      fflush(dbg_file);
-      BFT_FREE(filename);
-      fclose(dbg_file);
-    }
+    _dump_mesh(join_param.num, "InitMesh", mesh);
 #endif
 
     /* Build arrays and structures required for selection;
-       will be destoyed after joining and rebuilt once all
-       join operations are finished */
-
-    cs_mesh_init_group_classes(mesh);
-
-    cs_mesh_quantities_b_faces(mesh, &b_face_cog, &b_face_normal);
-
-    cs_glob_mesh->select_b_faces
-      = fvm_selector_create(mesh->dim,
-                            mesh->n_b_faces,
-                            mesh->class_defs,
-                            mesh->b_face_family,
-                            1,
-                            b_face_cog,
-                            b_face_normal);
-
-    /* Get selected faces for this joining and define the related
-       cs_join_face_select_t structure.
-       - Compute the global number of selected faces
-       - Get the adjacent faces, ...  */
-
-    join_select = cs_join_select_create(join_info->criteria,
-                                        join_param.verbosity);
-
-    bft_printf(_("\n  Element selection successfully done.\n"));
-    bft_printf_flush();
-
-    /* Free arrays and structures needed for selection */
+       will be destoyed after joining and rebuilt for each new join
+       operation in order to take into account mesh modification  */
 
-    BFT_FREE(b_face_cog);
-    BFT_FREE(b_face_normal);
-
-    mesh->class_defs = fvm_group_class_set_destroy(mesh->class_defs);
-
-    if (mesh->select_b_faces != NULL)
-      mesh->select_b_faces = fvm_selector_destroy(mesh->select_b_faces);
-    if (mesh->class_defs != NULL)
-      mesh->class_defs = fvm_group_class_set_destroy(mesh->class_defs);
+    _select_entities(this_join, mesh);
 
     /* Now execute the joining operation */
 
-    if (join_select->n_g_faces > 0) {
+    if (this_join->selection->n_g_faces > 0) {
 
       cs_int_t  n_iwm_vertices;      /* iwm: initial work mesh */
-      fvm_gnum_t  n_g_ifm_vertices;  /* ifm: initial full mesh */
-      fvm_gnum_t  n_g_new_vertices;
+      fvm_gnum_t  init_max_vtx_gnum, n_g_new_vertices;
 
       cs_real_t  *work_face_normal = NULL;
       cs_join_gset_t  *edge_edge_visibility = NULL;
-      cs_join_mesh_t  *work_join_mesh = NULL, *local_join_mesh = NULL;
+      cs_join_mesh_t  *work_jmesh = NULL, *local_jmesh = NULL;
       cs_join_edges_t  *work_join_edges = NULL;
       cs_join_eset_t  *vtx_eset = NULL;
       cs_join_inter_edges_t  *inter_edges = NULL;
 
-      _build_join_structures(join_param,
-                             join_select,
+      _build_join_structures(this_join,
                              mesh,
-                             &local_join_mesh,
-                             &work_join_mesh,
+                             &local_jmesh,
+                             &work_jmesh,
                              &work_join_edges,
                              &work_face_normal,
                              &edge_edge_visibility);
 
-      n_iwm_vertices = work_join_mesh->n_vertices;
-      n_g_ifm_vertices = mesh->n_g_vertices;
-
       if (join_param.verbosity > 2)
         bft_printf(_("\n  Number of faces to treat locally: %10d\n"),
-                   work_join_mesh->n_faces);
+                   work_jmesh->n_faces);
 
       /*
 
@@ -1976,11 +1573,17 @@ cs_join_all(void)
 
       */
 
-      _intersect_edges(join_param,
-                       work_join_mesh,
+      n_iwm_vertices = work_jmesh->n_vertices;
+
+      init_max_vtx_gnum = mesh->n_g_vertices;
+      if (join_param.perio_num > 0)
+        init_max_vtx_gnum += this_join->selection->n_g_vertices;
+
+      _intersect_edges(this_join,
+                       work_jmesh,
                        work_join_edges,
                        &edge_edge_visibility, /* free during this step */
-                       mesh->n_g_vertices,
+                       init_max_vtx_gnum,
                        &n_g_new_vertices,
                        &vtx_eset,
                        &inter_edges);
@@ -1993,36 +1596,38 @@ cs_join_all(void)
          local structure update after the merge step.
       */
 
-      _merge_vertices(join_param,
-                      join_select,
+      _merge_vertices(this_join,
                       n_iwm_vertices,
-                      n_g_ifm_vertices,
+                      init_max_vtx_gnum,
                       n_g_new_vertices,
                       vtx_eset,         /* free during this step */
                       inter_edges,      /* free during this step */
-                      &work_join_mesh,
+                      &work_jmesh,
                       &work_join_edges,
-                      &local_join_mesh,
+                      &local_jmesh,
                       mesh);
 
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+    _dump_mesh(join_param.num, "MeshAfterMerge", mesh);
+#endif
+
       /*
-         Split faces in work_join_mesh. Apply modification to the
-         local_join_mesh. Keep a history between old --> new faces.
+         Split faces in work_jmesh. Apply modification to the
+         local_jmesh. Keep a history between old --> new faces.
          Update cs_mesh_t structure.
       */
 
-      _split_faces(join_param,
-                   join_select,
+      _split_faces(this_join,
                    work_join_edges,
                    work_face_normal,
-                   &work_join_mesh,
-                   local_join_mesh,
+                   &work_jmesh,
+                   local_jmesh,
                    &mesh);
 
       /* Free memory */
 
-      cs_join_mesh_destroy(&local_join_mesh);
-      cs_join_mesh_destroy(&work_join_mesh);
+      cs_join_mesh_destroy(&local_jmesh);
+      cs_join_mesh_destroy(&work_jmesh);
       cs_join_mesh_destroy_edges(&work_join_edges);
 
       BFT_FREE(work_face_normal);
@@ -2035,9 +1640,15 @@ cs_join_all(void)
     else
       bft_printf(_("\nStop joining algorithm: no face selected...\n"));
 
-    /* Free memory */
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+    _dump_mesh(join_param.num, "FinalMesh", mesh);
+#endif
 
-    cs_join_select_destroy(&join_select);
+    if (join_param.verbosity > 0) {
+      bft_printf("\n");
+      cs_mesh_print_info(mesh, _(" After joining"));
+      bft_printf("\n");
+    }
 
     clock_end = bft_timer_wtime();
     cpu_end = bft_timer_cpu_time();
@@ -2046,34 +1657,12 @@ cs_join_all(void)
                  "  Complete joining treatment for joining %2d\n"
                  "    wall clock time:            %10.3g\n"
                  "    CPU time:                   %10.3g\n"),
-               join_id+1, clock_end - clock_start, cpu_end - cpu_start);
+               join_param.num, clock_end - clock_start, cpu_end - cpu_start);
     bft_printf_flush();
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-    {
-      int  len;
-      FILE  *dbg_file = NULL;
-      char  *filename = NULL;
-
-      len = strlen("JoinDBG_FinalMesh_.dat")+1+4+2;
-      BFT_MALLOC(filename, len, char);
-      sprintf(filename, "Join%02dDBG_FinalMesh_%04d.dat",
-              join_id+1, fvm_parall_get_rank());
-      dbg_file = fopen(filename, "w");
-
-      cs_mesh_dump_file(dbg_file, mesh);
-
-      fflush(dbg_file);
-      BFT_FREE(filename);
-      fclose(dbg_file);
-    }
-#endif
+    /* Free memory */
 
-    if (join_param.verbosity > 0) {
-      bft_printf("\n");
-      cs_mesh_print_info(mesh, _(" After joining"));
-      bft_printf("\n");
-    }
+    cs_join_destroy(&this_join);
 
 #if defined(HAVE_MPI)   /* Synchronization */
     if (cs_glob_n_ranks > 1)
@@ -2084,7 +1673,10 @@ cs_join_all(void)
 
   /* Destroy all remaining structures relative to joining operation */
 
-  _destroy_all_joinings();
+  BFT_FREE(cs_glob_join_array);
+
+  if (cs_glob_n_join_perio > 0)
+    cs_join_perio_transfer_builder();
 
   full_clock_end = bft_timer_wtime();
   full_cpu_end = bft_timer_cpu_time();
@@ -2104,26 +1696,6 @@ cs_join_all(void)
 /*---------------------------------------------------------------------------*/
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
-  {
-    int  len;
-    FILE  *dbg_file = NULL;
-    char  *filename = NULL;
-
-    len = strlen("JoinDBG_.dat")+ strlen(local_join_mesh->name) + 4 + 1 + 2;
-    BFT_MALLOC(filename, len, char);
-    sprintf(filename, "Join%02dDBG_%s%04d.dat",
-            join_param.num, local_join_mesh->name, fvm_parall_get_rank());
-    dbg_file = fopen(filename, "w");
-
-    cs_join_mesh_dump_file(dbg_file, local_join_mesh);
-
-    fflush(dbg_file);
-    BFT_FREE(filename);
-    fclose(dbg_file);
-  }
-#endif
-
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
     cs_debug_glob_mesh_dump("FinalGlobalVertices", mesh);
 #endif
 
diff --git a/src/base/cs_join_f2c.f90 b/src/base/cs_join_f2c.f90
index 9439e83..558c194 100644
--- a/src/base/cs_join_f2c.f90
+++ b/src/base/cs_join_f2c.f90
@@ -3,7 +3,7 @@
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2009 EDF S.A., France
+!     Copyright (C) 1998-2010 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -31,35 +31,33 @@ subroutine defjoi &
  ( numjoi, critjo, fract, plane, iwarnj )
 
 !===============================================================================
-! FONCTION :
-! ----------
+! Purpose:
+! -------
 
-!     DEFINITION DE RECOLLEMENT DE MAILLAGES
+! Definition of mesh face joining.
 
 !-------------------------------------------------------------------------------
-!ARGU                             ARGUMENTS
+! Arguments
 !__________________.____._____.________________________________________________.
-! name             !type!mode ! role                                           !
+!    nom           !type!mode !                   role                         !
 !__________________!____!_____!________________________________________________!
-! numjoi           ! e  ! <-- ! join number                                    !
+! numjoi           ! i  ! <-- ! join number                                    !
 ! critjo           ! a  ! <-- ! selection criteria for the border faces to     !
 !                  !    !     ! transform                                      !
 ! fract            ! r  ! <-- ! fraction parameter                             !
 ! plane            ! r  ! <-- ! face coplanarity parameter                     !
-! iwarnj           ! e  ! <-- ! level of display                               !
+! iwarnj           ! i  ! <-- ! verbosity level                                !
 !__________________!____!_____!________________________________________________!
 
-!     TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
-!            L (LOGIQUE)   .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
-!     MODE : <-- donnee, --> resultat, <-> Donnee modifiee
-!            --- tableau de travail
-
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
 !===============================================================================
 
 implicit none
 
 !===============================================================================
-! Common blocks
+!     DONNEES EN COMMON
 !===============================================================================
 
 !===============================================================================
@@ -70,7 +68,7 @@ character*(*)    critjo
 integer          iwarnj, numjoi
 double precision fract, plane
 
-! Variables locales
+! Local variables
 
 integer       lcritj
 
diff --git a/src/base/cs_join_intersect.c b/src/base/cs_join_intersect.c
index ef89285..79d2c90 100644
--- a/src/base/cs_join_intersect.c
+++ b/src/base/cs_join_intersect.c
@@ -341,6 +341,7 @@ _get_new_vertex(float                  curv_abs,
   /* New global number */
 
   new_vtx_data.gnum = gnum;
+  new_vtx_data.state = CS_JOIN_STATE_NEW;
 
   /* New tolerance */
 
@@ -844,13 +845,17 @@ _new_edge_edge_3d_inter(const cs_join_mesh_t   *mesh,
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
   if (tst_dbg) {
     bft_printf("\n\np1e1 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n",
-               p1e1.gnum, p1e1.coord[0], p1e1.coord[1], p1e1.coord[2], p1e1.tolerance);
+               p1e1.gnum, p1e1.coord[0], p1e1.coord[1], p1e1.coord[2],
+               p1e1.tolerance);
     bft_printf("p2e1 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n",
-               p2e1.gnum, p2e1.coord[0], p2e1.coord[1], p2e1.coord[2], p2e1.tolerance);
+               p2e1.gnum, p2e1.coord[0], p2e1.coord[1], p2e1.coord[2],
+               p2e1.tolerance);
     bft_printf("p1e2 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n",
-               p1e2.gnum, p1e2.coord[0], p1e2.coord[1], p1e2.coord[2], p1e2.tolerance);
+               p1e2.gnum, p1e2.coord[0], p1e2.coord[1], p1e2.coord[2],
+               p1e2.tolerance);
     bft_printf("p2e2 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n\n",
-               p2e2.gnum, p2e2.coord[0], p2e2.coord[1], p2e2.coord[2], p2e2.tolerance);
+               p2e2.gnum, p2e2.coord[0], p2e2.coord[1], p2e2.coord[2],
+               p2e2.tolerance);
     bft_printf("v0 : [ %10.8e %10.8e %10.8e]\n", v0[0], v0[1], v0[2]);
     bft_printf("v1 : [ %10.8e %10.8e %10.8e]\n", v1[0], v1[1], v1[2]);
     bft_printf("v2 : [ %10.8e %10.8e %10.8e]\n\n", v2[0], v2[1], v2[2]);
@@ -1514,13 +1519,17 @@ _edge_edge_3d_inter(const cs_join_mesh_t   *mesh,
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
   if (tst_dbg) {
     bft_printf("\n\np1e1 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n",
-               p1e1.gnum, p1e1.coord[0], p1e1.coord[1], p1e1.coord[2], p1e1.tolerance);
+               p1e1.gnum, p1e1.coord[0], p1e1.coord[1], p1e1.coord[2],
+               p1e1.tolerance);
     bft_printf("p2e1 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n",
-               p2e1.gnum, p2e1.coord[0], p2e1.coord[1], p2e1.coord[2], p2e1.tolerance);
+               p2e1.gnum, p2e1.coord[0], p2e1.coord[1], p2e1.coord[2],
+               p2e1.tolerance);
     bft_printf("p1e2 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n",
-               p1e2.gnum, p1e2.coord[0], p1e2.coord[1], p1e2.coord[2], p1e2.tolerance);
+               p1e2.gnum, p1e2.coord[0], p1e2.coord[1], p1e2.coord[2],
+               p1e2.tolerance);
     bft_printf("p2e2 : %10u - [%10.8e %10.8e %10.8e] - tol: %10.8g\n\n",
-               p2e2.gnum, p2e2.coord[0], p2e2.coord[1], p2e2.coord[2], p2e2.tolerance);
+               p2e2.gnum, p2e2.coord[0], p2e2.coord[1], p2e2.coord[2],
+               p2e2.tolerance);
     bft_printf("v0 : [ %10.8e %10.8e %10.8e]\n", v0[0], v0[1], v0[2]);
     bft_printf("v1 : [ %10.8e %10.8e %10.8e]\n", v1[0], v1[1], v1[2]);
     bft_printf("v2 : [ %10.8e %10.8e %10.8e]\n\n", v2[0], v2[1], v2[2]);
@@ -2279,7 +2288,7 @@ cs_join_inter_set_create(cs_int_t  init_size)
 /*----------------------------------------------------------------------------
  * Destroy a cs_join_inter_set_t structure.
  *
- * parameter:
+ * parameters:
  *   inter_set <-- a pointer to the inter_set_t structure to destroy
  *
  * returns:
@@ -2633,29 +2642,52 @@ cs_join_add_equiv_from_edges(cs_join_param_t               param,
                                               mesh->vertices[v2_id]);
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
-        fvm_gnum_t  v1_gnum = (mesh->vertices[v1_num-1]).gnum;
-        fvm_gnum_t  v2_gnum = (mesh->vertices[v2_num-1]).gnum;
-        bft_printf("\n%6d: [%9u] = (%7d [%9u] - %7d [%9u] - len: %8.6e)\n",
-                   i, edges->gnum[i], v1_num, v1_gnum, v2_num, v2_gnum,
-                   edge_length);
-        if (inter_edges->vtx_glst == NULL) {
-          for (j = start, k = 0; j < end; j++, k++) {
-            int  vid = inter_edges->vtx_lst[j] - 1;
-            double  ds_tol = mesh->vertices[vid].tolerance/edge_length;
-            bft_printf("    %7d (%9u) - (%7d, s = %8.6e, ds_tol = %8.6e)\n",
-                       k+1, vid+1, mesh->vertices[vid].gnum,
-                       inter_edges->abs_lst[j], ds_tol);
+        if (param.verbosity > 3) {
+          int  vid;
+          double  ds_tol;
+          fvm_gnum_t  v1_gnum = (mesh->vertices[v1_num-1]).gnum;
+          fvm_gnum_t  v2_gnum = (mesh->vertices[v2_num-1]).gnum;
+
+          bft_printf("\n%6d: [%9u] = (%7d [%9u] - %7d [%9u] - len: %8.6e)\n",
+                     i, edges->gnum[i], v1_num, v1_gnum, v2_num, v2_gnum,
+                     edge_length);
+          bft_printf_flush();
+
+          if (inter_edges->vtx_glst == NULL) {
+
+            for (j = start, k = 0; j < end; j++, k++) {
+              vid = inter_edges->vtx_lst[j] - 1;
+              if (vid > mesh->n_vertices) {
+                cs_join_mesh_dump(mesh);
+                bft_printf("vid: %d - n_vertices: %d\n",
+                           vid, mesh->n_vertices);
+                bft_error(__FILE__, __LINE__, 0,
+                          _("  Vertex number out of bounds.\n"));
+              }
+              ds_tol = mesh->vertices[vid].tolerance/edge_length;
+              bft_printf("    %7d (%9u) - (%7d, s = %8.6e, ds_tol = %8.6e)\n",
+                         k+1, vid+1, mesh->vertices[vid].gnum,
+                         inter_edges->abs_lst[j], ds_tol);
+            }
           }
-        }
-        else {
-          for (j = start, k = 0; j < end; j++, k++) {
-            int  vid = inter_edges->vtx_lst[j] - 1;
-            double  ds_tol = mesh->vertices[vid].tolerance/edge_length;
+          else {
+
+            for (j = start, k = 0; j < end; j++, k++) {
+              vid = inter_edges->vtx_lst[j] - 1;
+              if (vid > mesh->n_vertices) {
+                cs_join_mesh_dump(mesh);
+                bft_printf("vid: %d - n_vertices: %d\n",
+                           vid, mesh->n_vertices);
+                bft_error(__FILE__, __LINE__, 0,
+                          _("  Vertex number out of bounds.\n"));
+              }
+            ds_tol = mesh->vertices[vid].tolerance/edge_length;
             bft_printf("   %9u - (%7d, s = %8.6e, ds_tol = %8.6e)\n",
                        k+1, inter_edges->vtx_glst[j],
                        inter_edges->abs_lst[j], ds_tol);
+            }
           }
-        }
+        } /* param.verbosity > 3 */
 #endif
 
         /* Build temporary lists */
@@ -2688,11 +2720,9 @@ cs_join_add_equiv_from_edges(cs_join_param_t               param,
                                     edge_length);
 
         if (n_breaks > 0) {
-
           n_break_counter += 1;
           if (param.verbosity > 2)
             bft_printf(" Edge %8d: n_equiv. broken: %d\n", i+1, n_breaks);
-
         }
 
         n_max_breaks = CS_MAX(n_max_breaks, n_breaks);
@@ -2749,14 +2779,14 @@ cs_join_add_equiv_from_edges(cs_join_param_t               param,
     fvm_gnum_t n_g_break_counter = n_break_counter;
     fvm_parall_counter(&n_g_break_counter, 1);
 
-    bft_printf(_("\n  Equivalences broken for %lu edges.\n"),
-               (unsigned long)n_g_break_counter);
+    bft_printf(_("\n  Equivalences broken for %llu edges.\n"),
+               (unsigned long long)n_g_break_counter);
 
     if (param.verbosity > 1) {
       fvm_lnum_t g_n_max_breaks = n_max_breaks;
       fvm_parall_counter_max(&g_n_max_breaks, 1);
-      bft_printf(_("\n  Max. number of equiv. breaks: %lu\n"),
-                 (unsigned long)g_n_max_breaks);
+      bft_printf(_("\n  Max. number of equiv. breaks: %llu\n"),
+                 (unsigned long long)g_n_max_breaks);
     }
   }
 
@@ -3320,13 +3350,15 @@ cs_join_inter_edges_block_to_part(fvm_gnum_t                    n_g_edges,
  * Add future new vertices for the face definition in cs_join_mesh_t
  *
  * parameters:
+ *   verbosity   <-- verbosity level
  *   edges       <-- cs_join_edges_t structure
  *   mesh        <-> cs_join_mesh_t structure
  *   inter_edges <-> current cs_join_inter_edges_t struct. to work with
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_intersect_update_struct(const cs_join_edges_t   *edges,
+cs_join_intersect_update_struct(int                      verbosity,
+                                const cs_join_edges_t   *edges,
                                 cs_join_mesh_t          *mesh,
                                 cs_join_inter_edges_t  **inter_edges)
 {
@@ -3402,11 +3434,9 @@ cs_join_intersect_update_struct(const cs_join_edges_t   *edges,
       shift = new_inter_edges->index[o_id];
 
       for (j = _inter_edges->index[i]; j < _inter_edges->index[i+1]; j++) {
-
         new_inter_edges->vtx_glst[shift] = _inter_edges->vtx_glst[j];
         new_inter_edges->abs_lst[shift] = _inter_edges->abs_lst[j];
         shift++;
-
       }
 
     }
@@ -3486,8 +3516,10 @@ cs_join_intersect_update_struct(const cs_join_edges_t   *edges,
 
   if (n_new_vertices > 0) {
 
-    bft_printf(_("\n  Add %d new vertices in the %s mesh definition.\n"),
-               n_new_vertices, mesh->name);
+    if (verbosity > 1)
+      bft_printf(_("\n  Add %d new vertices in the %s mesh definition"
+                   " during update of the edge definition.\n"),
+                 n_new_vertices, mesh->name);
 
     BFT_REALLOC(mesh->vertices,
                 n_init_vertices + n_new_vertices,
@@ -3572,13 +3604,15 @@ cs_join_intersect_edges(cs_join_param_t         param,
 
   for (i = 0; i < edge_edge_vis->n_elts; i++) {
 
-    cs_int_t  e1_id = edge_edge_vis->g_elts[i] - 1;
+    int  e1 = edge_edge_vis->g_elts[i]; /* This is a local number */
 
     for (j = edge_edge_vis->index[i]; j < edge_edge_vis->index[i+1]; j++) {
 
-      cs_int_t  e2_id = edge_edge_vis->g_list[j] - 1;
+      int  e2 = edge_edge_vis->g_list[j]; /* This is a local number */
+      int  e1_id = (e1 < e2 ? e1 - 1 : e2 - 1);
+      int  e2_id = (e1 < e2 ? e2 - 1 : e1 - 1);
 
-      assert(e1_id != e2_id);
+      assert(e1 != e2);
 
       /* Get edge-edge intersection */
 
@@ -3785,11 +3819,32 @@ cs_join_intersect_faces(const cs_join_param_t   param,
 
   fvm_neighborhood_destroy(&face_neighborhood);
 
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  {
+    int  len;
+    FILE  *dbg_file = NULL;
+    char  *filename = NULL;
+
+    len = strlen("JoinDBG_FaceVis.dat")+1+2+4;
+    BFT_MALLOC(filename, len, char);
+    sprintf(filename, "Join%02dDBG_FaceVis%04d.dat",
+            param.num, CS_MAX(cs_glob_rank_id, 0));
+    dbg_file = fopen(filename, "w");
+
+    cs_join_gset_dump(dbg_file, face_visibility);
+
+    fflush(dbg_file);
+    BFT_FREE(filename);
+    fclose(dbg_file);
+  }
+#endif /* defined(DEBUG) && !defined(NDEBUG) */
+
   return face_visibility;
 }
 
 /*----------------------------------------------------------------------------
- * Transform face visibility into edge visibility.
+ * Transform face visibility into edge visibility (mesh->face_gnum must be
+ * ordered).
  *
  * parameters:
  *   mesh       <-- pointer to a cs_join_mesh_t structure
@@ -3981,13 +4036,13 @@ cs_join_intersect_face_to_edge(const cs_join_mesh_t   *mesh,
   BFT_FREE(count);
   BFT_FREE(tmp);
 
-  /* Delete redundancies in g_list */
+  /* Delete redundancies in g_elts, order g_elts and compact data */
 
-  cs_join_gset_clean(edge_visib);
+  cs_join_gset_merge_elts(edge_visib, 0); /* 0 = g_elts is not ordered */
 
-  /* Delete redundancies in g_elts and compact data */
+  /* Delete redundancies in g_list */
 
-  cs_join_gset_merge_elts(edge_visib, 0); /* g_elts is not ordered */
+  cs_join_gset_clean(edge_visib);
 
   cs_join_gset_compress(edge_visib);
 
diff --git a/src/base/cs_join_merge.c b/src/base/cs_join_merge.c
index 9a7e04d..7e17162 100644
--- a/src/base/cs_join_merge.c
+++ b/src/base/cs_join_merge.c
@@ -99,9 +99,9 @@ BEGIN_C_DECLS
 
 enum {
 
-  CS_JOIN_MERGE_MAX_GLOB_ITERS = 25,  /* Max. number of glob. iter. for finding
+  CS_JOIN_MERGE_MAX_GLOB_ITERS = 50,  /* Max. number of glob. iter. for finding
                                          equivalent vertices */
-  CS_JOIN_MERGE_MAX_LOC_ITERS = 50    /* Max. number of loc. iter. for finding
+  CS_JOIN_MERGE_MAX_LOC_ITERS = 100   /* Max. number of loc. iter. for finding
                                          equivalent vertices */
 };
 
@@ -219,16 +219,12 @@ _get_new_vertex(float                  curv_abs,
   assert(curv_abs >= 0.0);
   assert(curv_abs <= 1.0);
 
-  /* New global number */
+  /* New vertex features */
 
+  new_vtx_data.state = CS_JOIN_STATE_NEW;
   new_vtx_data.gnum = gnum;
-
-  /* New tolerance */
-
   new_vtx_data.tolerance = (1-curv_abs)*v1.tolerance + curv_abs*v2.tolerance;
 
-  /* New coordinates */
-
   for (k = 0; k < 3; k++)
     new_vtx_data.coord[k] = (1-curv_abs)*v1.coord[k] + curv_abs*v2.coord[k];
 
@@ -273,7 +269,7 @@ _define_inter_tag(fvm_gnum_t  tag[],
  *   work               <-- pointer to a cs_join_mesh_t structure
  *   edges              <-- list of edges
  *   inter_set          <-- structure including data on edge intersections
- *   n_g_vertices       <-- global number of vertices (initial full mesh)
+ *   init_max_vtx_gnum  <-- initial max. global numbering for vertices
  *   n_iwm_vertices     <-- initial local number of vertices (work struct)
  *   n_new_vertices     <-- local number of new vertices to define
  *   p_n_g_new_vertices <-> pointer to the global number of new vertices
@@ -285,7 +281,7 @@ static void
 _compute_new_vertex_gnum(const cs_join_mesh_t       *work,
                          const cs_join_edges_t      *edges,
                          const cs_join_inter_set_t  *inter_set,
-                         fvm_gnum_t                  n_g_vertices,
+                         fvm_gnum_t                  init_max_vtx_gnum,
                          cs_int_t                    n_iwm_vertices,
                          cs_int_t                    n_new_vertices,
                          fvm_gnum_t                 *p_n_g_new_vertices,
@@ -335,7 +331,7 @@ _compute_new_vertex_gnum(const cs_join_mesh_t       *work,
       if (inter1.vtx_id + 1 > n_iwm_vertices)
         _define_inter_tag(&(inter_tag[3*n_new_vertices]),
                           e1_gnum, e2_gnum,
-                          n_g_vertices + 1);
+                          init_max_vtx_gnum + 1);
       else
         _define_inter_tag(&(inter_tag[3*n_new_vertices]),
                           e1_gnum, e2_gnum,
@@ -385,7 +381,7 @@ _compute_new_vertex_gnum(const cs_join_mesh_t       *work,
     global_num = fvm_io_num_get_global_num(new_vtx_io_num);
 
     for (i = 0; i < n_new_vertices; i++)
-      new_vtx_gnum[order[i]] = global_num[i] + n_g_vertices;
+      new_vtx_gnum[order[i]] = global_num[i] + init_max_vtx_gnum;
 
     fvm_io_num_destroy(new_vtx_io_num);
 
@@ -395,7 +391,7 @@ _compute_new_vertex_gnum(const cs_join_mesh_t       *work,
 
     if (n_new_vertices > 0) {
 
-      fvm_gnum_t  new_gnum = n_g_vertices + 1;
+      fvm_gnum_t  new_gnum = init_max_vtx_gnum + 1;
 
       new_vtx_gnum[order[0]] = new_gnum;
 
@@ -519,24 +515,26 @@ _is_spread_not_converged(cs_int_t          n_vertices,
  *  vertex is equal to the minimal global number.
  *
  * parameters:
- *  vtx_eset <-- structure dealing with vertices equivalences
- *  vtx_tag  <-> tag for each vertex
+ *  n_vertices <-- local number of vertices
+ *  vtx_eset   <-- structure dealing with vertices equivalences
+ *  vtx_tag    <-> tag for each vertex
  *---------------------------------------------------------------------------*/
 
 static void
-_spread_tag(const cs_join_eset_t  *vtx_eset,
+_spread_tag(cs_int_t               n_vertices,
+            const cs_join_eset_t  *vtx_eset,
             fvm_gnum_t             vtx_tag[])
 {
-  cs_int_t  i;
-
+  cs_int_t  i, v1_id, v2_id;
+  fvm_gnum_t  v1_gnum, v2_gnum;
   cs_int_t  *equiv_lst = vtx_eset->equiv_couple;
 
   for (i = 0; i < vtx_eset->n_equiv; i++) {
 
-    cs_int_t  v1_id = equiv_lst[2*i] - 1;
-    cs_int_t  v2_id = equiv_lst[2*i+1] - 1;
-    fvm_gnum_t  v1_gnum = vtx_tag[v1_id];
-    fvm_gnum_t  v2_gnum = vtx_tag[v2_id];
+    v1_id = equiv_lst[2*i] - 1, v2_id = equiv_lst[2*i+1] - 1;
+    assert(v1_id < n_vertices);
+    assert(v1_id < n_vertices);
+    v1_gnum = vtx_tag[v1_id], v2_gnum = vtx_tag[v2_id];
 
     if (v1_gnum != v2_gnum) {
 
@@ -571,7 +569,7 @@ _local_spread(const cs_join_eset_t  *vtx_eset,
 
   _loc_merge_counter++;
 
-  _spread_tag(vtx_eset, vtx_tag);
+  _spread_tag(n_vertices, vtx_eset, vtx_tag);
 
   while (_is_spread_not_converged(n_vertices, prev_vtx_tag, vtx_tag)) {
 
@@ -588,7 +586,7 @@ _local_spread(const cs_join_eset_t  *vtx_eset,
     for (i = 0; i < n_vertices; i++)
       prev_vtx_tag[i] = vtx_tag[i];
 
-    _spread_tag(vtx_eset, vtx_tag);
+    _spread_tag(n_vertices, vtx_eset, vtx_tag);
   }
 }
 
@@ -1227,6 +1225,7 @@ _compute_merged_vertex(cs_int_t                n_elts,
 
   /* Initialize cs_join_vertex_t structure */
 
+  mvtx.state = CS_JOIN_STATE_UNDEF;
   mvtx.gnum = set[0].gnum;
   mvtx.tolerance = set[0].tolerance;
 
@@ -1239,8 +1238,9 @@ _compute_merged_vertex(cs_int_t                n_elts,
 
     mvtx.tolerance = CS_MIN(set[i].tolerance, mvtx.tolerance);
     mvtx.gnum = CS_MIN(set[i].gnum, mvtx.gnum);
+    mvtx.state = CS_MAX(set[i].state, mvtx.state);
 
-  /* Compute the resulting coordinates of the merged vertices */
+    /* Compute the resulting coordinates of the merged vertices */
 
 #if CS_JOIN_MERGE_INV_TOL
     w = 1.0/set[i].tolerance;
@@ -1251,11 +1251,17 @@ _compute_merged_vertex(cs_int_t                n_elts,
 
     for (k = 0; k < 3; k++)
       mvtx.coord[k] += w * set[i].coord[k];
+
   }
 
   for (k = 0; k < 3; k++)
     mvtx.coord[k] /= denum;
 
+  if (mvtx.state == CS_JOIN_STATE_ORIGIN)
+    mvtx.state = CS_JOIN_STATE_MERGE;
+  else if (mvtx.state == CS_JOIN_STATE_PERIO)
+    mvtx.state = CS_JOIN_STATE_PERIO_MERGE;
+
   return mvtx;
 }
 
@@ -1428,8 +1434,8 @@ _pre_merge(cs_join_param_t     param,
     fvm_gnum_t n_g_counter = n_local_pre_merge;
     fvm_parall_counter(&n_g_counter, 1);
 
-    bft_printf(_("\n  Pre-merge for %lu global couple of elements.\n"),
-               (unsigned long)n_g_counter);
+    bft_printf(_("\n  Pre-merge for %llu global couple of elements.\n"),
+               (unsigned long long)n_g_counter);
 
     if (param.verbosity > 1) {
       bft_printf(_("\n  Local number of pre-merge: %d\n"),
@@ -1578,7 +1584,7 @@ _build_subsets(cs_int_t          set_size,
 
   }
 
-#if 1 && defined(DEBUG) && !defined(NDEBUG)
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
   if (n_loops >= CS_JOIN_MERGE_MAX_LOC_ITERS)
     bft_printf("WARNING max sub_loops to build subset reached\n");
 #endif
@@ -2038,12 +2044,13 @@ _merge_vertices(cs_join_param_t    param,
     fvm_parall_counter_max(&g_max_list_size, 1);
 
     if (g_max_list_size < 2) {
+      cs_join_gset_destroy(&equiv_gnum);
       bft_printf(_("\n  No need to merge vertices.\n"));
       return;
     }
     else
-      bft_printf(_("\n  Max size of a merge set of vertices: %lu\n"),
-                 (unsigned long)g_max_list_size);
+      bft_printf(_("\n  Max size of a merge set of vertices: %llu\n"),
+                 (unsigned long long)g_max_list_size);
   }
 
   /* Temporary buffers allocation */
@@ -2174,14 +2181,14 @@ _merge_vertices(cs_join_param_t    param,
     fvm_gnum_t n_g_counter = n_transitivity;
     fvm_parall_counter(&n_g_counter, 1);
 
-    bft_printf(_("\n  Excessive transitivity for %lu set(s) of vertices.\n"),
-               (unsigned long)n_g_counter);
+    bft_printf(_("\n  Excessive transitivity for %llu set(s) of vertices.\n"),
+               (unsigned long long)n_g_counter);
 
     if (verbosity > 1) {
       fvm_lnum_t g_n_max_loops = n_max_loops;
       fvm_parall_counter_max(&g_n_max_loops, 1);
       bft_printf(_("\n  Max. number of iterations to solve transitivity"
-                   " excess: %lu\n"), (unsigned long)g_n_max_loops);
+                   " excess: %llu\n"), (unsigned long long)g_n_max_loops);
     }
   }
 
@@ -2201,54 +2208,45 @@ _merge_vertices(cs_join_param_t    param,
  * operation.
  *
  * parameters:
- *   n_iwm_vertices   <-- number of vertices before intersection for the work
- *                        cs_join_mesh_t structure
- *   n_g_ifm_vertices <-- global number of vertices on the initial full mesh
- *   iwm_vtx_gnum     <-- initial global vertex num. (work mesh struct.)
- *   n_vertices       <-- number of vertices before merge/after intersection
- *   vertices         <-- array of cs_join_vertex_t structures
- *   p_o2n_vtx_gnum   --> distributed array by block on the new global vertex
- *                        numbering for the initial vertices (before inter.)
+ *   n_iwm_vertices    <-- number of vertices before intersection for the
+ *                          work cs_join_mesh_t structure
+ *   iwm_vtx_gnum      <-- initial global vertex num. (work mesh struct.)
+ *   init_max_vtx_gnum <-- initial max. global numbering for vertices
+ *   n_vertices        <-- number of vertices before merge/after intersection
+ *   vertices          <-- array of cs_join_vertex_t structures
+ *   p_o2n_vtx_gnum    --> distributed array by block on the new global vertex
+ *                         numbering for the initial vertices (before inter.)
  *---------------------------------------------------------------------------*/
 
 static void
 _keep_global_vtx_evolution(cs_int_t                n_iwm_vertices,
-                           fvm_gnum_t              n_g_ifm_vertices,
                            const fvm_gnum_t        iwm_vtx_gnum[],
+                           fvm_gnum_t              init_max_vtx_gnum,
                            cs_int_t                n_vertices,
                            const cs_join_vertex_t  vertices[],
                            fvm_gnum_t             *p_o2n_vtx_gnum[])
 {
   cs_int_t  i;
-  cs_join_block_info_t  block_info;
 
-  int  n_ranks = cs_glob_n_ranks;
   fvm_gnum_t  *o2n_vtx_gnum = NULL;
 
+  const int  n_ranks = cs_glob_n_ranks;
   const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
 
   assert(n_iwm_vertices <= n_vertices); /* after inter. >= init */
 
-  block_info = cs_join_get_block_info(n_g_ifm_vertices,
-                                      n_ranks,
-                                      local_rank);
-
-  BFT_MALLOC(o2n_vtx_gnum, block_info.local_size, fvm_gnum_t);
-
   if (n_ranks == 1) {
 
+    BFT_MALLOC(o2n_vtx_gnum, n_iwm_vertices, fvm_gnum_t);
+
     for (i = 0; i < n_iwm_vertices; i++)
       o2n_vtx_gnum[i] = vertices[i].gnum;
 
-    /* Return pointer */
-
-    *p_o2n_vtx_gnum = o2n_vtx_gnum;
-
-    return;
   }
 
 #if defined(HAVE_MPI) /* Parallel treatment */
-  {
+  if (n_ranks > 1) {
+
     fvm_gnum_t  ii;
     cs_int_t  shift, rank, n_recv_elts;
 
@@ -2256,10 +2254,16 @@ _keep_global_vtx_evolution(cs_int_t                n_iwm_vertices,
     cs_int_t  *send_count = NULL, *recv_count = NULL;
     fvm_gnum_t  *send_glist = NULL, *recv_glist = NULL;
 
+    cs_join_block_info_t  block_info = cs_join_get_block_info(init_max_vtx_gnum,
+                                                              n_ranks,
+                                                              local_rank);
+
     MPI_Comm  mpi_comm = cs_glob_mpi_comm;
 
     /* Initialize o2n_vtx_gnum */
 
+    BFT_MALLOC(o2n_vtx_gnum, block_info.local_size, fvm_gnum_t);
+
     for (ii = 0; ii < block_info.local_size; ii++)
       o2n_vtx_gnum[ii] = block_info.first_gnum + ii;
 
@@ -2989,7 +2993,7 @@ _redistribute_mesh(const fvm_gnum_t        gnum_rank_index[],
  *   work               <-> joining mesh maintaining initial vertex data
  *   inter_set          <-> cs_join_inter_set_t structure including
  *                          data on edge-edge  intersections
- *   n_g_vertices       <-- global number of vertices (initial parent mesh)
+ *   init_max_vtx_gnum  <-- initial max. global numbering for vertices
  *   p_n_g_new_vertices <-> pointer to the global number of new vertices
  *   p_vtx_eset         <-> pointer to a structure dealing with vertex
  *                          equivalences
@@ -3000,7 +3004,7 @@ cs_join_create_new_vertices(int                     verbosity,
                             const cs_join_edges_t  *edges,
                             cs_join_mesh_t         *work,
                             cs_join_inter_set_t    *inter_set,
-                            fvm_gnum_t              n_g_vertices,
+                            fvm_gnum_t              init_max_vtx_gnum,
                             fvm_gnum_t             *p_n_g_new_vertices,
                             cs_join_eset_t        **p_vtx_eset)
 {
@@ -3042,15 +3046,15 @@ cs_join_create_new_vertices(int                     verbosity,
   _compute_new_vertex_gnum(work,
                            edges,
                            inter_set,
-                           n_g_vertices,
+                           init_max_vtx_gnum,
                            n_iwm_vertices,
                            n_new_vertices,
                            &n_g_new_vertices,
                            &new_vtx_gnum);
 
   if (verbosity > 0)
-    bft_printf(_("\n  Global number of new vertices to create: %10lu\n"),
-               (unsigned long)n_g_new_vertices);
+    bft_printf(_("\n  Global number of new vertices to create: %10llu\n"),
+               (unsigned long long)n_g_new_vertices);
 
   /* Define new vertices */
 
@@ -3070,6 +3074,7 @@ cs_join_create_new_vertices(int                     verbosity,
     incoherency.coord[1] = -9999.9999;
     incoherency.coord[2] = -9999.9999;
     incoherency.tolerance = -1.0;
+    incoherency.state = CS_JOIN_STATE_UNDEF;
 
     for (i = 0; i < n_new_vertices; i++)
       work->vertices[n_iwm_vertices + i] = incoherency;
@@ -3219,8 +3224,8 @@ cs_join_merge_vertices(cs_join_param_t        param,
     fvm_parall_counter(&g_n_equiv, 1);
     bft_printf(_("\n"
                  "  Final number of equiv. between vertices; local: %9d\n"
-                 "                                          global: %9lu\n"),
-               vtx_eset->n_equiv, (unsigned long)g_n_equiv);
+                 "                                          global: %9llu\n"),
+               vtx_eset->n_equiv, (unsigned long long)g_n_equiv);
   }
 
   /* Operate merge between equivalent vertices.
@@ -3321,8 +3326,8 @@ cs_join_merge_vertices(cs_join_param_t        param,
  * parameters:
  *   param                <-- set of user-defined parameters for the joining
  *   n_iwm_vertices       <-- initial number of vertices (work mesh struct.)
- *   n_g_ifm_vertices     <-- initial global number of vertices (full mesh)
  *   iwm_vtx_gnum         <-- initial global vertex num. (work mesh struct)
+ *   init_max_vtx_gnum    <-- initial max. global numbering for vertices
  *   rank_face_gnum_index <-- index on face global numbering to determine
  *                            the related rank
  *   p_mesh               <-> pointer to cs_join_mesh_t structure
@@ -3336,8 +3341,8 @@ cs_join_merge_vertices(cs_join_param_t        param,
 void
 cs_join_merge_update_struct(cs_join_param_t          param,
                             cs_int_t                 n_iwm_vertices,
-                            fvm_gnum_t               n_g_ifm_vertices,
                             const fvm_gnum_t         iwm_vtx_gnum[],
+                            fvm_gnum_t               init_max_vtx_gnum,
                             const fvm_gnum_t         rank_face_gnum_index[],
                             cs_join_mesh_t         **p_mesh,
                             cs_join_edges_t        **p_edges,
@@ -3356,8 +3361,8 @@ cs_join_merge_update_struct(cs_join_param_t          param,
   /* Keep an history of the evolution of each vertex */
 
   _keep_global_vtx_evolution(n_iwm_vertices,   /* n_vertices before inter */
-                             n_g_ifm_vertices,
                              iwm_vtx_gnum,
+                             init_max_vtx_gnum,
                              mesh->n_vertices, /* n_vertices after inter */
                              mesh->vertices,
                              &o2n_vtx_gnum);   /* defined by block in // */
@@ -3414,15 +3419,6 @@ cs_join_merge_update_struct(cs_join_param_t          param,
                      mesh,
                      &local_mesh);
 
-  /* Clean mesh: remove degenerate and empty edges */
-
-  cs_join_mesh_clean(mesh, param.verbosity);
-
-  /* Define a new cs_join_edges_t structure */
-
-  cs_join_mesh_destroy_edges(&edges);
-  edges = cs_join_mesh_define_edges(mesh);
-
   /* Set return pointers */
 
   *p_mesh = mesh;
diff --git a/src/base/cs_join_mesh.c b/src/base/cs_join_mesh.c
index 93d6f00..777e704 100644
--- a/src/base/cs_join_mesh.c
+++ b/src/base/cs_join_mesh.c
@@ -3,7 +3,7 @@
  *     This file is part of the Code_Saturne Kernel, element of the
  *     Code_Saturne CFD tool.
  *
- *     Copyright (C) 2008-2009 EDF S.A., France
+ *     Copyright (C) 2008-2010 EDF S.A., France
  *
  *     contact: saturne-support at edf.fr
  *
@@ -23,7 +23,7 @@
  *     51 Franklin St, Fifth Floor,
  *     Boston, MA  02110-1301  USA
  *
- *============================================================================*/
+ *===========================================================================*/
 
 /*============================================================================
  * Manipulation of a cs_join_mesh_t structure
@@ -89,6 +89,37 @@ BEGIN_C_DECLS
  *===========================================================================*/
 
 /*----------------------------------------------------------------------------
+ * Return a string related to a state
+ *
+ * parameters:
+ *   state <-- state to display
+ *
+ * returns:
+ *   related string
+ *---------------------------------------------------------------------------*/
+
+static const char *
+_print_state(cs_join_state_t  state)
+{
+  if (state == CS_JOIN_STATE_UNDEF)
+    return "UDF";
+  else if (state == CS_JOIN_STATE_NEW)
+    return "NEW";
+  else if (state == CS_JOIN_STATE_ORIGIN)
+    return "ORI";
+  else if (state == CS_JOIN_STATE_PERIO)
+    return "PER";
+  else if (state == CS_JOIN_STATE_MERGE)
+    return "MRG";
+  else if (state == CS_JOIN_STATE_PERIO_MERGE)
+    return "PMG";
+  else if (state == CS_JOIN_STATE_SPLIT)
+    return "SPL";
+  else
+    return "ERR";
+}
+
+/*----------------------------------------------------------------------------
  * Compute the cross product of two vectors.
  *
  * parameters:
@@ -97,7 +128,7 @@ BEGIN_C_DECLS
  *
  * returns:
  *   the resulting cross product (v1 x v2)
- *----------------------------------------------------------------------------*/
+ *---------------------------------------------------------------------------*/
 
 inline static void
 _cross_product(const double  v1[],
@@ -118,7 +149,7 @@ _cross_product(const double  v1[],
  *
  * returns:
  *   the resulting dot product (v1.v2)
- *----------------------------------------------------------------------------*/
+ *---------------------------------------------------------------------------*/
 
 inline static double
 _dot_product(const double  v1[],
@@ -133,9 +164,625 @@ _dot_product(const double  v1[],
   return result;
 }
 
+/*----------------------------------------------------------------------------
+ * Get the norm of a vector.
+ *
+ * parameters:
+ *  v      <->  vector to work with.
+ *---------------------------------------------------------------------------*/
+
+inline static double
+_norm(double   v[])
+{
+  return  sqrt(_dot_product(v, v));
+}
+
+/*----------------------------------------------------------------------------
+ * Compute the distance between two vertices.
+ *
+ * parameters:
+ *   id         <-- local id of the vertex to deal with
+ *   quantities <-- array keeping edge vector and its length
+ *
+ * returns:
+ *   sine in radians between edges sharing vertex id
+ *---------------------------------------------------------------------------*/
+
+inline static double
+_compute_sine(int           id,
+              const double  quantities[])
+{
+  int  i;
+
+  double  sine;
+  double  norm_a, norm_b, a[3], b[3], c[3];
+
+  for (i = 0; i < 3; i++) {
+    a[i] = -quantities[4*id+i];
+    b[i] = quantities[4*(id+1)+i];
+  }
+
+  norm_a = quantities[4*id+3];
+  norm_b = quantities[4*(id+1)+3];
+
+  _cross_product(a, b, c);
+
+  sine = _norm(c) / (norm_a * norm_b);
+
+  return sine;
+}
+
+/*----------------------------------------------------------------------------
+ * Compute the distance between two vertices.
+ *
+ * parameters:
+ *   a <-- coordinates of the first vertex.
+ *   b <-- coordinates of the second vertex.
+ *
+ * returns:
+ *   distance between a and b.
+ *---------------------------------------------------------------------------*/
+
+inline static double
+_compute_length(const double  a[3],
+                const double  b[3])
+{
+  double  length;
+
+  length = sqrt(  (b[0] - a[0])*(b[0] - a[0])
+                + (b[1] - a[1])*(b[1] - a[1])
+                + (b[2] - a[2])*(b[2] - a[2]));
+
+  return length;
+}
+
+/*----------------------------------------------------------------------------
+ * Compute tolerance (mode 2)
+ * tolerance = min[ edge length * sine(v1v2) * fraction]
+ *
+ * parameters:
+ *   vertex_coords    <--  coordinates of vertices.
+ *   vertex_tolerance <->  local tolerance affected to each vertex and
+ *                         to be updated
+ *   n_faces          <--  number of selected faces
+ *   face_lst         <--  list of faces selected to compute the tolerance
+ *   f2v_idx          <--  "face -> vertex" connect. index
+ *   f2v_lst          <--  "face -> vertex" connect. list
+ *   fraction         <--  parameter used to compute the tolerance
+ *---------------------------------------------------------------------------*/
+
+static void
+_compute_tolerance2(const cs_real_t   vtx_coords[],
+                    double            vtx_tolerance[],
+                    const cs_int_t    n_faces,
+                    const cs_int_t    face_lst[],
+                    const cs_int_t    f2v_idx[],
+                    const cs_int_t    f2v_lst[],
+                    double            fraction)
+{
+  int  i, j, k, coord;
+  double  tolerance, sine;
+  double  a[3], b[3];
+
+  int   n_max_face_vertices = 0;
+  int  *face_connect = NULL;
+  double  *edge_quantities = NULL;
+
+  for (i = 0; i < n_faces; i++) {
+    int  fid = face_lst[i] - 1;
+    n_max_face_vertices = CS_MAX(n_max_face_vertices,
+                                 f2v_idx[fid+1] - f2v_idx[fid]);
+  }
+
+  BFT_MALLOC(face_connect, n_max_face_vertices + 1, int);
+  BFT_MALLOC(edge_quantities, 4 * (n_max_face_vertices + 1), double);
+
+  for (i = 0; i < n_faces; i++) {
+
+    int  face_id = face_lst[i] - 1;
+    int  start = f2v_idx[face_id] - 1;
+    int  end = f2v_idx[face_id + 1] - 1;
+    int  n_face_vertices = end - start;
+
+    /* Keep face connect */
+
+    for (k = 0, j = start; j < end; j++, k++)
+      face_connect[k] = f2v_lst[j] - 1;
+    face_connect[k] = f2v_lst[start] - 1;
+
+    /* Keep edge lengths and edge vectors:
+        - edge_quantities[4*k+0..2] = edge vector
+        - edge_quantities[4*k+3] = edge length */
+
+    for (k = 0; k < n_face_vertices; k++) {
+
+      for (coord = 0; coord < 3; coord++) {
+        a[coord] = vtx_coords[3*face_connect[k] + coord];
+        b[coord] = vtx_coords[3*face_connect[k+1] + coord];
+        edge_quantities[4*(k+1)+coord] = b[coord] - a[coord];
+      }
+      edge_quantities[4*(k+1)+3] = _compute_length(a, b);
+
+    }
+
+    for (coord = 0; coord < 4; coord++)
+      edge_quantities[coord] = edge_quantities[4*k+coord];
+
+    /* Loop on the vertices of the face to update tolerance on
+       each vertex */
+
+    for (k = 0; k < n_face_vertices; k++) {
+
+      int  vid = face_connect[k];
+
+      tolerance = fraction * CS_MIN(edge_quantities[4*k+3],
+                                    edge_quantities[4*(k+1)+3]);
+      sine = _compute_sine(k, edge_quantities);
+
+      vtx_tolerance[vid] = FVM_MIN(vtx_tolerance[vid], sine*tolerance);
+
+    }
+
+  } /* End of loop on faces */
+
+  BFT_FREE(face_connect);
+  BFT_FREE(edge_quantities);
+
+}
+
+/*----------------------------------------------------------------------------
+ * Compute tolerance (mode 1)
+ * tolerance = shortest edge length * fraction
+ *
+ * parameters:
+ *   vertex_coords    <--  coordinates of vertices.
+ *   vertex_tolerance <->  local tolerance affected to each vertex and
+ *                         to be updated
+ *   n_faces          <--  number of selected faces
+ *   face_lst         <--  list of faces selected to compute the tolerance
+ *   face_vtx_idx     <--  "face -> vertex" connect. index
+ *   face_vtx_lst     <--  "face -> vertex" connect. list
+ *   fraction         <--  parameter used to compute the tolerance
+ *---------------------------------------------------------------------------*/
+
+static void
+_compute_tolerance1(const cs_real_t   vtx_coords[],
+                    double            vtx_tolerance[],
+                    const cs_int_t    n_faces,
+                    const cs_int_t    face_lst[],
+                    const cs_int_t    face_vtx_idx[],
+                    const cs_int_t    face_vtx_lst[],
+                    double            fraction)
+{
+  cs_int_t  i, j, k, start, end, face_id, vtx_id1, vtx_id2;
+  double  length, tolerance;
+  double  a[3], b[3];
+
+  for (i = 0; i < n_faces; i++) {
+
+    face_id = face_lst[i] - 1;
+    start = face_vtx_idx[face_id] - 1;
+    end = face_vtx_idx[face_id + 1] - 1;
+
+    /* Loop on the vertices of the face */
+
+    for (j = start; j < end - 1; j++) {
+
+      vtx_id1 = face_vtx_lst[j] - 1;
+      vtx_id2 = face_vtx_lst[j+1] - 1;
+
+      for (k = 0; k < 3; k++) {
+        a[k] = vtx_coords[3*vtx_id1 + k];
+        b[k] = vtx_coords[3*vtx_id2 + k];
+      }
+
+      length = _compute_length(a, b);
+      tolerance = length * fraction;
+      vtx_tolerance[vtx_id1] = FVM_MIN(vtx_tolerance[vtx_id1], tolerance);
+      vtx_tolerance[vtx_id2] = FVM_MIN(vtx_tolerance[vtx_id2], tolerance);
+
+    }
+
+    /* Case end - start */
+
+    vtx_id1 = face_vtx_lst[end-1] - 1;
+    vtx_id2 = face_vtx_lst[start] - 1;
+
+    for (k = 0; k < 3; k++) {
+      a[k] = vtx_coords[3*vtx_id1 + k];
+      b[k] = vtx_coords[3*vtx_id2 + k];
+    }
+
+    length = _compute_length(a, b);
+    tolerance = length * fraction;
+    vtx_tolerance[vtx_id1] = FVM_MIN(vtx_tolerance[vtx_id1], tolerance);
+    vtx_tolerance[vtx_id2] = FVM_MIN(vtx_tolerance[vtx_id2], tolerance);
+
+  } /* End of loop on faces */
+
+}
+
+/*----------------------------------------------------------------------------
+ * Define for each vertex a tolerance which is the radius of the
+ * sphere in which the vertex can be fused with another vertex.
+ * This tolerance is computed from the given list of faces (interior or border)
+ *
+ * parameters:
+ *   param            <--  set of user-defined parameters for the joining
+ *   vertex_coords    <--  coordinates of vertices.
+ *   n_faces          <--  number of selected faces
+ *   face_lst         <--  list of faces selected to compute the tolerance
+ *   face_vtx_idx     <--  "face -> vertex" connect. index
+ *   face_vtx_lst     <--  "face -> vertex" connect. list
+ *   vertex_tolerance <->  local tolerance affected to each vertex and
+ *                         to be updated
+ *---------------------------------------------------------------------------*/
+
+static void
+_get_local_tolerance(cs_join_param_t  param,
+                     const cs_real_t  vtx_coords[],
+                     const cs_int_t   n_faces,
+                     const cs_int_t   face_lst[],
+                     const cs_int_t   face_vtx_idx[],
+                     const cs_int_t   face_vtx_lst[],
+                     double           vtx_tolerance[])
+{
+
+  if (param.tcm % 10 == 1) {
+
+    /* tol = min(edge length * fraction) */
+
+    _compute_tolerance1(vtx_coords,
+                        vtx_tolerance,
+                        n_faces,
+                        face_lst,
+                        face_vtx_idx,
+                        face_vtx_lst,
+                        param.fraction);
+
+  }
+  else if (param.tcm % 10 == 2) {
+
+    /* tol = min(edge length * sin(v1v2) * fraction) */
+
+    _compute_tolerance2(vtx_coords,
+                        vtx_tolerance,
+                        n_faces,
+                        face_lst,
+                        face_vtx_idx,
+                        face_vtx_lst,
+                        param.fraction);
+
+  }
+  else
+    bft_error(__FILE__, __LINE__, 0,
+              _("  Tolerance computation mode (%d) is not defined\n"));
+
+}
+
 #if defined(HAVE_MPI)
 
 /*----------------------------------------------------------------------------
+ * Exchange local vertex tolerances to get a global vertex tolerance.
+ *
+ * parameters:
+ *   n_vertices        <-- number of local selected vertices
+ *   select_vtx_io_num <-- fvm_io_num_t structure for the selected vertices
+ *   vertex_data       <-> data associated to each selected vertex
+ *---------------------------------------------------------------------------*/
+
+static void
+_get_global_tolerance(cs_int_t             n_vertices,
+                      const fvm_io_num_t  *select_vtx_io_num,
+                      cs_join_vertex_t     vtx_data[])
+{
+  cs_int_t  i, rank, vtx_id, block_size, shift;
+  fvm_gnum_t  first_vtx_gnum;
+
+  double  *g_vtx_tolerance = NULL, *send_list = NULL, *recv_list = NULL;
+  cs_int_t  *send_count = NULL, *recv_count = NULL;
+  cs_int_t  *send_shift = NULL, *recv_shift = NULL;
+  fvm_gnum_t  *send_glist = NULL, *recv_glist = NULL;
+  fvm_gnum_t  n_g_vertices = fvm_io_num_get_global_count(select_vtx_io_num);
+  const fvm_gnum_t  *io_gnum = fvm_io_num_get_global_num(select_vtx_io_num);
+
+  MPI_Comm  mpi_comm = cs_glob_mpi_comm;
+  const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
+  const int  n_ranks = cs_glob_n_ranks;
+
+  /* Define a fvm_io_num_t structure on vertices */
+
+  block_size = n_g_vertices / n_ranks;
+  if (n_g_vertices % n_ranks > 0)
+    block_size += 1;
+
+  /* Count the number of vertices to send to each rank */
+  /* ------------------------------------------------- */
+
+  BFT_MALLOC(send_count, n_ranks, int);
+  BFT_MALLOC(recv_count, n_ranks, int);
+  BFT_MALLOC(send_shift, n_ranks + 1, int);
+  BFT_MALLOC(recv_shift, n_ranks + 1, int);
+
+  send_shift[0] = 0;
+  recv_shift[0] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++)
+    send_count[rank] = 0;
+
+  for (i = 0; i < n_vertices; i++) {
+    rank = (io_gnum[i] - 1)/block_size;
+    send_count[rank] += 1;
+  }
+
+  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, mpi_comm);
+
+  for (rank = 0; rank < n_ranks; rank++) {
+    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
+    recv_shift[rank + 1] = recv_shift[rank] + recv_count[rank];
+  }
+
+  assert(send_shift[n_ranks] == n_vertices);
+
+  /* Send the global numbering for each vertex */
+  /* ----------------------------------------- */
+
+  BFT_MALLOC(send_glist, n_vertices, fvm_gnum_t);
+  BFT_MALLOC(recv_glist, recv_shift[n_ranks], fvm_gnum_t);
+
+  for (rank = 0; rank < n_ranks; rank++)
+    send_count[rank] = 0;
+
+  for (i = 0; i < n_vertices; i++) {
+    rank = (io_gnum[i] - 1)/block_size;
+    shift = send_shift[rank] + send_count[rank];
+    send_count[rank] += 1;
+    send_glist[shift] = io_gnum[i];
+  }
+
+  MPI_Alltoallv(send_glist, send_count, send_shift, FVM_MPI_GNUM,
+                recv_glist, recv_count, recv_shift, FVM_MPI_GNUM, mpi_comm);
+
+  /* Send the vertex tolerance for each vertex */
+  /* ----------------------------------------- */
+
+  BFT_MALLOC(send_list, n_vertices, double);
+  BFT_MALLOC(recv_list, recv_shift[n_ranks], double);
+
+  for (rank = 0; rank < n_ranks; rank++)
+    send_count[rank] = 0;
+
+  for (i = 0; i < n_vertices; i++) {
+    rank = (io_gnum[i] - 1)/block_size;
+    shift = send_shift[rank] + send_count[rank];
+    send_count[rank] += 1;
+    send_list[shift] = vtx_data[i].tolerance;
+  }
+
+  MPI_Alltoallv(send_list, send_count, send_shift, MPI_DOUBLE,
+                recv_list, recv_count, recv_shift, MPI_DOUBLE, mpi_comm);
+
+  /* Define the global tolerance array */
+
+  BFT_MALLOC(g_vtx_tolerance, block_size, double);
+
+  for (i = 0; i < block_size; i++)
+    g_vtx_tolerance[i] = DBL_MAX;
+
+  first_vtx_gnum = block_size * local_rank + 1;
+
+  for (i = 0; i < recv_shift[n_ranks]; i++) {
+    vtx_id = recv_glist[i] - first_vtx_gnum;
+    g_vtx_tolerance[vtx_id] = FVM_MIN(g_vtx_tolerance[vtx_id], recv_list[i]);
+  }
+
+  /* Replace local vertex tolerance by the new computed global tolerance */
+
+  for (i = 0; i < recv_shift[n_ranks]; i++) {
+    vtx_id = recv_glist[i] - first_vtx_gnum;
+    recv_list[i] = g_vtx_tolerance[vtx_id];
+  }
+
+  MPI_Alltoallv(recv_list, recv_count, recv_shift, MPI_DOUBLE,
+                send_list, send_count, send_shift, MPI_DOUBLE, mpi_comm);
+
+  for (rank = 0; rank < n_ranks; rank++)
+    send_count[rank] = 0;
+
+  for (i = 0; i < n_vertices; i++) {
+    rank = (io_gnum[i] - 1)/block_size;
+    shift = send_shift[rank] + send_count[rank];
+    send_count[rank] += 1;
+    vtx_data[i].tolerance = send_list[shift];
+  }
+
+  /* Free memory */
+
+  BFT_FREE(recv_glist);
+  BFT_FREE(send_glist);
+  BFT_FREE(send_list);
+  BFT_FREE(recv_list);
+  BFT_FREE(recv_count);
+  BFT_FREE(send_count);
+  BFT_FREE(recv_shift);
+  BFT_FREE(send_shift);
+  BFT_FREE(g_vtx_tolerance);
+}
+#endif /* HAVE_MPI */
+
+/*----------------------------------------------------------------------------
+ * Define for each vertex a tolerance which is the radius of the
+ * sphere in which the vertex can be fused with another vertex.
+ * This tolerance is computed from the given list of faces (interior or border)
+ *
+ * parameters:
+ *   param        <-- set of user-defined parameters for the joining
+ *   selection    <-- pointer to a struct. keeping selected entities
+ *   b_f2v_idx    <-- border "face -> vertex" connectivity index
+ *   b_f2v_lst    <-- border "face -> vertex" connectivity
+ *   i_f2v_idx    <-- interior "face -> vertex" connectivity index
+ *   i_f2v_lst    <-- interior "face -> vertex" connectivity
+ *   n_vertices   <-- number of vertices in the parent mesh
+ *   vtx_coord    <-- coordinates of vertices in parent mesh
+ *   vtx_gnum     <-- global numbering of vertices
+ *
+ * returns:
+ *  a pointer to an array of cs_join_vertex_t
+ *---------------------------------------------------------------------------*/
+
+static cs_join_vertex_t *
+_define_vertices(cs_join_param_t        param,
+                 cs_join_select_t      *selection,
+                 const cs_int_t         b_f2v_idx[],
+                 const cs_int_t         b_f2v_lst[],
+                 const cs_int_t         i_f2v_idx[],
+                 const cs_int_t         i_f2v_lst[],
+                 const cs_int_t         n_vertices,
+                 const cs_real_t        vtx_coord[],
+                 const fvm_gnum_t       vtx_gnum[])
+{
+  int  i;
+
+  cs_join_vertex_t  *vertices = NULL;
+
+  const int  n_ranks = cs_glob_n_ranks;
+
+  /*
+     Define a tolerance around each vertex in the selection list.
+     Tolerance is the radius of the sphere in which the vertex can be merged
+     with another vertex. Radius is the min(fraction * edge_length) on all
+     edges connected to a vertex.
+     Store all data about a vertex in a cs_join_vertex_t structure.
+  */
+
+  if (selection->n_vertices > 0) {
+
+    /* Initialize vertices array */
+
+    BFT_MALLOC(vertices, selection->n_vertices, cs_join_vertex_t);
+
+    for (i = 0; i < selection->n_vertices; i++) {
+
+      cs_int_t  vtx_id = selection->vertices[i]-1;
+
+      if (n_ranks > 1)
+        vertices[i].gnum = vtx_gnum[vtx_id];
+      else
+        vertices[i].gnum = vtx_id + 1;
+
+      vertices[i].coord[0] = vtx_coord[3*vtx_id];
+      vertices[i].coord[1] = vtx_coord[3*vtx_id+1];
+      vertices[i].coord[2] = vtx_coord[3*vtx_id+2];
+      vertices[i].tolerance = 0.0;                  /* Default value */
+      vertices[i].state = CS_JOIN_STATE_ORIGIN;     /* Default value */
+
+    }
+
+
+    /* Compute the tolerance for each vertex of the mesh */
+
+    if (param.fraction > 0.0) {
+
+      double  *vtx_tolerance = NULL;
+
+      BFT_MALLOC(vtx_tolerance, n_vertices, double);
+
+      for (i = 0; i < n_vertices; i++)
+        vtx_tolerance[i] = DBL_MAX;
+
+      /* Define local tolerance */
+
+      _get_local_tolerance(param,
+                           vtx_coord,
+                           selection->n_faces,
+                           selection->faces,
+                           b_f2v_idx,
+                           b_f2v_lst,
+                           vtx_tolerance);
+
+      if (param.tcm / 10 == 0) {
+
+        /* Update local tolerance with adjacent border faces */
+
+        _get_local_tolerance(param,
+                             vtx_coord,
+                             selection->n_b_adj_faces,
+                             selection->b_adj_faces,
+                             b_f2v_idx,
+                             b_f2v_lst,
+                             vtx_tolerance);
+
+        /* Update local tolerance with adjacent interior faces */
+
+        _get_local_tolerance(param,
+                             vtx_coord,
+                             selection->n_i_adj_faces,
+                             selection->i_adj_faces,
+                             i_f2v_idx,
+                             i_f2v_lst,
+                             vtx_tolerance);
+
+      } /* Include adjacent faces in the computation of the vertex tolerance */
+
+      for (i = 0; i < selection->n_vertices; i++)
+        vertices[i].tolerance = vtx_tolerance[selection->vertices[i]-1];
+
+      BFT_FREE(vtx_tolerance);
+
+    } /* End if tolerance > 0.0 */
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)   /* Sanity check */
+  for (i = 0; i < selection->n_vertices; i++)
+    if (vertices[i].tolerance > (DBL_MAX - 1.))
+      bft_error(__FILE__, __LINE__, 0,
+                _("Incompatible value for the \"vertex tolerance\" item\n"
+                  "Value must be lower than DBL_MAX and current value is : %f"
+                  " (global numbering : %u)\n"),
+                vertices[i].tolerance, vertices[i].gnum);
+#endif
+
+  } /* End if selection->n_vertices > 0 */
+
+#if defined(HAVE_MPI)
+  if (n_ranks > 1) { /* Parallel treatment : synchro over the ranks */
+
+    /* Global number of selected vertices and associated
+       fvm_io_num_t structure */
+
+    fvm_io_num_t  *select_vtx_io_num = fvm_io_num_create(selection->vertices,
+                                                         vtx_gnum,
+                                                         selection->n_vertices,
+                                                         0);
+
+    selection->n_g_vertices = fvm_io_num_get_global_count(select_vtx_io_num);
+
+    _get_global_tolerance(selection->n_vertices,
+                          select_vtx_io_num,
+                          vertices);
+
+    if (param.verbosity > 1)
+      bft_printf(_("  Global number of selected vertices: %11llu\n\n"),
+                 (unsigned long long)(selection->n_g_vertices));
+
+    fvm_io_num_destroy(select_vtx_io_num);
+
+  }
+#endif /* defined(HAVE_MPI) */
+
+  if (n_ranks == 1) {
+    selection->n_g_vertices = selection->n_vertices;
+
+    if (param.verbosity > 1)
+      bft_printf(_("  Number of selected vertices: %11llu\n\n"),
+                 (unsigned long long)(selection->n_g_vertices));
+
+  }
+
+  return vertices;
+}
+
+#if defined(HAVE_MPI)
+/*----------------------------------------------------------------------------
  * Find for each face of the list its related rank
  *
  * parameters:
@@ -364,8 +1011,8 @@ _remove_empty_edges(cs_join_mesh_t  *mesh,
   if (verbosity > 1) {
     fvm_gnum_t n_g_simplified_faces = n_simplified_faces;
     fvm_parall_counter(&n_g_simplified_faces, 1);
-    bft_printf(_("\n  Number of simplified faces: %lu\n"),
-               (unsigned long)n_simplified_faces);
+    bft_printf(_("\n  Number of simplified faces: %llu\n"),
+               (unsigned long long)n_simplified_faces);
   }
 }
 
@@ -495,33 +1142,31 @@ _remove_degenerate_edges(cs_join_mesh_t  *mesh,
 
       /* Display the degenerate face */
 
-      if (n_face_vertices < 3 || verbosity > 2) {
+      if (verbosity > 4) {
 
         bft_printf("\n  Remove edge for face: %d [%u]:",
                    i+1, mesh->face_gnum[i]);
-
         bft_printf("\n    Initial def: ");
         for (j = start_id; j < end_id; j++) {
           cs_int_t  v_id = mesh->face_vtx_lst[j] - 1;
           bft_printf(" %d (%u) ", v_id+1, mesh->vertices[v_id].gnum);
         }
-
         bft_printf("\n    Final def:   ");
         for (j = 0; j < n_face_vertices; j++) {
           cs_int_t  v_id = tmp->array[j] - 1;
           bft_printf(" %d (%u) ", v_id+1, mesh->vertices[v_id].gnum);
         }
-
         bft_printf("\n");
         bft_printf_flush();
 
-        if (n_face_vertices < 3)
-          bft_error(__FILE__, __LINE__, 0,
-                    _("  The simplified face has less than 3 vertices.\n"
-                      "  Check your joining parameters.\n"
-                      "  Face %d (%u)\n"), i+1, mesh->face_gnum[i]);
       }
 
+      if (n_face_vertices < 3)
+        bft_error(__FILE__, __LINE__, 0,
+                  _("  The simplified face has less than 3 vertices.\n"
+                    "  Check your joining parameters.\n"
+                    "  Face %d (%u)\n"), i+1, mesh->face_gnum[i]);
+
     } /* End if n_face_vertices != n_init_vertices */
 
     for (j = 0; j < n_face_vertices; j++)
@@ -534,9 +1179,9 @@ _remove_degenerate_edges(cs_join_mesh_t  *mesh,
   fvm_parall_counter(&n_g_modified_faces, 1);
 
   if (verbosity > 0)
-    bft_printf("\n  Edge removed for %lu faces (global).\n"
+    bft_printf("\n  Edge removed for %llu faces (global).\n"
                "  Join mesh cleaning done.\n",
-               (unsigned long)n_g_modified_faces);
+               (unsigned long long)n_g_modified_faces);
 
   for (i = n_faces; i > 0; i--)
     mesh->face_vtx_idx[i] = mesh->face_vtx_idx[i-1] + 1;
@@ -712,29 +1357,33 @@ cs_join_mesh_create_vtx_datatype(void)
   cs_join_vertex_t  v_data;
   MPI_Datatype  new_type;
 
-  int  blocklengths[3] = {1, 1, 3};
-  MPI_Aint  displacements[3] = {0 , 0, 0};
-  MPI_Datatype  types[3] = {MPI_DOUBLE, FVM_MPI_GNUM, FVM_MPI_COORD};
+  int  blocklengths[4] = {1, 1, 1, 3};
+  MPI_Aint  displacements[4] = {0 , 0, 0, 0};
+  MPI_Datatype  types[4] = {MPI_INT,  FVM_MPI_GNUM, MPI_DOUBLE, FVM_MPI_COORD};
 
-  /* Initialize bbox */
+  /* Initialize vertex structure */
 
-  v_data.tolerance = 0.0;
+  v_data.state = CS_JOIN_STATE_UNDEF;
   v_data.gnum = 1;
+  v_data.tolerance = 0.0;
   for (j = 0; j < 3; j++)
-    v_data.coord[j] = 0.;
+    v_data.coord[j] = 0.0;
 
   /* Define array of displacements */
 
 #if defined(MPI_VERSION) && (MPI_VERSION >= 2)
   MPI_Get_address(&v_data, displacements);
   MPI_Get_address(&v_data.gnum, displacements + 1);
-  MPI_Get_address(&v_data.coord, displacements + 2);
+  MPI_Get_address(&v_data.tolerance, displacements + 2);
+  MPI_Get_address(&v_data.coord, displacements + 3);
 #else
   MPI_Address(&v_data, displacements);
   MPI_Address(&v_data.gnum, displacements + 1);
-  MPI_Address(&v_data.coord, displacements + 2);
+  MPI_Address(&v_data.tolerance, displacements + 2);
+  MPI_Address(&v_data.coord, displacements + 3);
 #endif
 
+  displacements[3] -= displacements[0];
   displacements[2] -= displacements[0];
   displacements[1] -= displacements[0];
   displacements[0] = 0;
@@ -742,9 +1391,9 @@ cs_join_mesh_create_vtx_datatype(void)
   /* Create new datatype */
 
 #if defined(MPI_VERSION) && (MPI_VERSION >= 2)
-  MPI_Type_create_struct(3, blocklengths, displacements, types, &new_type);
+  MPI_Type_create_struct(4, blocklengths, displacements, types, &new_type);
 #else
-  MPI_Type_struct(3, blocklengths, displacements, types, &new_type);
+  MPI_Type_struct(4, blocklengths, displacements, types, &new_type);
 #endif
 
   MPI_Type_commit(&new_type);
@@ -762,10 +1411,11 @@ cs_join_mesh_create_vtx_datatype(void)
  *   datatype  <--  MPI_datatype associated to cs_join_vertex_t
  *---------------------------------------------------------------------------*/
 
-void  cs_join_mesh_mpi_vertex_min(cs_join_vertex_t   *in,
-                                  cs_join_vertex_t   *inout,
-                                  int                *len,
-                                  MPI_Datatype       *datatype)
+void
+cs_join_mesh_mpi_vertex_min(cs_join_vertex_t   *in,
+                            cs_join_vertex_t   *inout,
+                            int                *len,
+                            MPI_Datatype       *datatype)
 {
   int  i, j;
 
@@ -779,14 +1429,17 @@ void  cs_join_mesh_mpi_vertex_min(cs_join_vertex_t   *in,
         for (j = 0; j < 3; j++)
           inout->coord[j] = in->coord[j];
         inout->tolerance = in->tolerance;
+        inout->state = in->state;
 
       }
       else {
+
         if (in->gnum < inout->gnum) {
           inout->gnum = in->gnum;
           for (j = 0; j < 3; j++)
             inout->coord[j] = in->coord[j];
           inout->tolerance = in->tolerance;
+          inout->state = in->state;
         }
 
       }
@@ -807,10 +1460,11 @@ void  cs_join_mesh_mpi_vertex_min(cs_join_vertex_t   *in,
  *   datatype  <--  MPI_datatype associated to cs_join_vertex_t
  *---------------------------------------------------------------------------*/
 
-void  cs_join_mesh_mpi_vertex_max(cs_join_vertex_t   *in,
-                                  cs_join_vertex_t   *inout,
-                                  int                *len,
-                                  MPI_Datatype       *datatype)
+void
+cs_join_mesh_mpi_vertex_max(cs_join_vertex_t   *in,
+                            cs_join_vertex_t   *inout,
+                            int                *len,
+                            MPI_Datatype       *datatype)
 {
   int  i, j;
 
@@ -819,18 +1473,25 @@ void  cs_join_mesh_mpi_vertex_max(cs_join_vertex_t   *in,
     if (in->tolerance >= inout->tolerance) {
 
       if (in->tolerance > inout->tolerance) {
+
         inout->gnum = in->gnum;
         for (j = 0; j < 3; j++)
           inout->coord[j] = in->coord[j];
         inout->tolerance = in->tolerance;
+        inout->state = in->state;
+
       }
       else {
+
         if (in->gnum < inout->gnum) {
           inout->gnum = in->gnum;
           for (j = 0; j < 3; j++)
             inout->coord[j] = in->coord[j];
           inout->tolerance = in->tolerance;
+          inout->state = in->state;
+
         }
+
       }
 
     } /* in.tol >= inout.tol */
@@ -958,6 +1619,8 @@ cs_join_mesh_create_from_glob_sel(const char            *mesh_name,
 
     BFT_FREE(send_faces);
     BFT_FREE(send_rank_index);
+
+    cs_join_mesh_face_order(new_mesh);
   }
 
 #endif
@@ -1025,15 +1688,18 @@ cs_join_mesh_create_from_subset(const char            *mesh_name,
 
   mesh->n_faces = subset_size;
 
-  /* Build face_vtx_idx */
+  /* Build face_vtx_idx, and face global numbering */
 
   BFT_MALLOC(mesh->face_vtx_idx, mesh->n_faces + 1, cs_int_t);
+  BFT_MALLOC(mesh->face_gnum, mesh->n_faces, fvm_gnum_t);
 
   for (i = 0; i < mesh->n_faces; i++) {
 
     parent_id = selection[i] - 1;
+
     mesh->face_vtx_idx[i+1] =  parent_mesh->face_vtx_idx[parent_id+1]
                              - parent_mesh->face_vtx_idx[parent_id];
+    mesh->face_gnum[i] = parent_mesh->face_gnum[parent_id];
 
   }
 
@@ -1064,7 +1730,7 @@ cs_join_mesh_create_from_subset(const char            *mesh_name,
 
   } /* End of loop on selected faces */
 
- /* Define vertices */
+  /* Define vertices */
 
   mesh->n_vertices = n_select_vertices;
 
@@ -1076,16 +1742,7 @@ cs_join_mesh_create_from_subset(const char            *mesh_name,
       mesh->vertices[n_select_vertices++] = parent_mesh->vertices[i];
   }
 
-  /* Define global face numbering and linked global cell numbering */
-
-  BFT_MALLOC(mesh->face_gnum, mesh->n_faces, fvm_gnum_t);
-
-  for (i = 0; i < mesh->n_faces; i++) {
-
-    parent_id = selection[i] - 1;
-    mesh->face_gnum[i] = parent_mesh->face_gnum[parent_id];
-
-  }
+  /* Define global numbering */
 
   if (cs_glob_n_ranks == 1) {
 
@@ -1133,87 +1790,87 @@ cs_join_mesh_create_from_subset(const char            *mesh_name,
 
   BFT_FREE(select_vtx_id);
 
+  /* Order faces by increasing global number */
+
+  cs_join_mesh_face_order(mesh);
+
   return  mesh;
 }
 
 /*----------------------------------------------------------------------------
- * Allocate and define a cs_join_mesh_t structure relative to an extraction
- * of selected faces.
+ * Define a cs_join_mesh_t structure from a selection of faces and its
+ * related vertices.
  *
  * parameters:
- *   mesh_name           <-- name of the mesh to create
- *   n_faces             <-- number of selected faces
- *   n_g_faces           <-- global number of selected faces
- *   selected_faces      <-- list of selected faces (based on parent mesh)
- *   face_gnum           <-- global face numbers
- *   face_vtx_idx        <-- "face -> vertex" connectivity index
- *   face_vtx_lst        <-- "face -> vertex" connectivity
- *   n_select_vertices   <-- number of vertices used in joining operation
- *   n_g_select_vertices <-- global number of vertices used in joining
- *   select_vertices     <-- list of selected vertices (based on parent mesh)
- *   vtx_data            <-- array on data associated to selected vertices
+ *   name       <-- mesh name of the resulting cs_join_mesh_t structure
+ *   param      <-- set of user-defined parameters for the joining
+ *   selection  <-> selected entities
+ *   b_f2v_idx  <-- border "face -> vertex" connectivity index
+ *   b_f2v_lst  <-- border "face -> vertex" connectivity
+ *   i_f2v_idx  <-- interior "face -> vertex" connectivity index
+ *   i_f2v_lst  <-- interior "face -> vertex" connectivity
+ *   n_vertices <-- number of vertices in the parent mesh
+ *   vtx_coord  <-- coordinates of vertices in parent mesh
+ *   vtx_gnum   <-- global numbering of vertices
  *
  * returns:
  *   a pointer to a cs_join_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 cs_join_mesh_t *
-cs_join_mesh_create_from_extract(const char              *mesh_name,
-                                 cs_int_t                 n_faces,
-                                 fvm_gnum_t               n_g_faces,
-                                 const cs_int_t           selected_faces[],
-                                 const fvm_gnum_t         face_gnum[],
-                                 const cs_int_t           face_vtx_idx[],
-                                 const cs_int_t           face_vtx_lst[],
-                                 cs_int_t                 n_select_vertices,
-                                 fvm_gnum_t               n_g_select_vertices,
-                                 const cs_int_t           selected_vertices[],
-                                 const cs_join_vertex_t  *vtx_data)
+cs_join_mesh_create_from_select(const char              *name,
+                                const cs_join_param_t    param,
+                                cs_join_select_t        *selection,
+                                const cs_int_t           b_f2v_idx[],
+                                const cs_int_t           b_f2v_lst[],
+                                const cs_int_t           i_f2v_idx[],
+                                const cs_int_t           i_f2v_lst[],
+                                const cs_int_t           n_vertices,
+                                const cs_real_t          vtx_coord[],
+                                const fvm_gnum_t         vtx_gnum[])
 {
-  cs_int_t  i, j, shift, id, face_id, vtx_num, start, end;
+  int  i, j, id, face_id, start, end, shift;
 
+  cs_join_vertex_t  *vertices = NULL;
   cs_join_mesh_t  *mesh = NULL;
 
-  mesh = cs_join_mesh_create(mesh_name);
+  mesh = cs_join_mesh_create(name);
 
   /* Define face connectivity */
 
-  mesh->n_faces = n_faces;
-  mesh->n_g_faces = n_g_faces;
+  mesh->n_faces = selection->n_faces;
+  mesh->n_g_faces = selection->n_g_faces;
 
   /* Define face_vtx_idx */
 
-  BFT_MALLOC(mesh->face_vtx_idx, n_faces + 1, cs_int_t);
-
-  for (i = 0; i < n_faces; i++) {
-
-    face_id = selected_faces[i] - 1;
-    mesh->face_vtx_idx[i+1] = face_vtx_idx[face_id+1] - face_vtx_idx[face_id];
+  BFT_MALLOC(mesh->face_vtx_idx, selection->n_faces + 1, cs_int_t);
 
+  for (i = 0; i < selection->n_faces; i++) {
+    face_id = selection->faces[i] - 1;
+    mesh->face_vtx_idx[i+1] = b_f2v_idx[face_id+1] - b_f2v_idx[face_id];
   }
 
   mesh->face_vtx_idx[0] = 1;
-  for (i = 0; i < n_faces; i++)
+  for (i = 0; i < selection->n_faces; i++)
     mesh->face_vtx_idx[i+1] += mesh->face_vtx_idx[i];
 
-  BFT_MALLOC(mesh->face_vtx_lst, mesh->face_vtx_idx[n_faces] - 1, cs_int_t);
+  BFT_MALLOC(mesh->face_vtx_lst,
+             mesh->face_vtx_idx[mesh->n_faces] - 1, cs_int_t);
 
   /* Define face_vtx_lst */
 
-  for (i = 0; i < n_faces; i++) {
+  for (i = 0; i < selection->n_faces; i++) {
 
-    face_id = selected_faces[i] - 1;
-    start = face_vtx_idx[face_id] - 1;
-    end = face_vtx_idx[face_id+1] - 1;
     shift = mesh->face_vtx_idx[i] - 1;
+    face_id = selection->faces[i] - 1;
+    start = b_f2v_idx[face_id] - 1;
+    end = b_f2v_idx[face_id+1] - 1;
 
     for (j = 0; j < end - start; j++) {
 
-      vtx_num = face_vtx_lst[start + j];
-
-      id = cs_search_binary(n_select_vertices,
-                            vtx_num,
-                            selected_vertices);
+      id = cs_search_binary(selection->n_vertices,
+                            b_f2v_lst[start + j],
+                            selection->vertices);
 
       mesh->face_vtx_lst[shift + j] = id + 1;
 
@@ -1225,22 +1882,28 @@ cs_join_mesh_create_from_extract(const char              *mesh_name,
 
   BFT_MALLOC(mesh->face_gnum, mesh->n_faces, fvm_gnum_t);
 
-  if (face_gnum == NULL)
-    for (i = 0; i < n_faces; i++)
-      mesh->face_gnum[i] = selected_faces[i];
+  if (selection->compact_face_gnum == NULL)
+    for (i = 0; i < selection->n_faces; i++)
+      mesh->face_gnum[i] = selection->faces[i];
   else
-    for (i = 0; i < n_faces; i++)
-      mesh->face_gnum[i] = face_gnum[i];
+    for (i = 0; i < selection->n_faces; i++)
+      mesh->face_gnum[i] = selection->compact_face_gnum[i];
 
   /* Define vertices */
 
-  mesh->n_vertices = n_select_vertices;
-  mesh->n_g_vertices = n_g_select_vertices;
-
-  BFT_MALLOC(mesh->vertices, n_select_vertices, cs_join_vertex_t);
+  vertices = _define_vertices(param,
+                              selection,
+                              b_f2v_idx,
+                              b_f2v_lst,
+                              i_f2v_idx,
+                              i_f2v_lst,
+                              n_vertices,
+                              vtx_coord,
+                              vtx_gnum);
 
-  for (i = 0; i < n_select_vertices; i++)
-    mesh->vertices[i] = vtx_data[i];
+  mesh->n_vertices = selection->n_vertices;
+  mesh->n_g_vertices = selection->n_g_vertices;
+  mesh->vertices = vertices;
 
   return  mesh;
 }
@@ -1256,13 +1919,16 @@ void
 cs_join_mesh_destroy(cs_join_mesh_t  **mesh)
 {
   if (*mesh != NULL) {
+
     cs_join_mesh_t *m = *mesh;
+
     BFT_FREE(m->name);
     BFT_FREE(m->face_vtx_idx);
     BFT_FREE(m->face_vtx_lst);
     BFT_FREE(m->face_gnum);
     BFT_FREE(m->vertices);
     BFT_FREE(*mesh);
+
   }
 }
 
@@ -1386,7 +2052,7 @@ cs_join_mesh_minmax_tol(cs_join_param_t    param,
 
     if (param.verbosity > 2) {
       bft_printf(_("\n  Local min/max. tolerance:\n\n"
-                   "Glob. Num.  |  Tolerance  |        Coordinates\n"));
+                   " Glob. Num. |  Tolerance  |              Coordinates\n"));
       cs_join_mesh_dump_vertex(_min);
       cs_join_mesh_dump_vertex(_max);
     }
@@ -1410,7 +2076,7 @@ cs_join_mesh_minmax_tol(cs_join_param_t    param,
                   cs_glob_mpi_comm);
 
     bft_printf(_("\n  Global min/max. tolerance:\n\n"
-                 "Glob. Num.  |  Tolerance  |        Coordinates\n"));
+                 " Glob. Num. |  Tolerance  |              Coordinates\n"));
     cs_join_mesh_dump_vertex(g_min);
     cs_join_mesh_dump_vertex(g_max);
 
@@ -1498,11 +2164,9 @@ cs_join_mesh_exchange(int                    n_ranks,
   BFT_MALLOC(recv_mesh->face_gnum, n_face_to_recv, fvm_gnum_t);
   BFT_MALLOC(recv_mesh->face_vtx_idx, n_face_to_recv + 1, cs_int_t);
 
-  /*
-     The mesh doesn't change from a global point of view.
+  /* The mesh doesn't change from a global point of view.
      It's only a redistribution of the elements according to the send_faces
-     list.
-  */
+     list. */
 
   recv_mesh->n_g_faces = send_mesh->n_g_faces;
   recv_mesh->n_g_vertices = send_mesh->n_g_vertices;
@@ -1542,8 +2206,7 @@ cs_join_mesh_exchange(int                    n_ranks,
 
       }
 
-      send_count[rank] +=  1            /* face_gnum     */
-                         + 1            /* n_vertices    */
+      send_count[rank] +=  2            /* face_gnum and n_vertices */
                          + n_vertices;  /* face connect. */
 
     }
@@ -1606,8 +2269,7 @@ cs_join_mesh_exchange(int                    n_ranks,
 
       }
 
-      send_count[rank] +=  1            /* face_gnum     */
-                         + 1            /* n_vertices    */
+      send_count[rank] +=  2            /* face_gnum and n_vertices */
                          + n_vertices;  /* face connect. */
 
     }
@@ -1817,8 +2479,7 @@ cs_join_mesh_destroy_edges(cs_join_edges_t  **edges)
 }
 
 /*----------------------------------------------------------------------------
- * Order a cs_join_mesh_t structure according to the global face numbering
- *
+ * Order a cs_join_mesh_t structure according to its global face numbering
  * Delete redundancies.
  *
  * parameters:
@@ -1923,7 +2584,7 @@ cs_join_mesh_face_order(cs_join_mesh_t  *mesh)
 
 /*----------------------------------------------------------------------------
  * Synchronize vertices definition over the rank. For a vertex with the same
- * global number but a not equal tolerance, we keep the minimal tolerance.
+ * global number but a different tolerance, we keep the minimal tolerance.
  *
  * parameters:
  *  mesh <->  pointer to the cs_join_mesh_t structure to synchronize
@@ -2702,13 +3363,13 @@ cs_join_mesh_update(cs_join_mesh_t         *mesh,
       if (new_face_vtx_idx[i+1] < 3)
         bft_error(__FILE__, __LINE__, 0,
                   _(" Problem in mesh connectivity."
-                    " Face: %lu\n"
+                    " Face: %llu\n"
                     " Problem detected during connectivity update:\n"
                     " The face is defined by less than 3 points"
                     " (excessive merging has occured).\n\n"
                     " Modify joining parameters to reduce merging"
                     " (fraction & merge).\n"),
-                  (unsigned long)(mesh->face_gnum[i]));
+                  (unsigned long long)(mesh->face_gnum[i]));
 
     }
 
@@ -2979,10 +3640,8 @@ cs_join_mesh_get_edge_face_adj(const cs_join_mesh_t   *mesh,
   cs_int_t  n_edges, n_faces;
 
   cs_int_t  n_max_vertices = 0;
-  cs_int_t  *counter = NULL;
-  cs_int_t  *face_connect = NULL;
-  cs_int_t  *_edge_face_idx = NULL;
-  cs_int_t  *_edge_face_lst = NULL;
+  cs_int_t  *counter = NULL, *face_connect = NULL;
+  cs_int_t  *_edge_face_idx = NULL, *_edge_face_lst = NULL;
 
   if (mesh == NULL || edges == NULL)
     return;
@@ -3120,9 +3779,10 @@ cs_join_mesh_dump_vertex(const cs_join_vertex_t   vertex)
   assert(vertex.gnum > 0);
   assert(vertex.tolerance >= 0.0);
 
-  bft_printf(" %10u | %11.8f |  [ %12.9e %12.9e  %12.9e]\n",
+  bft_printf(" %10u | %11.8f | % 12.10e % 12.10e  % 12.10e | %s\n",
              vertex.gnum, vertex.tolerance,
-             vertex.coord[0], vertex.coord[1], vertex.coord[2]);
+             vertex.coord[0], vertex.coord[1], vertex.coord[2],
+             _print_state(vertex.state));
 }
 
 /*----------------------------------------------------------------------------
@@ -3140,9 +3800,10 @@ cs_join_mesh_dump_vertex_file(FILE                   *file,
   assert(vertex.gnum > 0);
   assert(vertex.tolerance >= 0.0);
 
-  fprintf(file," %10u | %11.6f |  [ %12.6g  %12.6g  %12.6g]\n",
-          vertex.gnum, vertex.tolerance,
-          vertex.coord[0], vertex.coord[1], vertex.coord[2]);
+  fprintf(file," %10llu | %11.6f | % 12.10e  % 12.10e  % 12.10e | %s\n",
+          (unsigned long long)vertex.gnum, vertex.tolerance,
+          vertex.coord[0], vertex.coord[1], vertex.coord[2],
+          _print_state( vertex.state));
 }
 
 /*----------------------------------------------------------------------------
@@ -3175,7 +3836,7 @@ cs_join_mesh_dump(const cs_join_mesh_t  *mesh)
       cs_int_t  start = mesh->face_vtx_idx[i] - 1;
       cs_int_t  end = mesh->face_vtx_idx[i+1] - 1;
 
-      bft_printf(_("\n face_id: %5d gnum: %9u - n_vertices: %4d\n"),
+      bft_printf(_("\n face_id: %5d gnum: %9u n_vertices: %4d\n"),
                  i, mesh->face_gnum[i], end-start);
 
       for (j = start; j < end; j++) {
@@ -3288,17 +3949,18 @@ cs_join_mesh_dump_file(FILE                  *file,
       cs_int_t  start = mesh->face_vtx_idx[i] - 1;
       cs_int_t  end = mesh->face_vtx_idx[i+1] - 1;
 
-      fprintf(file,_("\n face_id: %9d gnum: %10u - n_vertices : %4d\n"),
-              i, mesh->face_gnum[i],end-start);
+      fprintf(file,_("\n face_id: %9d gnum: %10llu n_vertices : %4d\n"),
+              i, (unsigned long long)mesh->face_gnum[i], end-start);
 
       for (j = start; j < end; j++) {
 
         cs_int_t  vtx_id = mesh->face_vtx_lst[j]-1;
         cs_join_vertex_t  v_data = mesh->vertices[vtx_id];
 
-        fprintf(file," %9d - %10u - [ %12.6g %12.6g %12.6g]\n",
-                vtx_id+1, v_data.gnum,
-                v_data.coord[0], v_data.coord[1], v_data.coord[2]);
+        fprintf(file," %8d - %10llu - [ % 7.5e % 7.5e % 7.5e] - %s\n",
+                vtx_id+1, (unsigned long long)v_data.gnum,
+                v_data.coord[0], v_data.coord[1], v_data.coord[2],
+                _print_state(v_data.state));
 
       }
       fprintf(file,"\n");
@@ -3312,12 +3974,13 @@ cs_join_mesh_dump_file(FILE                  *file,
 
         if (vtx_id1 == vtx_id2) {
           fprintf(file,_("  Incoherency found in the current mesh definition\n"
-                         "  Face number: %d (global: %u)\n"
-                         "  Vertices: local (%d, %d), global (%u, %u)"
+                         "  Face number: %d (global: %llu)\n"
+                         "  Vertices: local (%d, %d), global (%llu, %llu)"
                          " are defined twice\n"),
-                  i+1, mesh->face_gnum[i], vtx_id1+1, vtx_id2+1,
-                  (mesh->vertices[vtx_id1]).gnum,
-                  (mesh->vertices[vtx_id2]).gnum);
+                  i+1, (unsigned long long)mesh->face_gnum[i],
+                  vtx_id1+1, vtx_id2+1,
+                  (unsigned long long)(mesh->vertices[vtx_id1]).gnum,
+                  (unsigned long long)(mesh->vertices[vtx_id2]).gnum);
           fflush(file);
           assert(0);
         }
@@ -3395,7 +4058,7 @@ cs_join_mesh_dump_edges(const cs_join_edges_t  *edges,
     fvm_gnum_t  v1_gnum = (mesh->vertices[v1_id]).gnum;
     fvm_gnum_t  v2_gnum = (mesh->vertices[v2_id]).gnum;
 
-    bft_printf(_("  Edge %6d  (%7u) <Vertex> [%7u %7u]\n"),
+    bft_printf(_("  Edge %6d  (%8u) <Vertex> [%8u %8u]\n"),
                i+1, edges->gnum[i], v1_gnum, v2_gnum);
 
     /* Check coherency */
diff --git a/src/base/cs_join_perio.c b/src/base/cs_join_perio.c
new file mode 100644
index 0000000..0076e82
--- /dev/null
+++ b/src/base/cs_join_perio.c
@@ -0,0 +1,2417 @@
+/*============================================================================
+ *
+ *     This file is part of the Code_Saturne Kernel, element of the
+ *     Code_Saturne CFD tool.
+ *
+ *     Copyright (C) 2008-2009 EDF S.A., France
+ *
+ *     contact: saturne-support at edf.fr
+ *
+ *     The Code_Saturne Kernel is free software; you can redistribute it
+ *     and/or modify it under the terms of the GNU General Public License
+ *     as published by the Free Software Foundation; either version 2 of
+ *     the License, or (at your option) any later version.
+ *
+ *     The Code_Saturne Kernel 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 General Public License for more details.
+ *
+ *     You should have received a copy of the GNU General Public License
+ *     along with the Code_Saturne Kernel; if not, write to the
+ *     Free Software Foundation, Inc.,
+ *     51 Franklin St, Fifth Floor,
+ *     Boston, MA  02110-1301  USA
+ *
+ *===========================================================================*/
+
+/*============================================================================
+ * Management of conforming and non-conforming joining in case of periodicity
+ *===========================================================================*/
+
+#if defined(HAVE_CONFIG_H)
+#include "cs_config.h"
+#endif
+
+/*----------------------------------------------------------------------------
+ * Standard C library headers
+ *---------------------------------------------------------------------------*/
+
+#include <assert.h>
+#include <string.h>
+
+/*----------------------------------------------------------------------------
+ * BFT library headers
+ *---------------------------------------------------------------------------*/
+
+#include <bft_mem.h>
+#include <bft_error.h>
+#include <bft_printf.h>
+#include <bft_timer.h>
+
+/*----------------------------------------------------------------------------
+ * FVM library headers
+ *---------------------------------------------------------------------------*/
+
+#include <fvm_parall.h>
+#include <fvm_periodicity.h>
+#include <fvm_interface.h>
+
+/*----------------------------------------------------------------------------
+ *  Local headers
+ *---------------------------------------------------------------------------*/
+
+#include "cs_search.h"
+#include "cs_join_mesh.h"
+#include "cs_join_post.h"
+#include "cs_join_set.h"
+
+/*----------------------------------------------------------------------------
+ *  Header for the current file
+ *---------------------------------------------------------------------------*/
+
+#include "cs_join_perio.h"
+
+/*---------------------------------------------------------------------------*/
+
+BEGIN_C_DECLS
+
+/*=============================================================================
+ * Local Structure Definitions
+ *===========================================================================*/
+
+typedef struct _cs_join_perio_builder_t {
+
+  int   n_perio;   /* Number of initial periodicity
+                      No composition of periodicity taken into account */
+
+  fvm_periodicity_t   *periodicity;   /* Structure keeping periodicity
+                                         information like matrix of
+                                         the transformation */
+
+  int   *n_perio_couples;             /* Local number of periodic face
+                                         couples for each periodicity */
+  fvm_gnum_t  **perio_couples;        /* List of global numbering of
+                                         periodic faces. */
+
+} cs_join_perio_builder_t;
+
+/*============================================================================
+ * Global variables
+ *===========================================================================*/
+
+int  cs_glob_n_join_perio = 0; /* Number of periodicity defined through
+                                  a joining operation */
+
+/*============================================================================
+ * Static global variables
+ *===========================================================================*/
+
+static cs_join_perio_builder_t  *cs_glob_join_perio_builder = NULL;
+
+/*============================================================================
+ * Private function definitions
+ *===========================================================================*/
+
+/*----------------------------------------------------------------------------
+ * Create and initialize a cs_join_perio_builder_t structure.
+ *
+ * returns:
+ *  a pointer to a new allocated cs_join_perio_builder_t
+ *---------------------------------------------------------------------------*/
+
+static cs_join_perio_builder_t *
+_create_perio_builder(void)
+{
+  cs_join_perio_builder_t  *perio_builder = NULL;
+
+  BFT_MALLOC(perio_builder, 1, cs_join_perio_builder_t);
+
+  perio_builder->n_perio = 1;
+
+  perio_builder->periodicity = fvm_periodicity_create(0.001);
+
+  BFT_MALLOC(perio_builder->n_perio_couples, 1, int);
+  BFT_MALLOC(perio_builder->perio_couples, 1, fvm_gnum_t *);
+
+  perio_builder->n_perio_couples[0] = 0;
+  perio_builder->perio_couples[0] = NULL;
+
+  return perio_builder;
+}
+
+/*----------------------------------------------------------------------------
+ * Free a cs_join_perio_builder_t structure.
+ * builder->periodicity is not freed here because it's transfered to a
+ * cs_mesh_t structure.
+ *
+ * parameters:
+ *   builder     <-> a pointer to a cs_join_perio_builder_t struct. to free
+ *---------------------------------------------------------------------------*/
+
+static void
+_delete_perio_builder(cs_join_perio_builder_t   **builder)
+{
+  int  i;
+
+  cs_join_perio_builder_t  *_bdr = *builder;
+
+  if (_bdr == NULL)
+    return;
+
+  for (i = 0; i < _bdr->n_perio; i++)
+    BFT_FREE(_bdr->perio_couples[i]);
+  BFT_FREE(_bdr->perio_couples);
+  BFT_FREE(_bdr->n_perio_couples);
+
+  BFT_FREE(_bdr);
+
+  *builder = NULL;
+}
+
+/*----------------------------------------------------------------------------
+ * Update a cs_join_perio_builder_t structure. Add a new periodicity.
+ *
+ * parameters:
+ *   builder     <-> a pointer to a cs_join_perio_builder_t structure
+ *---------------------------------------------------------------------------*/
+
+static void
+_increment_perio_builder(cs_join_perio_builder_t   *builder)
+{
+  assert(builder != NULL);
+
+  builder->n_perio += 1;
+
+  BFT_REALLOC(builder->n_perio_couples, builder->n_perio, int);
+  BFT_REALLOC(builder->perio_couples, builder->n_perio, fvm_gnum_t *);
+
+  builder->n_perio_couples[builder->n_perio - 1] = 0;
+  builder->perio_couples[builder->n_perio - 1] = NULL;
+}
+
+/*----------------------------------------------------------------------------
+ * Add a new periodic cs_join_t structure.
+ *
+ * parameters:
+ *   join_number  <-- number related to the joining operation
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   perio_num    <-- periodicity number
+ *   verbosity    <-- level of verbosity required
+ *
+ * returns:
+ *   a pointer to a new allocated cs_join_t structure
+ *---------------------------------------------------------------------------*/
+
+static void
+_add_perio_join(int           join_number,
+                const char   *criteria,
+                float         fraction,
+                float         plane,
+                int           perio_num,
+                int           verbosity)
+{
+  /* Check parameters value */
+
+  if (fraction < 0.0 || fraction >= 1.0)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the fraction parameter.\n"
+                "  It must be between [0.0, 1.0[ and is here: %f\n"),
+              fraction);
+
+  if (plane < 0.0 || plane >= 90.0)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the plane parameter.\n"
+                "  It must be between [0, 90] and is here: %f\n"),
+              plane);
+
+  if (perio_num < 1)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the periodicity number.\n"
+                "  It must be between > 0 and is here: %d\n"),
+              perio_num);
+
+   /* Allocate and initialize a cs_join_t structure */
+
+  BFT_REALLOC(cs_glob_join_array, cs_glob_n_joinings + 1, cs_join_t *);
+
+  cs_glob_join_array[cs_glob_n_joinings] = cs_join_create(join_number,
+                                                          criteria,
+                                                          fraction,
+                                                          plane,
+                                                          perio_num,
+                                                          verbosity);
+
+  cs_glob_n_joinings++;
+}
+
+/*----------------------------------------------------------------------------
+ * Update work_mesh by redistributing local join mesh.
+ *
+ * parameters:
+ *   param             <--  set of user-defined parameter
+ *   gnum_rank_index   <--  index on ranks for the old global face numbering
+ *   local_mesh        <--  mesh on local selected faces to be joined
+ *   p_work_mesh       <->  distributed mesh on faces to join
+ *---------------------------------------------------------------------------*/
+
+static void
+_redistribute_mesh(cs_join_param_t         param,
+                   const fvm_gnum_t        gnum_rank_index[],
+                   const cs_join_mesh_t   *local_mesh,
+                   cs_join_mesh_t        **p_work_mesh)
+{
+  cs_join_mesh_t  *work_mesh = *p_work_mesh;
+
+  const int  n_ranks = cs_glob_n_ranks;
+  const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
+
+  /* sanity checks */
+
+  assert(local_mesh != NULL);
+  assert(work_mesh != NULL);
+
+  if (n_ranks == 1)
+    cs_join_mesh_copy(&work_mesh, local_mesh);
+
+#if defined(HAVE_MPI)
+  if (n_ranks > 1) { /* Parallel mode */
+
+    int  i, n_work_faces;
+
+    char  *mesh_name = NULL;
+    fvm_gnum_t  *work_faces = NULL;
+
+    n_work_faces = work_mesh->n_faces;
+    BFT_MALLOC(work_faces, n_work_faces, fvm_gnum_t);
+
+    for (i = 0; i < n_work_faces; i++)
+      work_faces[i] = work_mesh->face_gnum[i];
+
+    /* Replace current work mesh */
+
+    cs_join_mesh_destroy(&work_mesh);
+
+    BFT_MALLOC(mesh_name, strlen("WorkMesh_j_n") + 2 + 5 + 1, char);
+    sprintf(mesh_name,"%s%02d%s%05d",
+            "WorkMesh_j", param.num, "_n", local_rank);
+
+    work_mesh = cs_join_mesh_create_from_glob_sel(mesh_name,
+                                                  n_work_faces,
+                                                  work_faces,
+                                                  gnum_rank_index,
+                                                  local_mesh);
+
+    BFT_FREE(mesh_name);
+    BFT_FREE(work_faces);
+
+  }
+#endif
+
+  /* Return pointers */
+
+  *p_work_mesh = work_mesh;
+
+}
+
+#if defined(HAVE_MPI)
+
+/*----------------------------------------------------------------------------
+ * Complete mesh builder definition for periodic faces.
+ * Algorithm similar to the one in the file cs_preprocessor_data.c.
+ * Face relation are defined in local numbering.
+ *
+ * parameters:
+ *   n_init_perio <-- number of initial periodicities defined
+ *   mb           <-> mesh builder structure to update
+ *   face_ifs     <-- face interface set structure
+ *---------------------------------------------------------------------------*/
+
+static void
+_extract_perio_couples(int                   n_init_perio,
+                       cs_mesh_builder_t    *mb,
+                       fvm_interface_set_t  *face_ifs)
+{
+  int  i, j, k, l;
+
+  fvm_lnum_t  *per_face_count = NULL;
+  fvm_lnum_t  *if_index = NULL;
+  fvm_lnum_t  *send_num = NULL, *recv_num = NULL;
+
+  const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
+  const int  n_interfaces = fvm_interface_set_size(face_ifs);
+  const fvm_lnum_t  tr_index_size = n_init_perio*2 + 2;
+
+  /* Define interface index only for the periodic data */
+
+  BFT_MALLOC(if_index, n_interfaces + 1, fvm_lnum_t);
+
+  if_index[0] = 0;
+  for (j = 0; j < n_interfaces; j++) {
+    const fvm_interface_t *face_if = fvm_interface_set_get(face_ifs, j);
+    const fvm_lnum_t *tr_index = fvm_interface_get_tr_index(face_if);
+    if_index[j+1] = if_index[j] + tr_index[tr_index_size - 1]-tr_index[1];
+  }
+
+  /* Define send_num and recv_num */
+
+  BFT_MALLOC(send_num, if_index[n_interfaces], fvm_lnum_t);
+  BFT_MALLOC(recv_num, if_index[n_interfaces], fvm_lnum_t);
+
+  for (j = 0; j < n_interfaces; j++) {
+
+    const fvm_lnum_t start_id = if_index[j];
+    const fvm_lnum_t end_id = if_index[j+1];
+    const fvm_interface_t *face_if = fvm_interface_set_get(face_ifs, j);
+    const fvm_lnum_t *tr_index = fvm_interface_get_tr_index(face_if);
+    const fvm_lnum_t *loc_num = fvm_interface_get_local_num(face_if);
+    const int distant_rank = fvm_interface_rank(face_if);
+
+    for (k = start_id, l = tr_index[1]; k < end_id; k++, l++)
+      send_num[k] = loc_num[l];
+
+    if (distant_rank == local_rank) {
+      const fvm_lnum_t *dist_num = fvm_interface_get_distant_num(face_if);
+      for (k = start_id, l = tr_index[1]; k < end_id; k++, l++)
+        recv_num[k] = dist_num[l];
+    }
+  }
+
+  {   /* Exchange local face numbers */
+
+    MPI_Request  *request = NULL;
+    MPI_Status  *status  = NULL;
+
+    int request_count = 0;
+
+    BFT_MALLOC(request, n_interfaces*2, MPI_Request);
+    BFT_MALLOC(status, n_interfaces*2, MPI_Status);
+
+    for (j = 0; j < n_interfaces; j++) {
+      const fvm_interface_t *face_if = fvm_interface_set_get(face_ifs, j);
+      int distant_rank = fvm_interface_rank(face_if);
+
+      if (distant_rank != local_rank)
+        MPI_Irecv(recv_num + if_index[j],
+                  if_index[j+1] - if_index[j],
+                  FVM_MPI_LNUM,
+                  distant_rank,
+                  distant_rank,
+                  cs_glob_mpi_comm,
+                  &(request[request_count++]));
+    }
+
+    for (j = 0; j < n_interfaces; j++) {
+      const fvm_interface_t *face_if = fvm_interface_set_get(face_ifs, j);
+      int distant_rank = fvm_interface_rank(face_if);
+
+      if (distant_rank != local_rank)
+        MPI_Isend(send_num + if_index[j],
+                  if_index[j+1] - if_index[j],
+                  FVM_MPI_LNUM,
+                  distant_rank,
+                  (int)local_rank,
+                  cs_glob_mpi_comm,
+                  &(request[request_count++]));
+    }
+
+    MPI_Waitall(request_count, request, status);
+
+    BFT_FREE(request);
+    BFT_FREE(status);
+  }
+
+  /* Copy interface information to mesh builder */
+
+  BFT_MALLOC(per_face_count, n_init_perio, fvm_lnum_t);
+  for (i = 0; i < n_init_perio; i++)
+    per_face_count[i] = 0;
+
+  for (j = 0; j < n_interfaces; j++) {
+
+    fvm_lnum_t  tr_shift = 0;
+    const fvm_interface_t  *face_if = fvm_interface_set_get(face_ifs, j);
+    const int  distant_rank = fvm_interface_rank(face_if);
+    const fvm_lnum_t  *tr_index = fvm_interface_get_tr_index(face_if);
+
+    for (i = 1; i < tr_index_size - 1; i++) {
+
+      fvm_lnum_t n_elts = tr_index[i+1] - tr_index[i];
+
+      if ((distant_rank != local_rank) || (i%2 == 1)) {
+
+        fvm_lnum_t  send_shift, recv_shift;
+
+        int  perio_id = (i-1)/2;
+        int  perio_sgn = (i%2)*2 - 1; /* 1 for odd, -1 for even */
+        fvm_lnum_t  n_dir_elts = tr_index[2*perio_id+2]-tr_index[2*perio_id+1];
+        fvm_lnum_t  n_rev_elts = tr_index[2*perio_id+3]-tr_index[2*perio_id+2];
+
+        send_shift = if_index[j] + tr_shift;
+        if (distant_rank != local_rank) {
+          if (perio_sgn > 0)
+            recv_shift = if_index[j] + n_rev_elts + tr_shift;
+          else
+            recv_shift = if_index[j] - n_dir_elts + tr_shift;
+        }
+        else /* if (i%2 == 1) */
+          recv_shift = send_shift;
+
+        for (k = 0; k < n_elts; k++) {
+          l = mb->per_face_idx[perio_id] + per_face_count[perio_id];
+          mb->per_face_lst[l*2]     = send_num[send_shift + k]*perio_sgn;
+          mb->per_face_lst[l*2 + 1] = recv_num[recv_shift + k];
+          mb->per_rank_lst[l] = distant_rank + 1;
+          per_face_count[perio_id] += 1;
+        }
+      }
+
+      tr_shift += n_elts;
+
+    } /* End of loop on tr_index */
+
+  } /* End of loop on interfaces */
+
+
+  BFT_FREE(per_face_count);
+  BFT_FREE(recv_num);
+  BFT_FREE(send_num);
+  BFT_FREE(if_index);
+
+}
+
+#endif /* HAVE_MPI */
+
+/*----------------------------------------------------------------------------
+ * Delete interior faces temporary added for periodicity operation.
+ * Only done if n_ranks > 1 because in serial, these periodic faces are
+ * merged with initially present faces
+ *
+ * parameters:
+ *   param <-- set of parameters for the joining operation
+ *   mesh  <-> cs_mesh_t structure to update
+ *---------------------------------------------------------------------------*/
+
+static void
+_perio_face_clean(cs_join_param_t      param,
+                  cs_mesh_t           *mesh)
+{
+  int  i, j, k, shift;
+
+  int  n_ii_faces = mesh->n_i_faces;
+  int  n_fi_faces = 0;
+  cs_int_t  *new_f2v_idx = NULL;
+  int  *tag = NULL;
+
+  assert(cs_glob_n_ranks > 1);
+
+  BFT_MALLOC(tag, n_ii_faces, int);
+
+  for (i = 0; i < n_ii_faces; i++) {
+
+    if (mesh->i_face_cells[2*i] == 0 && mesh->i_face_cells[2*i+1] == 0)
+      tag[i] = -1;
+    else {
+      mesh->i_face_cells[2*n_fi_faces] = mesh->i_face_cells[2*i];
+      mesh->i_face_cells[2*n_fi_faces+1] = mesh->i_face_cells[2*i+1];
+      n_fi_faces++;
+      tag[i] = n_fi_faces;
+    }
+
+  }
+
+  if (param.verbosity > 2)
+    bft_printf(_("\n  Delete %d interior periodic faces locally\n"),
+               n_ii_faces - n_fi_faces);
+
+  mesh->n_i_faces = n_fi_faces;
+  BFT_REALLOC(mesh->i_face_cells, 2*mesh->n_i_faces, cs_int_t);
+  BFT_MALLOC(new_f2v_idx, n_fi_faces + 1, cs_int_t);
+
+  n_fi_faces = 0;
+  for (i = 0; i < n_ii_faces; i++) {
+    if (tag[i] > 0) {
+      mesh->global_i_face_num[n_fi_faces] = mesh->global_i_face_num[i];
+      mesh->i_face_family[n_fi_faces] = mesh->i_face_family[i];
+      new_f2v_idx[n_fi_faces + 1] =  mesh->i_face_vtx_idx[i+1]
+                                   - mesh->i_face_vtx_idx[i];
+      n_fi_faces++;
+    }
+  }
+
+  BFT_REALLOC(mesh->global_i_face_num, mesh->n_i_faces, fvm_gnum_t);
+  BFT_REALLOC(mesh->i_face_family, mesh->n_i_faces, cs_int_t);
+
+  /* Update interior face connectivity */
+
+  new_f2v_idx[0] = 1;
+  for (i = 0; i < n_fi_faces; i++)
+    new_f2v_idx[i+1] += new_f2v_idx[i];
+
+  n_fi_faces = 0;
+  for (i = 0; i < n_ii_faces; i++) {
+    if (tag[i] > 0) {
+      shift = new_f2v_idx[n_fi_faces] - 1;
+      for (k = 0, j = mesh->i_face_vtx_idx[i]-1;
+           j < mesh->i_face_vtx_idx[i+1]-1; j++, k++)
+        mesh->i_face_vtx_lst[shift+k] = mesh->i_face_vtx_lst[j];
+      n_fi_faces++;
+    }
+  }
+
+  BFT_REALLOC(mesh->i_face_vtx_lst, new_f2v_idx[n_fi_faces]-1, cs_int_t);
+  BFT_FREE(mesh->i_face_vtx_idx);
+
+  mesh->i_face_vtx_idx = new_f2v_idx;
+
+  /* There is no need to define a new glbal interior face numbering
+     because the excluded faces are always defined on an another rank */
+
+  BFT_FREE(tag);
+}
+
+/*============================================================================
+ *  Public function prototypes for Fortran API
+ *============================================================================*/
+
+/*----------------------------------------------------------------------------
+ * Get the number of periodic transformations already defined
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE NUMPER
+ * *****************
+ *
+ * INTEGER   numper      : --> : number of periodicities  op. already defined
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(numper, NUMPER)
+(
+ cs_int_t    *numper
+)
+{
+  *numper = cs_glob_n_join_perio;
+
+  return;
+}
+
+/*----------------------------------------------------------------------------
+ * Define a translation
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE DEFPT1
+ * *****************
+ *
+ * INTEGER        numper    : <-- : number related to the periodic op.
+ * CHARACTER*     criteria  : <-- : boundary face selection criteria
+ * REAL           fraction  : <-- : parameter for merging vertices
+ * REAL           plane     : <-- : parameter for splitting faces
+ * INTEGER        verbosity : <-- : verbosity level
+ * REAL           tx        : <-- : X coordinate of the translation vector
+ * REAL           ty        : <-- : Y coordinate of the translation vector
+ * REAL           tz        : <-- : Z coordinate of the translation vector
+ * INTEGER        crit_len  : <-- : length of criteria
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(defpt1, DEFPT1)
+(
+ cs_int_t    *numper,
+ const char  *criteria,
+ cs_real_t   *fraction,
+ cs_real_t   *plane,
+ cs_int_t    *verbosity,
+ cs_real_t   *tx,
+ cs_real_t   *ty,
+ cs_real_t   *tz,
+ cs_int_t    *crit_len
+ CS_ARGF_SUPP_CHAINE
+)
+{
+  double  trans[3];
+
+  char *_criteria = NULL;
+
+  assert(CS_ABS(*tx) > 0.0 || CS_ABS(*ty) > 0.0 || CS_ABS(*tz) > 0.0);
+
+  trans[0] = *tx;
+  trans[1] = *ty;
+  trans[2] = *tz;
+
+  if (criteria != NULL && *crit_len > 0)
+    _criteria = cs_base_string_f_to_c_create(criteria, *crit_len);
+  if (_criteria != NULL && strlen(_criteria) == 0)
+    cs_base_string_f_to_c_free(&_criteria);
+
+  bft_printf(_("  Adding periodicity %d "
+               "(translation [%10.4e, %10.4e, %10.4e]).\n"),
+             cs_glob_n_join_perio, trans[0], trans[1], trans[2]);
+
+  cs_join_perio_add_translation(*numper,
+                                _criteria,
+                                *fraction,
+                                *plane,
+                                *verbosity,
+                                trans);
+
+  if (_criteria != NULL)
+    cs_base_string_f_to_c_free(&_criteria);
+}
+
+/*----------------------------------------------------------------------------
+ * Define a rotation
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE DEFPR1
+ * *****************
+ *
+ * INTEGER        numper    : <-- : number related to the periodic op.
+ * CHARACTER*     criteria  : <-- : boundary face selection criteria
+ * REAL           fraction  : <-- : parameter for merging vertices
+ * REAL           plane     : <-- : parameter for splitting faces
+ * INTEGER        verbosity : <-- : verbosity level
+ * REAL           ax        : <-- : X coordinate of the rotation axis
+ * REAL           ay        : <-- : Y coordinate of the rotation axis
+ * REAL           az        : <-- : Z coordinate of the rotation axis
+ * REAL           theta     : <-- : angle of the rotation (radian)
+ * REAL           ix        : <-- : X coordinate of the invariant point
+ * REAL           iy        : <-- : Y coordinate of the invariant point
+ * REAL           iz        : <-- : Z coordinate of the invariant point
+ * INTEGER        crit_len  : <-- : length of criteria string
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(defpr1, DEFPR1)
+(
+ cs_int_t    *numper,
+ const char  *criteria,
+ cs_real_t   *fraction,
+ cs_real_t   *plane,
+ cs_int_t    *verbosity,
+ cs_real_t   *ax,
+ cs_real_t   *ay,
+ cs_real_t   *az,
+ cs_real_t   *theta,
+ cs_real_t   *ix,
+ cs_real_t   *iy,
+ cs_real_t   *iz,
+ cs_int_t    *crit_len
+ CS_ARGF_SUPP_CHAINE
+)
+{
+  double  axis[3], inv[3];
+  char  *_criteria = NULL;
+
+  assert(CS_ABS(*ax) > 0.0 || CS_ABS(*ay) > 0.0 || CS_ABS(*az) > 0.0);
+  assert(CS_ABS(*theta) > 0.0);
+
+  axis[0] = *ax;
+  axis[1] = *ay;
+  axis[2] = *az;
+
+  inv[0] = *ix;
+  inv[1] = *iy;
+  inv[2] = *iz;
+
+  if (criteria != NULL && *crit_len > 0)
+    _criteria = cs_base_string_f_to_c_create(criteria, *crit_len);
+  if (_criteria != NULL && strlen(_criteria) == 0)
+    cs_base_string_f_to_c_free(&_criteria);
+
+  bft_printf(_("  Adding periodicity %d (rotation).\n"), cs_glob_n_join_perio);
+
+  cs_join_perio_add_rotation(*numper,
+                             _criteria,
+                             *fraction,
+                             *plane,
+                             *verbosity,
+                             *theta,
+                             axis,
+                             inv);
+
+  if (_criteria != NULL)
+    cs_base_string_f_to_c_free(&_criteria);
+}
+
+/*----------------------------------------------------------------------------
+ * Define a general transformation through a homogeneous matrix (4x4)
+ *     _               _
+ *    | r11 r12 r13 tx  |  t(x,y,z) : translation vector
+ *    | r21 r22 r23 ty  |  r(i,j)   : rotation matrix
+ *    | r31 r32 r33 tz  |
+ *    |_  0   0   0  1 _|
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE DEFPG1
+ * *****************
+ *
+ * INTEGER        numper    : <-- : number related to the periodic op.
+ * CHARACTER*     criteria  : <-- : boundary face selection criteria
+ * REAL           fraction  : <-- : parameter for merging vertices
+ * REAL           plane     : <-- : parameter for splitting faces
+ * INTEGER        verbosity : <-- : verbosity level
+ * REAL           r11       : <-- : coef. (1,1) of the homogeneous matrix
+ * REAL           r12       : <-- : coef. (1,2) of the homogeneous matrix
+ * REAL           r13       : <-- : coef. (1,3) of the homogeneous matrix
+ * REAL           tx        : <-- : coef. (1,4) of the homogeneous matrix
+ * REAL           r21       : <-- : coef. (2,1) of the homogeneous matrix
+ * REAL           r22       : <-- : coef. (2,2) of the homogeneous matrix
+ * REAL           r23       : <-- : coef. (2,3) of the homogeneous matrix
+ * REAL           ty        : <-- : coef. (2,4) of the homogeneous matrix
+ * REAL           r31       : <-- : coef. (3,1) of the homogeneous matrix
+ * REAL           r32       : <-- : coef. (3,2) of the homogeneous matrix
+ * REAL           r33       : <-- : coef. (3,3) of the homogeneous matrix
+ * REAL           tz        : <-- : coef. (3,4) of the homogeneous matrix
+ * INTEGER        crit_len  : <-- : length of criteria string
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(defpg1, DEFPG1)
+(
+ cs_int_t    *numper,
+ const char  *criteria,
+ cs_real_t   *fraction,
+ cs_real_t   *plane,
+ cs_int_t    *verbosity,
+ cs_real_t   *r11,
+ cs_real_t   *r12,
+ cs_real_t   *r13,
+ cs_real_t   *tx,
+ cs_real_t   *r21,
+ cs_real_t   *r22,
+ cs_real_t   *r23,
+ cs_real_t   *ty,
+ cs_real_t   *r31,
+ cs_real_t   *r32,
+ cs_real_t   *r33,
+ cs_real_t   *tz,
+ cs_int_t    *crit_len
+ CS_ARGF_SUPP_CHAINE
+)
+{
+  double  matrix[3][4];
+  char  *_criteria = NULL;
+
+  /* Build the matrix */
+
+  matrix[0][0] = *r11;
+  matrix[0][1] = *r12;
+  matrix[0][2] = *r13;
+  matrix[0][3] = *tx;
+
+  matrix[1][0] = *r21;
+  matrix[1][1] = *r22;
+  matrix[1][2] = *r23;
+  matrix[1][3] = *ty;
+
+  matrix[2][0] = *r31;
+  matrix[2][1] = *r32;
+  matrix[2][2] = *r33;
+  matrix[2][3] = *tz;
+
+  if (criteria != NULL && *crit_len > 0)
+    _criteria = cs_base_string_f_to_c_create(criteria, *crit_len);
+  if (_criteria != NULL && strlen(_criteria) == 0)
+    cs_base_string_f_to_c_free(&_criteria);
+
+  bft_printf(_("  Adding periodicity %d (general formulation).\n"),
+             cs_glob_n_join_perio);
+
+  cs_join_perio_add_mixed(*numper,
+                          _criteria,
+                          *fraction,
+                          *plane,
+                          *verbosity,
+                          (double (*)[4])matrix);
+
+  if (_criteria != NULL)
+    cs_base_string_f_to_c_free(&_criteria);
+}
+
+/*----------------------------------------------------------------------------
+ * Set advanced parameters for the joining algorithm in case of periodicity
+ *
+ * Fortran Interface:
+ *
+ * SUBROUTINE SETAPP
+ * *****************
+ *
+ * INTEGER      perio_num         : <-- : perio number
+ * REAL         mtf               : <-- : merge tolerance coefficient
+ * REAL         pmf               : <-- : pre-merge factor
+ * INTEGER      tcm               : <-- : tolerance computation mode
+ * INTEGER      icm               : <-- : intersection computation mode
+ * INTEGER      maxbrk            : <-- : max number of equiv. breaks
+ * INTEGER      max_sub_faces     : <-- : max. possible number of sub-faces
+ *                                        by splitting a selected face
+ * INTEGER      tml               : <-- : tree max level
+ * INTEGER      tmb               : <-- : tree max boxes
+ * REAL         tmr               : <-- : tree max ratio
+ *----------------------------------------------------------------------------*/
+
+void CS_PROCF(setapp, SETAPP)
+(
+ cs_int_t    *perio_num,
+ cs_real_t   *mtf,
+ cs_real_t   *pmf,
+ cs_int_t    *tcm,
+ cs_int_t    *icm,
+ cs_int_t    *maxbrk,
+ cs_int_t    *max_sub_faces,
+ cs_int_t    *tml,
+ cs_int_t    *tmb,
+ cs_real_t   *tmr
+)
+{
+  int  i, join_id = -1;
+
+  cs_join_t  *join = NULL;
+
+  assert(*perio_num > 0);
+
+  /* Look for the joining structure related to "perio_num" */
+
+  for (i = 0; i < cs_glob_n_joinings; i++) {
+
+    join = cs_glob_join_array[i];
+    if (*perio_num == join->param.perio_num) {
+      join_id = i;
+      break;
+    }
+
+  }
+
+  if (join_id < 0)
+    bft_error(__FILE__, __LINE__, 0,
+              _(" Periodicity number %d is not defined\n"
+                " %d periodicities are defined\n"),
+              *perio_num, cs_glob_n_join_perio);
+
+  assert(join != NULL);
+
+  cs_join_set_advanced_param(join,
+                             *mtf,
+                             *pmf,
+                             *tcm,
+                             *icm,
+                             *maxbrk,
+                             *max_sub_faces,
+                             *tml,
+                             *tmb,
+                             *tmr);
+
+}
+
+/*============================================================================
+ * Public function definitions
+ *===========================================================================*/
+
+/*----------------------------------------------------------------------------
+ * Define a translational periodicity
+ *
+ * parameters:
+ *   perio_num    <-- number related to the periodicity
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   verbosity    <-- level of verbosity required
+ *   trans        <-- translation vector
+ *----------------------------------------------------------------------------*/
+
+void
+cs_join_perio_add_translation(int            perio_num,
+                              const char    *sel_criteria,
+                              double         fraction,
+                              double         plane,
+                              int            verbosity,
+                              const double   trans[3])
+{
+  cs_int_t  tr_id;
+
+  assert((trans[0]*trans[0] + trans[1]*trans[1] + trans[2]*trans[2]) > 0.0);
+
+  if (cs_glob_n_join_perio == 0) {
+    assert(cs_glob_join_perio_builder == NULL);
+    cs_glob_join_perio_builder = _create_perio_builder();
+  }
+  else
+    _increment_perio_builder(cs_glob_join_perio_builder);
+
+  cs_glob_n_join_perio++;
+
+  /* Temporarily increment the number of periodicy in the mesh structure */
+  cs_glob_mesh->n_init_perio++;
+
+  tr_id =
+    fvm_periodicity_add_translation(cs_glob_join_perio_builder->periodicity,
+                                    cs_glob_n_join_perio,
+                                    trans);
+
+  _add_perio_join(perio_num + cs_glob_join_count,
+                  sel_criteria,
+                  fraction,
+                  plane,
+                  cs_glob_n_join_perio,
+                  verbosity);
+}
+
+/*----------------------------------------------------------------------------
+ * Define a rotational periodicity
+ *
+ * parameters:
+ *   perio_num    <-- number related to the periodicity
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   verbosity    <-- level of verbosity required
+ *   theta        <-- rotation angle (in degrees)
+ *   axis         <-- axis vector
+ *   invariant    <-- invariant point coordinates
+ *----------------------------------------------------------------------------*/
+
+void
+cs_join_perio_add_rotation(int            perio_num,
+                           const char    *sel_criteria,
+                           double         fraction,
+                           double         plane,
+                           int            verbosity,
+                           double         theta,
+                           const double   axis[3],
+                           const double   invariant[3])
+{
+  cs_int_t  tr_id;
+
+  assert(theta*theta > 0.0);
+  assert((axis[0]*axis[0] + axis[1]*axis[1] + axis[2]*axis[2]) > 0.0);
+
+  if (cs_glob_n_join_perio == 0) {
+    assert(cs_glob_join_perio_builder == NULL);
+    cs_glob_join_perio_builder = _create_perio_builder();
+  }
+  else
+    _increment_perio_builder(cs_glob_join_perio_builder);
+
+  cs_glob_n_join_perio++;
+
+  /* Temporarily increment the number of periodicy in the mesh structure */
+  cs_glob_mesh->n_init_perio++;
+
+  /* Add a tag to indicate the use of rotation */
+  cs_glob_mesh->have_rotation_perio = 1;
+
+  tr_id =
+    fvm_periodicity_add_rotation(cs_glob_join_perio_builder->periodicity,
+                                 cs_glob_n_join_perio,
+                                 theta,
+                                 axis,
+                                 invariant);
+
+  _add_perio_join(perio_num + cs_glob_join_count,
+                  sel_criteria,
+                  fraction,
+                  plane,
+                  cs_glob_n_join_perio,
+                  verbosity);
+}
+
+/*----------------------------------------------------------------------------
+ * Define a periodicity using a matrix
+ *
+ * parameters:
+ *   perio_num    <-- number related to the periodicity
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   verbosity    <-- level of verbosity required
+ *   matrix       <-- transformation matrix
+ *----------------------------------------------------------------------------*/
+
+void
+cs_join_perio_add_mixed(int            perio_num,
+                        const char    *sel_criteria,
+                        double         fraction,
+                        double         plane,
+                        int            verbosity,
+                        double         matrix[3][4])
+{
+  cs_int_t  tr_id;
+
+  if (cs_glob_n_join_perio == 0) {
+    assert(cs_glob_join_perio_builder == NULL);
+    cs_glob_join_perio_builder = _create_perio_builder();
+  }
+  else
+    _increment_perio_builder(cs_glob_join_perio_builder);
+
+  cs_glob_n_join_perio++;
+
+  /* Temporarily increment the number of periodicy in the mesh structure */
+  cs_glob_mesh->n_init_perio++;
+
+  /* Add a tag to indicate the use of rotation */
+  cs_glob_mesh->have_rotation_perio = 1;
+
+  tr_id =
+    fvm_periodicity_add_by_matrix(cs_glob_join_perio_builder->periodicity,
+                                  cs_glob_n_join_perio,
+                                  FVM_PERIODICITY_MIXED,
+                                  matrix);
+
+  _add_perio_join(perio_num + cs_glob_join_count,
+                  sel_criteria,
+                  fraction,
+                  plane,
+                  cs_glob_n_join_perio,
+                  verbosity);
+}
+
+/*----------------------------------------------------------------------------
+ * Duplicate and apply transformation to the selected faces and also to
+ * their related vertices. Modify compact_face_gnum to take into account
+ * new periodic faces and create a periodic vertex couple list.
+ *
+ * parameters:
+ *   this_join <-- high level join structure
+ *   jmesh     <-> local join mesh struct. to duplicate and transform
+ *   mesh      <-- pointer to a cs_mesh_t struct.
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_apply(cs_join_t          *this_join,
+                    cs_join_mesh_t     *jmesh,
+                    const cs_mesh_t    *mesh)
+{
+  cs_int_t  i, j, k, shift;
+  cs_real_t  matrix[3][4], xyz[4];
+
+  cs_join_param_t  param = this_join->param;
+  cs_join_select_t  *select = this_join->selection;
+  fvm_periodicity_t  *periodicity = cs_glob_join_perio_builder->periodicity;
+
+  const int  n_ranks = cs_glob_n_ranks;
+  const int  perio_id = param.perio_num - 1;
+  const int  n_init_vertices = jmesh->n_vertices;
+  const int  n_init_faces = jmesh->n_faces;
+
+  assert(perio_id > -1);
+
+  /* Retrieve related transformation */
+
+  fvm_periodicity_get_matrix(periodicity, 2*perio_id, matrix);
+
+  /* Duplicate and transform vertices */
+
+  jmesh->n_vertices *= 2;
+  jmesh->n_g_vertices *= 2;
+
+  BFT_REALLOC(jmesh->vertices, jmesh->n_vertices, cs_join_vertex_t);
+
+  shift = n_init_vertices;
+  for (i = 0; i < n_init_vertices; i++) {
+
+    /* Copy tolerance, coord, state and gnum to initialize new_vtx */
+
+    cs_join_vertex_t  new_vtx = jmesh->vertices[i];
+
+    for (j = 0; j < 3; j++) {
+      xyz[j] = new_vtx.coord[j];
+      new_vtx.coord[j] = 0.0;
+    }
+    xyz[3] = 1;
+
+    for (j = 0; j < 3; j++)
+      for (k = 0; k < 4; k++)
+        new_vtx.coord[j] += matrix[j][k]*xyz[k];
+
+    new_vtx.state = CS_JOIN_STATE_PERIO;
+    jmesh->vertices[shift++] = new_vtx;
+
+  }
+
+  /* Add a periodic vertex couple list */
+
+  select->n_couples = n_init_vertices;
+  BFT_MALLOC(select->per_v_couples, 2*n_init_vertices, fvm_gnum_t);
+
+  if (n_ranks > 1) { /* Global numbering update */
+
+    fvm_gnum_t  *gnum = NULL;
+    fvm_io_num_t  *io_num = NULL;
+    const fvm_gnum_t  *io_gnum = NULL;
+
+    BFT_MALLOC(gnum, n_init_vertices, fvm_gnum_t);
+
+    for (i = 0, shift = n_init_vertices; i < n_init_vertices; i++, shift++)
+      gnum[i] = jmesh->vertices[shift].gnum;
+
+    io_num = fvm_io_num_create(NULL, gnum, n_init_vertices, 0);
+    io_gnum = fvm_io_num_get_global_num(io_num);
+
+    for (i = 0, shift = n_init_vertices; i < n_init_vertices; i++, shift++) {
+      jmesh->vertices[shift].gnum = io_gnum[i] + mesh->n_g_vertices;
+      select->per_v_couples[2*i] = jmesh->vertices[i].gnum;
+      select->per_v_couples[2*i+1] = jmesh->vertices[shift].gnum;
+    }
+
+    fvm_io_num_destroy(io_num);
+    BFT_FREE(gnum);
+
+  }
+  else { /* Serial run */
+
+    for (i = 0, shift = n_init_vertices; i < n_init_vertices; i++, shift++) {
+      jmesh->vertices[shift].gnum = i + 1 + mesh->n_g_vertices;
+      select->per_v_couples[2*i] = jmesh->vertices[i].gnum;
+      select->per_v_couples[2*i+1] = jmesh->vertices[shift].gnum;
+    }
+
+  }
+
+  /* Duplicate and transform faces */
+
+  jmesh->n_faces *= 2;
+  jmesh->n_g_faces *= 2;
+
+  BFT_REALLOC(jmesh->face_vtx_idx, jmesh->n_faces + 1, cs_int_t);
+  BFT_REALLOC(jmesh->face_gnum, jmesh->n_faces, fvm_gnum_t);
+  BFT_REALLOC(jmesh->face_vtx_lst,
+              2*(jmesh->face_vtx_idx[n_init_faces]-1), cs_int_t);
+
+  for (i = 0; i < n_init_faces; i++) {
+
+    int  pfid = n_init_faces + i;
+    int  s = jmesh->face_vtx_idx[i] - 1;
+    int  e = jmesh->face_vtx_idx[i+1] - 1;
+    int  ps = jmesh->face_vtx_idx[pfid] - 1;
+    int  pe = jmesh->face_vtx_idx[pfid] - 1 + e - s;
+    fvm_gnum_t  new_gnum = 2*jmesh->face_gnum[i];
+
+    jmesh->face_gnum[i] = new_gnum - 1;
+    jmesh->face_gnum[pfid] = new_gnum;
+
+    for (j = s, shift = ps; j < e; j++, shift++)
+      jmesh->face_vtx_lst[shift] = jmesh->face_vtx_lst[j] + n_init_vertices;
+    jmesh->face_vtx_idx[pfid+1] =  pe + 1;
+
+  }
+
+  /* Modify cs_join_select_t structure */
+
+  for (i = 0; i < n_ranks + 1; i++)
+    select->compact_rank_index[i] *= 2;
+
+  for (i = 0; i < select->n_faces; i++)
+    select->compact_face_gnum[i] = 2*select->compact_face_gnum[i] - 1;
+
+  /* Order faces in mesh struct. by increasing global face number.
+     We have to be order in this way in order to keep an exact
+     redistribution (work_mesh) */
+
+  cs_join_mesh_face_order(jmesh);
+
+  if (param.verbosity > 1)
+    bft_printf(_("  Apply periodicity to the local join mesh structure\n"
+                 "  New number of faces to treat locally: %8d\n"),
+               jmesh->n_faces);
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf("\n Periodic vertex couples:\n");
+  for (i = 0; i < n_init_vertices; i++)
+    bft_printf(" %6d  (%9u, %9u)\n", i+1,
+               select->per_v_couples[2*i],  select->per_v_couples[2*i+1]);
+  bft_printf_flush();
+#endif
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf(_("\n  Selected faces for the joining operation:\n"));
+  for (i = 0; i < select->n_faces; i++)
+    bft_printf(" %9d | %9d | %10u | %10u\n",
+               i, select->faces[i], select->compact_face_gnum[i],
+               select->cell_gnum[i]);
+  bft_printf("\n");
+#endif
+
+}
+
+/*----------------------------------------------------------------------------
+ * Duplicate and apply transformation to the selected faces and also to
+ * their related vertices. Modify compact_face_gnum to take into account
+ * new periodic faces and create a periodic vertex couple list.
+ *
+ * parameters:
+ *   this_join          <-- pointer to a high level join structure
+ *   jmesh              <-> local join mesh struct. to duplicate and transform
+ *   p_work_jmesh       <-> distributed join mesh struct. on which operations
+ *                          take place
+ *   p_work_edges       <-> join edges struct. related to work_jmesh
+ *   init_max_vtx_gnum  <-- initial max. global numbering for vertices
+ *   n_g_new_vertices   <-- global number of vertices created during the
+ *                          intersection of edges
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_merge_back(cs_join_t          *this_join,
+                         cs_join_mesh_t     *jmesh,
+                         cs_join_mesh_t    **p_work_jmesh,
+                         cs_join_edges_t   **p_work_edges,
+                         fvm_gnum_t          init_max_vtx_gnum,
+                         fvm_gnum_t          n_g_new_vertices)
+{
+  cs_int_t  i, j, k, shift, vid, start, end, perio_start, perio_end;
+  cs_int_t  n_new_vertices, n_init_faces;
+  cs_real_t  matrix[3][4], xyz[4];
+  cs_bool_t  is_modified;
+  fvm_gnum_t  new_gnum;
+  cs_join_state_t  state;
+
+  cs_int_t  *new_f2v_idx = NULL, *new_f2v_lst = NULL, *vtag = NULL;
+  cs_int_t  *linked_id = NULL;
+  fvm_gnum_t  *gnum = NULL;
+  cs_bool_t  *f_state = NULL;
+  cs_join_mesh_t  *work_jmesh = *p_work_jmesh;
+  cs_join_edges_t  *work_edges = *p_work_edges;
+  cs_join_param_t  param = this_join->param;
+  cs_join_select_t  *select = this_join->selection;
+  cs_join_perio_builder_t  *builder = cs_glob_join_perio_builder;
+
+  const int  n_ranks = cs_glob_n_ranks;
+  const int  perio_id = param.perio_num - 1;
+
+  assert(perio_id > -1);
+  assert(builder != NULL);
+
+  /* Retrieve related back transformation */
+
+  fvm_periodicity_get_matrix(builder->periodicity, 2*perio_id+1, matrix);
+
+  BFT_MALLOC(linked_id, jmesh->n_vertices, cs_int_t);
+  BFT_MALLOC(gnum, jmesh->n_vertices, fvm_gnum_t);
+
+  for (i = 0; i < jmesh->n_vertices; i++) {
+    linked_id[i] = -1; /* Default: no link */
+    gnum[i] = jmesh->vertices[i].gnum; /* ordered list */
+  }
+
+  /* Linked vertex id by inverse transformation */
+
+  for (i = 0; i < select->n_couples; i++) {
+
+    j = cs_search_g_binary(jmesh->n_vertices,
+                           select->per_v_couples[2*i],
+                           gnum);
+
+    k = cs_search_g_binary(jmesh->n_vertices,
+                           select->per_v_couples[2*i+1],
+                           gnum);
+
+    linked_id[k] = j;
+
+  }
+
+  BFT_FREE(gnum);
+
+  /* Scan faces to detect new vertices in order to define and build a
+     new face->vertex index */
+
+  n_init_faces = jmesh->n_faces/2;
+
+  BFT_MALLOC(f_state, jmesh->n_faces, cs_bool_t);
+  BFT_MALLOC(new_f2v_idx, jmesh->n_faces + 1, cs_int_t);
+  BFT_MALLOC(vtag, jmesh->n_vertices, cs_int_t);
+
+  for (i = 0; i < jmesh->n_vertices; i++)
+    vtag[i] = 0;
+
+  for (i = 0; i < n_init_faces; i++) {
+
+    is_modified = false;
+    start = jmesh->face_vtx_idx[2*i]-1;
+    end = jmesh->face_vtx_idx[2*i+1]-1;
+    perio_start = end;
+    perio_end = jmesh->face_vtx_idx[2*i+2]-1;
+
+    for (j = perio_start; j < perio_end; j++) {
+
+      vid = jmesh->face_vtx_lst[j] - 1;
+      state = jmesh->vertices[vid].state;
+
+      if (state == CS_JOIN_STATE_PERIO_MERGE) {
+
+        is_modified = true;
+        vtag[vid] = -1;
+        assert(linked_id[vid] > -1);
+
+      }
+      else if (state == CS_JOIN_STATE_NEW) {
+
+        is_modified = true;
+        vtag[vid] = 1;
+        assert(linked_id[vid] == -1);
+
+      }
+      else if (state == CS_JOIN_STATE_MERGE) {
+
+        is_modified = true;
+        if (linked_id[vid] > -1) /* Update is enough */
+          vtag[vid] = -2;
+
+        else /* New vertex for the periodic face but not for
+                  the original intersected face.
+                  Add a new vertex for the related original face */
+
+          vtag[vid] = 2;
+
+      }
+
+    }
+
+    if (is_modified == true)
+      new_f2v_idx[2*i+1] = perio_end - perio_start;
+    else
+      new_f2v_idx[2*i+1] = end - start;
+    new_f2v_idx[2*i+2] = perio_end - perio_start;
+
+    f_state[2*i] = is_modified;
+    f_state[2*i+1] = false;
+
+  }
+
+  n_new_vertices = 0;
+  for (i = 0; i < jmesh->n_vertices; i++)
+    if (vtag[i] > 0)
+      n_new_vertices++;
+
+  BFT_REALLOC(jmesh->vertices,
+              jmesh->n_vertices + n_new_vertices,
+              cs_join_vertex_t);
+
+  /* Transform back new periodic vertices */
+
+  n_new_vertices = 0;
+
+  for (i = 0; i < jmesh->n_vertices; i++) {
+
+    if (vtag[i] > 0) { /* New vertex to transform back */
+
+      cs_join_vertex_t  new_vtx = jmesh->vertices[i];
+
+      for (j = 0; j < 3; j++) {
+        xyz[j] = new_vtx.coord[j];
+        new_vtx.coord[j] = 0.0;
+      }
+      xyz[3] = 1;
+
+      for (j = 0; j < 3; j++)
+        for (k = 0; k < 4; k++)
+          new_vtx.coord[j] += matrix[j][k]*xyz[k];
+
+      jmesh->vertices[jmesh->n_vertices + n_new_vertices] = new_vtx;
+      n_new_vertices++;
+      vtag[i] = jmesh->n_vertices + n_new_vertices;
+
+    }
+    else if (vtag[i] < 0) { /* Existing vertex to update */
+
+      cs_join_vertex_t  new_vtx = jmesh->vertices[linked_id[i]];
+
+      assert(   new_vtx.state != CS_JOIN_STATE_MERGE
+             || new_vtx.state != CS_JOIN_STATE_PERIO_MERGE);
+
+      for (j = 0; j < 3; j++) {
+        xyz[j] = jmesh->vertices[i].coord[j];
+        new_vtx.coord[j] = 0.0;
+      }
+      xyz[3] = 1;
+
+      for (j = 0; j < 3; j++)
+        for (k = 0; k < 4; k++)
+          new_vtx.coord[j] += matrix[j][k]*xyz[k];
+
+      new_vtx.state = CS_JOIN_STATE_MERGE;
+      jmesh->vertices[linked_id[i]] = new_vtx;
+
+    }
+
+  }
+
+  if (n_ranks > 1) { /* Global numbering update */
+
+    fvm_io_num_t  *io_num = NULL;
+    const fvm_gnum_t  *io_gnum = NULL;
+
+    BFT_MALLOC(gnum, n_new_vertices, fvm_gnum_t);
+
+    for (i = 0, shift = jmesh->n_vertices; i < n_new_vertices; i++, shift++)
+      gnum[i] = jmesh->vertices[shift].gnum;
+
+    io_num = fvm_io_num_create(NULL, gnum, n_new_vertices, 0);
+    io_gnum = fvm_io_num_get_global_num(io_num);
+
+    for (i = 0, shift = jmesh->n_vertices; i < n_new_vertices; i++, shift++) {
+      new_gnum = io_gnum[i] + init_max_vtx_gnum + n_g_new_vertices;
+      jmesh->vertices[shift].gnum = new_gnum;
+    }
+
+    jmesh->n_g_vertices += fvm_io_num_get_global_count(io_num);
+
+    fvm_io_num_destroy(io_num);
+    BFT_FREE(gnum);
+
+  }
+  else { /* Serial run */
+
+    for (i = 0, shift = jmesh->n_vertices; i < n_new_vertices; i++, shift++) {
+      new_gnum = i + 1 + init_max_vtx_gnum + n_g_new_vertices;
+      jmesh->vertices[shift].gnum = new_gnum;
+    }
+
+    jmesh->n_g_vertices += n_new_vertices;
+
+  }
+
+  /* Update face->vertex connectivity for original faces if needed
+     Copy connectivity for periodic faces */
+
+  new_f2v_idx[0] = 1;
+  for (i = 0; i < jmesh->n_faces; i++)
+    new_f2v_idx[i+1] += new_f2v_idx[i];
+
+  BFT_MALLOC(new_f2v_lst, new_f2v_idx[jmesh->n_faces] - 1, cs_int_t);
+
+  for (i = 0; i < n_init_faces; i++) {
+
+    start = jmesh->face_vtx_idx[2*i]-1;
+    end = jmesh->face_vtx_idx[2*i+1]-1;
+    perio_start = end;
+    perio_end = jmesh->face_vtx_idx[2*i+2]-1;
+
+    if (f_state[2*i] == false) { /* No modification to apply */
+
+      for (j = start, shift = new_f2v_idx[2*i] - 1;
+           j < perio_start; j++, shift++)
+        new_f2v_lst[shift] = jmesh->face_vtx_lst[j];
+
+    }
+    else { /* Modification to apply from the periodic face */
+
+      for (j = perio_start, shift = new_f2v_idx[2*i] - 1;
+           j < perio_end; j++, shift++) {
+
+        vid = jmesh->face_vtx_lst[j] - 1;
+        state = jmesh->vertices[vid].state;
+
+        if (   state == CS_JOIN_STATE_PERIO_MERGE
+            || state == CS_JOIN_STATE_PERIO)
+          new_f2v_lst[shift] = linked_id[vid] + 1;
+        else if (state == CS_JOIN_STATE_MERGE) {
+          if (linked_id[vid] > -1)
+            new_f2v_lst[shift] = linked_id[vid] + 1;
+          else
+            new_f2v_lst[shift] = vtag[vid];
+        }
+        else if (state == CS_JOIN_STATE_NEW)
+          new_f2v_lst[shift] = vtag[vid];
+        else
+          bft_error(__FILE__, __LINE__, 0,
+                    _("  Vertex state (%d) is not consistent.\n"
+                      "  Can not apply changes from periodic faces to"
+                      " original face.\n"
+                      "  Check your periodicity parameters.\n"), state);
+      }
+
+    } /* End of test on face state */
+
+    /* Copy periodic face connectivity */
+
+    for (j = perio_start, shift = new_f2v_idx[2*i+1] - 1;
+         j < perio_end; j++, shift++)
+      new_f2v_lst[shift] = jmesh->face_vtx_lst[j];
+
+  } /* End of loop on initial faces */
+
+  /* Add new vertices to the periodic vertex list */
+
+  if (param.verbosity > 2)
+  bft_printf("  Add locally %d new vertices for periodicity\n",
+             n_new_vertices);
+
+  shift = select->n_couples;
+  select->n_couples += n_new_vertices;
+  BFT_REALLOC(select->per_v_couples, 2*select->n_couples, fvm_gnum_t);
+
+  for (i = 0; i < jmesh->n_vertices; i++) {
+    if (vtag[i] > 0) {
+      vid = vtag[i] - 1;
+      select->per_v_couples[2*shift] = jmesh->vertices[vid].gnum;
+      select->per_v_couples[2*shift+1] = jmesh->vertices[i].gnum;
+      shift++;
+    }
+  }
+
+  BFT_FREE(vtag);
+  BFT_FREE(linked_id);
+  BFT_FREE(f_state);
+
+  /* Reshape join_mesh structure */
+
+  BFT_FREE(jmesh->face_vtx_idx);
+  BFT_FREE(jmesh->face_vtx_lst);
+
+  jmesh->face_vtx_idx = new_f2v_idx;
+  jmesh->face_vtx_lst = new_f2v_lst;
+  jmesh->n_vertices += n_new_vertices;
+
+  /* Update now work_jmesh by exchanging jmesh over the ranks */
+
+  _redistribute_mesh(param,
+                     select->compact_rank_index,
+                     jmesh,
+                     &work_jmesh);
+
+  /* Define a new cs_join_edges_t structure related to work_jmesh */
+
+  cs_join_mesh_destroy_edges(&work_edges);
+  work_edges = cs_join_mesh_define_edges(work_jmesh);
+
+  /* Reshape join_mesh structure by deleting periodic faces */
+
+  shift = 0;
+
+  for (i = 0; i < n_init_faces; i++) {
+
+    jmesh->face_gnum[i] = jmesh->face_gnum[2*i];
+
+    for (j = jmesh->face_vtx_idx[2*i]-1; j < jmesh->face_vtx_idx[2*i+1]-1; j++)
+      jmesh->face_vtx_lst[shift++] = jmesh->face_vtx_lst[j];
+
+    jmesh->face_vtx_idx[i+1] = shift + 1;
+
+  }
+
+  BFT_REALLOC(jmesh->face_gnum, n_init_faces, fvm_gnum_t);
+  BFT_REALLOC(jmesh->face_vtx_idx, n_init_faces + 1, cs_int_t);
+  BFT_REALLOC(jmesh->face_vtx_lst, shift, cs_int_t);
+
+  jmesh->n_faces = n_init_faces;
+  jmesh->n_g_faces /= 2;
+
+  /* Return pointer */
+
+  *p_work_jmesh = work_jmesh;
+  *p_work_edges = work_edges;
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf("\n Periodic vertex couples:\n");
+  for (i = 0; i < select->n_couples; i++)
+    bft_printf(" %6d  (%9u, %9u)\n", i+1,
+               select->per_v_couples[2*i], select->per_v_couples[2*i+1]);
+  bft_printf_flush();
+#endif
+
+}
+
+/*----------------------------------------------------------------------------
+ * Duplicate and apply transformation to the selected faces and also to
+ * their related vertices. Update jmesh structure.
+ * Define a new n2o_hist.
+ *
+ * parameters:
+ *   this_join  <-- pointer to a high level join structure
+ *   jmesh      <-> local join mesh struct. to duplicate and transform
+ *   mesh       <-- pointer to a cs_mesh_t structure
+ *   o2n_hist   <-- old global face -> new local face numbering
+ *   p_n2o_hist <-- new global face -> old local face numbering
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_split_back(cs_join_t          *this_join,
+                         cs_join_mesh_t     *jmesh,
+                         cs_mesh_t          *mesh,
+                         cs_join_gset_t     *o2n_hist,
+                         cs_join_gset_t    **p_n2o_hist)
+{
+  int  i, j, k, shift, vid, fid, start, end, perio_start, perio_end;
+  int  n_final_faces, n1_faces, n2_faces;
+  int  shift1, shift2, shift3, shift4;
+  int  n_sub_ori, n_sub_per, n_contrib, n_couples;
+  fvm_gnum_t  n2_g_faces;
+
+  int  n_vertices_to_add = 0, n_g_vertices_to_add = 0;
+  cs_int_t  *new_f2v_idx = NULL, *new_f2v_lst = NULL;
+  cs_int_t  *linked_id = NULL, *f_tag = NULL;
+  fvm_gnum_t  *gnum = NULL, *f2_gnum = NULL, *new_fgnum = NULL;
+  cs_join_gset_t  *new_history = NULL, *n2o_hist = *p_n2o_hist;
+
+  cs_join_param_t  param = this_join->param;
+  cs_join_select_t  *select = this_join->selection;
+  cs_join_perio_builder_t  *builder = cs_glob_join_perio_builder;
+
+  const int  n_ranks = cs_glob_n_ranks;
+  const int  perio_id = param.perio_num - 1;
+
+  assert(perio_id > -1);
+  assert(builder != NULL);
+
+  /* Detect periodic face to delete and associate a tag for each new face */
+
+  BFT_MALLOC(f_tag, jmesh->n_faces, cs_int_t);
+
+  assert(n2o_hist->n_elts == jmesh->n_faces);
+  n_couples = 0;
+
+  for (i = 0; i < n2o_hist->n_elts; i++) {
+
+    start = n2o_hist->index[i];
+    end = n2o_hist->index[i+1];
+    n_contrib = end - start;
+
+    if (n_contrib == 1) { /* New face remains a border face */
+
+      if (n2o_hist->g_list[start]%2 == 0)
+        f_tag[i] = 0; /* To delete without transferring back face connect. */
+      else
+        f_tag[i] = 1; /* To keep. Original face */
+
+    }
+    else if (n_contrib == 2) { /* New face becomes an interior face */
+
+      if (n2o_hist->g_list[start]%2 == 0) { /* Old periodic face */
+
+        assert(n2o_hist->g_list[start+1]%2 == 1); /* Associated face should
+                                                     be an old original face */
+
+        f_tag[i] = -1; /* To keep with transferring back face connect. */
+        n_couples++;
+
+      }
+      else { /* Old original face */
+
+        assert(n2o_hist->g_list[start]%2 == 1);
+        assert(n2o_hist->g_list[start+1]%2 == 0); /* Associated face should
+                                                     be an old periodic face */
+
+        f_tag[i] = -1; /* To keep with transferring back face connect. */
+        n_couples++;
+
+      }
+
+    }
+    else { /* n_contrib > 2 => remains a border face and keep the new face
+              if not all the old faces are periodic */
+
+      cs_bool_t  have_perio = true;
+
+      f_tag[i] = 0; /* Initialize as if we want to delete the new face */
+
+      for (j = start; j < end; j++)
+        if (n2o_hist->g_list[j]%2 == 1) /* Old original face are taking part
+                                           in the composition of the new
+                                           face */
+          have_perio = false;
+
+      if (have_perio == false)
+        f_tag[i] = 1; /* To keep without transferring back face connect. */
+    }
+
+  } /* End of loop on new faces */
+
+  /* Loop over old faces and change the current tag for the new faces
+     according to the number of subdivisions applied to the original
+     faces */
+
+  for (i = 0; i < select->n_faces; i++) {
+
+    start = o2n_hist->index[2*i];
+    end = o2n_hist->index[2*i+1];
+    perio_start = end;
+    perio_end = o2n_hist->index[2*i+2];
+
+    n_sub_ori = end - start;
+    n_sub_per = perio_end - perio_start;
+
+    assert(n_sub_per > 0 && n_sub_ori > 0);
+
+    if (n_sub_ori == 1 && n_sub_per > 1) {
+
+      fid = cs_search_g_binary(jmesh->n_faces,
+                               o2n_hist->g_list[start],
+                               jmesh->face_gnum);
+
+      f_tag[fid] = 2; /* Original face to delete and to replace by
+                         a set of new sub-faces */
+
+      for (j = perio_start; j < perio_end; j++) {
+
+        fid = cs_search_g_binary(jmesh->n_faces,
+                                 o2n_hist->g_list[j],
+                                 jmesh->face_gnum);
+
+        assert(fid > -1);
+
+        if (f_tag[fid] == 0)
+          f_tag[fid] = -2; /* Switch tag:
+                              Will be deleted after periodicity application */
+
+      }
+
+    } /* n_sub_ori == 1 && n_sub_per > 1 */
+
+    else if (n_sub_ori == 1 && n_sub_per == 1) {
+
+      fid = cs_search_g_binary(jmesh->n_faces,
+                               o2n_hist->g_list[perio_start],
+                               jmesh->face_gnum);
+
+      if (n2o_hist->index[fid+1] - n2o_hist->index[fid] == 2) {
+
+        assert(f_tag[fid] == -1); /* New face to keep with transferring
+                                     back face connectivity */
+
+        fid = cs_search_g_binary(jmesh->n_faces,
+                                 o2n_hist->g_list[start],
+                                 jmesh->face_gnum);
+
+
+        assert(fid > -1);
+        f_tag[fid] = 2; /* Original face to delete and to replace by
+                           a set the new sub-face */
+
+      }
+
+    }
+
+  } /* End of loop on old faces */
+
+  /* Count the final number of new subfaces */
+
+  n_final_faces = 0;
+  for (i = 0; i < jmesh->n_faces; i++) {
+
+    if (f_tag[i] == 1 || f_tag[i] == -2)
+      n_final_faces++;
+    else if (f_tag[i] == -1)
+      n_final_faces += 2;
+
+  }
+
+  /* Define a global number for each face to transfer back by periodicity */
+
+  n2_faces = 0;
+  for (i = 0; i < jmesh->n_faces; i++)
+    if (f_tag[i] < 0)
+      n2_faces++;
+  n2_g_faces = n2_faces;
+
+  BFT_MALLOC(f2_gnum, n2_faces, fvm_gnum_t);
+
+  if (n_ranks > 1) { /* Parallel run */
+
+    fvm_io_num_t  *io_num = NULL;
+    const fvm_gnum_t  *io_gnum = NULL;
+
+    n2_faces = 0;
+    for (i = 0; i < jmesh->n_faces; i++)
+      if (f_tag[i] < 0)
+        f2_gnum[n2_faces++] = jmesh->face_gnum[i];
+
+    io_num = fvm_io_num_create(NULL, f2_gnum, n2_faces, 0);
+    io_gnum = fvm_io_num_get_global_num(io_num);
+
+    for (i = 0; i < n2_faces; i++)
+      f2_gnum[i] = jmesh->n_g_faces + io_gnum[i];
+
+    n2_g_faces = fvm_io_num_get_global_count(io_num);
+
+    fvm_io_num_destroy(io_num);
+
+  }
+  else { /* Serial run */
+
+    n2_faces = 0;
+    for (i = 0; i < jmesh->n_faces; i++) {
+      if (f_tag[i] < 0) {
+        f2_gnum[n2_faces] = jmesh->n_faces + n2_faces + 1;
+        n2_faces++;
+      }
+    }
+
+  }
+
+  /* Define the new face -> vertex index and the new global face numbering */
+
+  BFT_MALLOC(new_f2v_idx, n_final_faces + 1, cs_int_t);
+  BFT_MALLOC(new_fgnum, n_final_faces, fvm_gnum_t);
+
+  new_history = cs_join_gset_create(n_final_faces);
+  new_history->n_g_elts = new_history->n_elts;
+
+  n1_faces = 0;
+
+  for (i = 0; i < jmesh->n_faces; i++) {
+    if (f_tag[i] == 1 || f_tag[i] == -1) {
+
+      new_f2v_idx[n1_faces+1] =
+        jmesh->face_vtx_idx[i+1] - jmesh->face_vtx_idx[i];
+      new_fgnum[n1_faces] = jmesh->face_gnum[i];
+
+      new_history->index[n1_faces+1] =
+        n2o_hist->index[i+1] - n2o_hist->index[i];
+
+      n1_faces++;
+
+    }
+  }
+
+  shift = n1_faces;
+  n2_faces = 0;
+  for (i = 0; i < jmesh->n_faces; i++) {
+    if (f_tag[i] < 0) {
+
+      assert(f_tag[i] == -1 || f_tag[i] == -2);
+
+      new_f2v_idx[shift + 1] =
+        jmesh->face_vtx_idx[i+1] - jmesh->face_vtx_idx[i];
+      new_fgnum[shift] = f2_gnum[n2_faces];
+
+      new_history->index[shift+1] =
+        n2o_hist->index[i+1] - n2o_hist->index[i];
+
+      n2_faces++;
+      shift++;
+
+    }
+  }
+
+  assert(n1_faces + n2_faces == n_final_faces);
+
+  /* Detect if there are new vertices to add to the jmesh definition */
+
+  BFT_MALLOC(gnum, jmesh->n_vertices, fvm_gnum_t);
+  BFT_MALLOC(linked_id, jmesh->n_vertices, cs_int_t);
+
+  for (i = 0; i < jmesh->n_vertices; i++) {
+    linked_id[i] = -1; /* Default: no link */
+    gnum[i] = jmesh->vertices[i].gnum; /* ordered list */
+  }
+
+  for (i = 0; i < select->n_couples; i++) {
+
+    j = cs_search_g_binary(jmesh->n_vertices,
+                           select->per_v_couples[2*i],
+                           gnum);
+
+    k = cs_search_g_binary(jmesh->n_vertices,
+                           select->per_v_couples[2*i+1],
+                           gnum);
+
+    linked_id[k] = j;
+
+  }
+
+  BFT_FREE(f2_gnum);
+  BFT_FREE(gnum);
+
+  for (i = 0; i < jmesh->n_faces; i++) {
+    if (f_tag[i] < 0) { /* Periodicity to transfer back */
+
+      for (j = jmesh->face_vtx_idx[i]-1; j < jmesh->face_vtx_idx[i+1]-1; j++) {
+        vid = jmesh->face_vtx_lst[j] - 1;
+
+        if (linked_id[vid] == -1)
+          linked_id[vid] = -2; /* Have to get the related id. Add a new
+                                  vertex */
+
+      }
+
+    }
+  } /* End of loop on new faces */
+
+  n_vertices_to_add = 0;
+  for (i = 0; i < jmesh->n_vertices; i++)
+    if (linked_id[i] == -2)
+      n_vertices_to_add += 1;
+
+  if (n_vertices_to_add > 0) {
+
+    cs_int_t  i1, i2;
+    cs_real_t  matrix[3][4], xyz[4];
+
+    BFT_REALLOC(jmesh->vertices, jmesh->n_vertices + n_vertices_to_add,
+                cs_join_vertex_t);
+    BFT_REALLOC(linked_id,  jmesh->n_vertices + n_vertices_to_add, cs_int_t);
+
+    /* Retrieve related back transformation */
+
+    fvm_periodicity_get_matrix(builder->periodicity, 2*perio_id+1, matrix);
+
+    n_vertices_to_add = 0;
+    for (i1 = 0; i1 < jmesh->n_vertices; i1++) {
+      if (linked_id[i1] == -2) {
+
+        cs_join_vertex_t  new_vtx = jmesh->vertices[i1];
+
+        i2 = jmesh->n_vertices + n_vertices_to_add;
+        linked_id[i1] = i2;
+
+        for (k = 0; k < 3; k++) {
+          xyz[k] = new_vtx.coord[k];
+          new_vtx.coord[k] = 0.0;
+        }
+        xyz[3] = 1;
+
+        for (j = 0; j < 3; j++)
+          for (k = 0; k < 4; k++)
+            new_vtx.coord[j] += matrix[j][k]*xyz[k];
+
+        jmesh->vertices[i2] = new_vtx;
+        n_vertices_to_add += 1;
+
+      }
+    }
+
+  } /* n_vertices_to_add > 0 */
+
+  /* Define a global vertex num for the new added vertices */
+
+#if defined(HAVE_MPI)
+  if (n_ranks > 1) {
+
+    fvm_io_num_t  *io_num = NULL;
+    const fvm_gnum_t  *io_gnum = NULL;
+
+    MPI_Allreduce(&n_vertices_to_add, &n_g_vertices_to_add, 1, MPI_INT,
+                  MPI_SUM, cs_glob_mpi_comm);
+
+    /* Define global numbering for vertices to add
+       and keep relation between periodic couples */
+
+    if (n_g_vertices_to_add > 0) {
+
+      BFT_MALLOC(gnum, n_vertices_to_add, fvm_gnum_t);
+
+      for (i = 0, shift = jmesh->n_vertices; i < n_vertices_to_add;
+           i++, shift++)
+        gnum[i] = jmesh->vertices[shift].gnum;
+
+      io_num = fvm_io_num_create(NULL, gnum, n_vertices_to_add, 0);
+      io_gnum = fvm_io_num_get_global_num(io_num);
+
+      for (i = 0, shift = jmesh->n_vertices; i < n_vertices_to_add;
+           i++, shift++)
+        jmesh->vertices[shift].gnum = io_gnum[i] + mesh->n_g_vertices;
+
+      n_g_vertices_to_add = fvm_io_num_get_global_count(io_num);
+      jmesh->n_g_vertices += n_g_vertices_to_add;
+
+      fvm_io_num_destroy(io_num);
+      BFT_FREE(gnum);
+
+    }
+
+  }
+#endif
+
+  if (n_ranks == 1 && n_vertices_to_add > 0) {
+
+    for (i = 0, shift = jmesh->n_vertices; i < n_vertices_to_add; i++, shift++)
+      jmesh->vertices[shift].gnum = i + 1 + mesh->n_g_vertices;
+
+    jmesh->n_g_vertices += n_vertices_to_add;
+
+  }
+
+  jmesh->n_vertices += n_vertices_to_add;
+
+  new_f2v_idx[0] = 1;
+  new_history->index[0] = 0;
+
+  for (i = 0; i < n_final_faces; i++) {
+    new_f2v_idx[i+1] += new_f2v_idx[i];
+    new_history->index[i+1] += new_history->index[i];
+  }
+
+  BFT_MALLOC(new_f2v_lst, new_f2v_idx[n_final_faces] - 1, cs_int_t);
+  BFT_MALLOC(new_history->g_list, new_history->index[new_history->n_elts],
+             fvm_gnum_t);
+
+  /* Define a new face connectivity and a new face history */
+
+  shift1 = 0; /*kept faces in face connect. */
+  shift2 = new_f2v_idx[n1_faces] - 1; /* transfered faces in face connect. */
+
+  shift3 = 0; /* kept faces in face history */
+  shift4 = new_history->index[n1_faces]; /* transfered faces in face history */
+
+  /* Store periodic couples. First in local join numbering.
+     Will move next to a global numbering (after interior face add) */
+
+  builder->n_perio_couples[perio_id] = n_couples;
+  BFT_MALLOC(builder->perio_couples[perio_id], 2*n_couples, fvm_gnum_t);
+
+  n2_faces = n1_faces;
+  n1_faces = 0;
+  n_couples = 0;
+
+  for (i = 0; i < jmesh->n_faces; i++) {
+
+    start = jmesh->face_vtx_idx[i]-1;
+    end = jmesh->face_vtx_idx[i+1]-1;
+
+    if (f_tag[i] == 1) { /* Original face to keep */
+
+      for (j = start; j < end; j++)
+        new_f2v_lst[shift1++] = jmesh->face_vtx_lst[j];
+
+      for (j = n2o_hist->index[i]; j < n2o_hist->index[i+1]; j++)
+        new_history->g_list[shift3++] = n2o_hist->g_list[j];
+
+      n1_faces++;
+
+    }
+    else if (f_tag[i] == -1) { /* Periodic face to keep and to transfer back */
+
+      /* Store periodic face couple */
+
+      n1_faces++;
+      n2_faces++;
+      builder->perio_couples[perio_id][2*n_couples] = n2_faces;
+      builder->perio_couples[perio_id][2*n_couples+1] = n1_faces;
+      n_couples++;
+
+      /* Define face connectivity */
+
+      for (j = start; j < end; j++) {
+        vid = jmesh->face_vtx_lst[j] - 1;
+        assert(linked_id[vid] > -1);
+        new_f2v_lst[shift1++] = vid + 1;
+        new_f2v_lst[shift2++] = linked_id[vid] + 1;
+      }
+
+      /* Define new old->new face history */
+
+      for (j = n2o_hist->index[i]; j < n2o_hist->index[i+1]; j++) {
+
+        if (n2o_hist->g_list[j]%2 == 0) { /* Periodic face */
+          new_history->g_list[shift3++] = n2o_hist->g_list[j];
+          /* Original face related to this periodic one */
+          new_history->g_list[shift4++] = n2o_hist->g_list[j] - 1;
+        }
+        else { /* Original face */
+          new_history->g_list[shift3++] = n2o_hist->g_list[j];
+          /* Periodic face related to this original one */
+          new_history->g_list[shift4++] = n2o_hist->g_list[j] + 1;
+        }
+
+      }
+
+    }
+    else if (f_tag[i] == -2) { /* Periodic face to transfer back */
+
+      n2_faces++;
+
+      for (j = start; j < end; j++) {
+        vid = jmesh->face_vtx_lst[j] - 1;
+        assert(linked_id[vid] > -1);
+        new_f2v_lst[shift2++] = linked_id[vid] + 1;
+      }
+
+      for (j = n2o_hist->index[i]; j < n2o_hist->index[i+1]; j++) {
+
+        assert(n2o_hist->g_list[j]%2 == 0); /* Periodic face */
+
+        /* Original face related to this periodic one */
+        new_history->g_list[shift4++] = n2o_hist->g_list[j] - 1;
+
+      }
+
+    }
+
+  } /* End of loop on faces */
+
+  BFT_FREE(linked_id);
+  BFT_FREE(f_tag);
+
+  /* Reshape join_mesh structure */
+
+  jmesh->n_faces = n_final_faces;
+  jmesh->n_g_faces = jmesh->n_faces;
+
+  BFT_FREE(jmesh->face_gnum);
+  BFT_FREE(jmesh->face_vtx_idx);
+  BFT_FREE(jmesh->face_vtx_lst);
+
+  jmesh->face_gnum = new_fgnum;
+  jmesh->face_vtx_idx = new_f2v_idx;
+  jmesh->face_vtx_lst = new_f2v_lst;
+
+  if (n_ranks > 1) { /* Update global face number */
+
+    fvm_io_num_t  *io_num = NULL;
+    const fvm_gnum_t  *io_gnum = NULL;
+
+    io_num = fvm_io_num_create(NULL, jmesh->face_gnum, jmesh->n_faces, 0);
+    io_gnum = fvm_io_num_get_global_num(io_num);
+
+    for (i = 0; i < jmesh->n_faces; i++) {
+      jmesh->face_gnum[i] = io_gnum[i];
+      new_history->g_elts[i] = io_gnum[i];
+    }
+
+    jmesh->n_g_faces = fvm_io_num_get_global_count(io_num);
+    new_history->n_g_elts = jmesh->n_g_faces;
+
+    fvm_io_num_destroy(io_num);
+    BFT_FREE(gnum);
+
+  }
+  else { /* Serial run */
+
+    for (i = 0; i < jmesh->n_faces; i++) {
+      jmesh->face_gnum[i] = i+1;
+      new_history->g_elts[i] = i+1;
+    }
+
+  }
+
+  /* Return pointer */
+
+  cs_join_gset_destroy(&n2o_hist);
+
+  *p_n2o_hist = new_history;
+
+}
+
+/*----------------------------------------------------------------------------
+ * Define a list of coupled faces by periodicty in global numbering.
+ * For parallel runs:
+ *  - remove isolated periodic faces in the mesh definition
+ *  - define a consistent face connectivity in order to prepare the building
+ *    of periodic vertex couples
+ *
+ *
+ * parameters:
+ *   param      <-- set of parameters for the joining operation
+ *   n_ii_faces <-- initial local number of interior faces
+ *   face_type  <-- type of faces in join mesh (interior or border ...)
+ *   jmesh      <-- pointer on a cs_join_mesh_t struct.
+ *   mesh       <-> pointer on a cs_mesh_t struct.
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_split_update(cs_join_param_t             param,
+                           cs_int_t                    n_ii_faces,
+                           const cs_join_face_type_t   face_type[],
+                           const cs_join_mesh_t       *jmesh,
+                           cs_mesh_t                  *mesh)
+{
+  int  i, shift;
+
+  fvm_gnum_t  *o2n_num = NULL;
+  cs_join_perio_builder_t  *builder = cs_glob_join_perio_builder;
+
+  const int  n_j_faces = jmesh->n_faces;
+  const int  n_ranks = cs_glob_n_ranks;
+  const int  perio_id = param.perio_num - 1;
+
+  assert(perio_id > -1);
+  assert(builder != NULL);
+
+  /* Initialize o2n_num */
+
+  BFT_MALLOC(o2n_num, n_j_faces, fvm_gnum_t);
+
+  for (i = 0; i < n_j_faces; i++)
+    o2n_num[i] = 0;
+
+  if (n_ranks == 1) {
+
+    shift = n_ii_faces + 1;
+    for (i = 0; i < n_j_faces; i++)
+      if (face_type[i] == CS_JOIN_FACE_INTERIOR)
+        o2n_num[i] = shift++;
+
+  }
+  else { /* n_ranks > 1 */
+
+    shift = n_ii_faces;
+    for (i = 0; i < n_j_faces; i++)
+      if (face_type[i] == CS_JOIN_FACE_INTERIOR)
+        o2n_num[i] = mesh->global_i_face_num[shift++];
+
+  }
+
+  /* Apply new numbering */
+
+  for (i = 0; i < builder->n_perio_couples[perio_id]; i++) {
+
+    fvm_gnum_t  old1 = builder->perio_couples[perio_id][2*i] - 1;
+    fvm_gnum_t  old2 = builder->perio_couples[perio_id][2*i+1] - 1;
+
+    assert(o2n_num[old1] > 0);
+    assert(o2n_num[old2] > 0);
+
+    builder->perio_couples[perio_id][2*i] = o2n_num[old1];
+    builder->perio_couples[perio_id][2*i+1] = o2n_num[old2];
+
+  }
+
+  BFT_FREE(o2n_num);
+
+  if (n_ranks > 1) /* Remove isolated periodic face for the current mesh */
+    _perio_face_clean(param, mesh);
+
+}
+
+/*----------------------------------------------------------------------------
+ * Use periodic face couples in cs_glob_join_perio_builder to define
+ * cs_glob_mesh_builder.
+ * Free all elements which can be freed.
+ * Transfer data to cs_glob_mesh and cs_glob_mesh_builder.
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_perio_transfer_builder(void)
+{
+  int  i, j, k;
+
+  cs_join_perio_builder_t  *p_builder = cs_glob_join_perio_builder;
+  cs_mesh_builder_t  *m_builder = cs_glob_mesh_builder;
+  cs_mesh_t  *mesh = cs_glob_mesh;
+
+  const int  n_perio = cs_glob_n_join_perio;
+  const int  n_ranks = cs_glob_n_ranks;
+
+  /* Periodicity is either defined by a joining operation, either defined
+     by a preprocessor command. One cannot use the way together */
+
+  assert(m_builder != NULL);
+  assert(m_builder->per_face_idx == NULL);
+  assert(m_builder->per_face_lst == NULL);
+  assert(m_builder->per_rank_lst == NULL);
+  assert(p_builder != NULL);
+  assert(mesh != NULL);
+  assert(n_perio == p_builder->n_perio);
+  assert(mesh->periodicity == NULL); /* No periodicity already defined by
+                                        the preprocessor */
+
+  /* Transfer data to mesh structure */
+
+  mesh->n_init_perio = n_perio;
+  mesh->periodicity = p_builder->periodicity;
+
+  /* Define mesh builder */
+
+  BFT_MALLOC(m_builder->per_face_idx, n_perio + 1, cs_int_t);
+
+  m_builder->per_face_idx[0] = 0;
+  for (i = 0; i < n_perio; i++)
+    m_builder->per_face_idx[i+1] =  m_builder->per_face_idx[i]
+                                  + p_builder->n_perio_couples[i];
+
+  BFT_MALLOC(m_builder->per_face_lst, 2*m_builder->per_face_idx[n_perio],
+             cs_int_t);
+
+  if (n_ranks == 1) {
+
+    for (i = 0, k = 0; i < n_perio; i++) {
+      for (j = 0; j < p_builder->n_perio_couples[i]; j++, k++) {
+        m_builder->per_face_lst[2*k] = p_builder->perio_couples[i][2*j];
+        m_builder->per_face_lst[2*k+1] = p_builder->perio_couples[i][2*j+1];
+      }
+    }
+
+  }
+  else { /* Parallel run: n_ranks > 1 */
+
+    fvm_interface_set_t *face_ifs = NULL;
+    fvm_lnum_t  *periodicity_num = NULL;
+
+    BFT_MALLOC(periodicity_num, n_perio, fvm_lnum_t);
+    BFT_MALLOC(m_builder->per_rank_lst, m_builder->per_face_idx[n_perio],
+               cs_int_t);
+
+    for (i = 0; i < n_perio; i++)
+      periodicity_num[i] = i+1;
+
+    face_ifs = fvm_interface_set_create(mesh->n_i_faces,
+                                        NULL,
+                                        mesh->global_i_face_num,
+                                        mesh->periodicity,
+                                        n_perio,
+                                        periodicity_num,
+                                        p_builder->n_perio_couples,
+              (const fvm_gnum_t **const)p_builder->perio_couples);
+
+#if defined(HAVE_MPI) /* Algo. similar to the one in cs_preprocessor_data.c */
+    _extract_perio_couples(n_perio, m_builder, face_ifs);
+#endif
+
+    /* Keep face interface to build the future i_face_cells connect. */
+
+    m_builder->face_ifs = face_ifs;
+
+    /* Free memory */
+
+    BFT_FREE(periodicity_num);
+
+  }
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+ {
+   int  perio_id;
+
+   const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
+
+   bft_printf("\n  Dump periodic data built from the joining algorithm\n");
+
+   for (perio_id = 0; perio_id < n_perio; perio_id++) {
+
+     int  start_id = m_builder->per_face_idx[perio_id];
+     int  end_id = m_builder->per_face_idx[perio_id+1];
+
+     bft_printf("\n  Perio id: %4d - Number of elements: %7d "
+                "(start: %7d - end: %7d)\n",
+                perio_id, end_id-start_id, start_id, end_id);
+     bft_printf("   id    | 1st face | 2nd face | associated rank\n");
+
+     for (i = start_id; i < end_id; i++) {
+       if (cs_glob_n_ranks > 1) {
+
+         int  f1_id = CS_ABS(m_builder->per_face_lst[2*i]) -1;
+         int  f2_id = CS_ABS(m_builder->per_face_lst[2*i+1]) -1;
+
+         bft_printf("%8d | %8d (%9u) | %8d (%9u) | %5d\n",
+                    i, m_builder->per_face_lst[2*i],
+                    cs_glob_mesh->global_i_face_num[f1_id],
+                    m_builder->per_face_lst[2*i+1],
+                    (m_builder->per_rank_lst[i]-1 == local_rank ?
+                     cs_glob_mesh->global_i_face_num[f2_id] : 0),
+                    m_builder->per_rank_lst[i]-1);
+
+       }
+       else
+         bft_printf("%8d | %10d | %10d | %6d\n",
+                    i, m_builder->per_face_lst[2*i],
+                    m_builder->per_face_lst[2*i+1],
+                    local_rank);
+     }
+     bft_printf_flush();
+
+   }
+
+ }
+#endif
+
+  _delete_perio_builder(&p_builder);
+
+}
+
+/*---------------------------------------------------------------------------*/
+
+END_C_DECLS
+
diff --git a/src/base/cs_join_perio_f2c.f90 b/src/base/cs_join_perio_f2c.f90
new file mode 100644
index 0000000..639bb1e
--- /dev/null
+++ b/src/base/cs_join_perio_f2c.f90
@@ -0,0 +1,235 @@
+!-------------------------------------------------------------------------------
+
+!     This file is part of the Code_Saturne Kernel, element of the
+!     Code_Saturne CFD tool.
+
+!     Copyright (C) 1998-2010 EDF S.A., France
+
+!     contact: saturne-support at edf.fr
+
+!     The Code_Saturne Kernel is free software; you can redistribute it
+!     and/or modify it under the terms of the GNU General Public License
+!     as published by the Free Software Foundation; either version 2 of
+!     the License, or (at your option) any later version.
+
+!     The Code_Saturne Kernel 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 General Public License for more details.
+
+!     You should have received a copy of the GNU General Public License
+!     along with the Code_Saturne Kernel; if not, write to the
+!     Free Software Foundation, Inc.,
+!     51 Franklin St, Fifth Floor,
+!     Boston, MA  02110-1301  USA
+
+!-------------------------------------------------------------------------------
+
+subroutine defptr &
+!================
+
+ ( numper, crit, fract, plane, iwarnj, tx, ty, tz )
+
+!===============================================================================
+! Purpose:
+! -------
+
+! Definition of a periodicity of translation.
+
+!-------------------------------------------------------------------------------
+! Arguments
+!__________________.____._____.________________________________________________.
+! name             !type!mode ! role                                           !
+!__________________!____!_____!________________________________________________!
+! numper           ! i  ! <-- ! periodicity number                             !
+! crit             ! a  ! <-- ! selection criteria for the border faces to     !
+!                  !    !     ! transform                                      !
+! fract            ! r  ! <-- ! fraction parameter                             !
+! plane            ! r  ! <-- ! face coplanarity parameter                     !
+! iwarnj           ! i  ! <-- ! verbosity level                                !
+! tx               ! r  ! <-- ! X coordinate of the translation vector         !
+! ty               ! r  ! <-- ! Y coordinate of the translation vector         !
+! tz               ! r  ! <-- ! Z coordinate of the translation vector         !
+!__________________!____!_____!________________________________________________!
+
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
+!===============================================================================
+
+implicit none
+
+!===============================================================================
+! Common blocks
+!===============================================================================
+
+!===============================================================================
+
+! Arguments
+
+character*(*)    crit
+integer          iwarnj, numper
+double precision fract, plane
+double precision tx, ty, tz
+
+! Local variables
+
+integer       lcrit
+
+!===============================================================================
+
+lcrit = len(crit)
+
+call defpt1(numper, crit, fract, plane, iwarnj, tx, ty, tz, lcrit)
+!==========
+
+return
+
+end subroutine
+
+!===============================================================================
+
+subroutine defpro &
+!================
+
+ ( numper, crit, fract, plane, iwarnj, ax, ay, az, theta, ix, iy, iz )
+
+!===============================================================================
+! Purpose:
+! -------
+
+! Definition of a periodicity of rotation.
+
+!-------------------------------------------------------------------------------
+! Arguments
+!__________________.____._____.________________________________________________.
+! name             !type!mode ! role                                           !
+!__________________!____!_____!________________________________________________!
+! numper           ! i  ! <-- ! periodicity number                             !
+! crit             ! a  ! <-- ! selection criteria for the border faces to     !
+!                  !    !     ! transform                                      !
+! fract            ! r  ! <-- ! fraction parameter                             !
+! plane            ! r  ! <-- ! face coplanarity parameter                     !
+! iwarnj           ! i  ! <-- ! verbosity level                                !
+! ax               ! r  ! <-- ! X coordinate of the rotation axis              !
+! ay               ! r  ! <-- ! Y coordinate of the rotation axis              !
+! az               ! r  ! <-- ! Z coordinate of the rotation axis              !
+! theta            ! r  ! <-- ! angle of the rotation (radian)                 !
+! ix               ! r  ! <-- ! X coordinate of the invariant point            !
+! iy               ! r  ! <-- ! Y coordinate of the invariant point            !
+! iz               ! r  ! <-- ! Z coordinate of the invariant point            !
+!__________________!____!_____!________________________________________________!
+
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
+!===============================================================================
+
+implicit none
+
+!===============================================================================
+! Common blocks
+!===============================================================================
+
+!===============================================================================
+
+! Arguments
+
+character*(*)    crit
+integer          iwarnj, numper
+double precision fract, plane
+double precision ax, ay, az, theta, ix, iy, iz
+
+! Local variables
+
+integer       lcrit
+
+!===============================================================================
+
+lcrit = len(crit)
+
+call defpr1(numper, crit, fract, plane, iwarnj, &
+!==========
+            ax, ay, az, theta, ix, iy, iz, lcrit)
+
+return
+
+end subroutine
+
+!===============================================================================
+
+subroutine defpge &
+!================
+
+ ( numper, crit, fract, plane, iwarnj, &
+   r11, r12, r13, tx,                  &
+   r21, r22, r23, ty,                  &
+   r31, r32, r33, tz )
+
+!===============================================================================
+! Purpose:
+! -------
+
+! Definition of a general periodicity.
+
+!-------------------------------------------------------------------------------
+! Arguments
+!__________________.____._____.________________________________________________.
+! name             !type!mode ! role                                           !
+!__________________!____!_____!________________________________________________!
+! numper           ! i  ! <-- ! periodicity number                             !
+! crit             ! a  ! <-- ! selection criteria for the border faces to     !
+!                  !    !     ! transform                                      !
+! fract            ! r  ! <-- ! fraction parameter                             !
+! plane            ! r  ! <-- ! face coplanarity parameter                     !
+! iwarnj           ! i  ! <-- ! verbosity level                                !
+! r11              ! r  ! <-- ! coef. (1,1) of the homogeneous matrix          !
+! r12              ! r  ! <-- ! coef. (1,2) of the homogeneous matrix          !
+! r13              ! r  ! <-- ! coef. (1,3) of the homogeneous matrix          !
+! tx               ! r  ! <-- ! coef. (1,4) of the homogeneous matrix          !
+! r21              ! r  ! <-- ! coef. (2,1) of the homogeneous matrix          !
+! r22              ! r  ! <-- ! coef. (2,2) of the homogeneous matrix          !
+! r23              ! r  ! <-- ! coef. (2,3) of the homogeneous matrix          !
+! ty               ! r  ! <-- ! coef. (2,4) of the homogeneous matrix          !
+! r31              ! r  ! <-- ! coef. (3,1) of the homogeneous matrix          !
+! r32              ! r  ! <-- ! coef. (3,2) of the homogeneous matrix          !
+! r33              ! r  ! <-- ! coef. (3,3) of the homogeneous matrix          !
+! tz               ! r  ! <-- ! coef. (3,4) of the homogeneous matrix          !
+!__________________!____!_____!________________________________________________!
+
+!     Type: i (integer), r (real), s (string), a (array), l (logical),
+!           and composite types (ex: ra real array)
+!     mode: <-- input, --> output, <-> modifies data, --- work array
+
+!===============================================================================
+
+implicit none
+
+!===============================================================================
+! Common blocks
+!===============================================================================
+
+!===============================================================================
+
+! Arguments
+
+character*(*)    crit
+integer          iwarnj, numper
+double precision fract, plane
+double precision r11, r12, r13, r21, r22, r23, r31, r32, r33, tx, ty, tz
+
+! Local variables
+
+integer       lcrit
+
+!===============================================================================
+
+lcrit = len(crit)
+
+call defpg1(numper, crit, fract, plane, iwarnj, &
+!==========
+            r11, r12, r13, tx, r21, r22, r23, ty, r31, r32, r33, tz, lcrit)
+
+return
+
+end subroutine
diff --git a/src/base/cs_join_post.c b/src/base/cs_join_post.c
index 170bba5..7372e55 100644
--- a/src/base/cs_join_post.c
+++ b/src/base/cs_join_post.c
@@ -493,9 +493,7 @@ cs_join_post_after_merge(cs_join_param_t          join_param,
  *
  * parameters:
  *   n_old_i_faces   <-- initial number of interior faces
- *   n_new_i_faces   <-- number of interior faces added to the mesh definition
  *   n_old_b_faces   <-- initial number of border faces
- *   n_new_b_faces   <-- number of border faces added to the mesh definition
  *   n_g_new_b_faces <-- global number of new border faces
  *   n_select_faces  <-- number of selected faces
  *   mesh            <-- pointer to a cs_mesh_t structure
@@ -504,9 +502,7 @@ cs_join_post_after_merge(cs_join_param_t          join_param,
 
 void
 cs_join_post_after_split(cs_int_t          n_old_i_faces,
-                         cs_int_t          n_new_i_faces,
                          cs_int_t          n_old_b_faces,
-                         cs_int_t          n_new_b_faces,
                          fvm_gnum_t        n_g_new_b_faces,
                          cs_int_t          n_select_faces,
                          const cs_mesh_t  *mesh,
@@ -514,8 +510,12 @@ cs_join_post_after_split(cs_int_t          n_old_i_faces,
 {
   cs_int_t  i, j;
 
-  cs_int_t  *post_i_faces = NULL, *post_b_faces = NULL;
   char  *mesh_name = NULL;
+  cs_int_t  *post_i_faces = NULL, *post_b_faces = NULL;
+  cs_int_t  post_i_mesh_id = cs_post_get_free_mesh_id();
+
+  const int  n_new_i_faces = mesh->n_i_faces - n_old_i_faces;
+  const int  n_new_b_faces = mesh->n_b_faces - n_old_b_faces + n_select_faces;
 
   if (_cs_join_post_initialized == false)
     return;
@@ -531,61 +531,37 @@ cs_join_post_after_split(cs_int_t          n_old_i_faces,
   for (i = n_old_b_faces-n_select_faces, j = 0; i < mesh->n_b_faces; i++, j++)
     post_b_faces[j] = i + 1;
 
-  if (join_param.verbosity < 2) {
-
-    int  post_mesh_id = cs_post_get_free_mesh_id();
+  BFT_MALLOC(mesh_name, strlen("InteriorJoinedFaces_j") + 2 + 1, char);
+  sprintf(mesh_name,"%s%02d", "InteriorJoinedFaces_j", join_param.num);
 
-    BFT_MALLOC(mesh_name, strlen("JoinedFaces_j") + 2 + 1, char);
-    sprintf(mesh_name, "%s%02d", "JoinedFaces_j", join_param.num);
-
-    cs_post_add_mesh(post_mesh_id,
-                     mesh_name,
-                     0,
-                     n_new_i_faces,
-                     n_new_b_faces,
-                     NULL,
-                     post_i_faces,
-                     post_b_faces);
+  cs_post_add_mesh(post_i_mesh_id,
+                   mesh_name,
+                   0,
+                   n_new_i_faces,
+                   0,
+                   NULL,
+                   post_i_faces,
+                   NULL);
 
-    cs_post_associate(post_mesh_id, _cs_join_post_param.writer_num);
+  cs_post_associate(post_i_mesh_id, _cs_join_post_param.writer_num);
 
-  }
-  else {
+  if (n_g_new_b_faces > 0) {
 
-    cs_int_t  post_i_mesh_id = cs_post_get_free_mesh_id();
+    cs_int_t  post_b_mesh_id = cs_post_get_free_mesh_id();
 
-    BFT_MALLOC(mesh_name, strlen("InteriorJoinedFaces_j") + 2 + 1, char);
-    sprintf(mesh_name,"%s%02d", "InteriorJoinedFaces_j", join_param.num);
+    BFT_REALLOC(mesh_name, strlen("BorderJoinedFaces_j") + 2 + 1, char);
+    sprintf(mesh_name,"%s%02d", "BorderJoinedFaces_j", join_param.num);
 
-    cs_post_add_mesh(post_i_mesh_id,
+    cs_post_add_mesh(post_b_mesh_id,
                      mesh_name,
                      0,
-                     n_new_i_faces,
                      0,
+                     n_new_b_faces,
                      NULL,
-                     post_i_faces,
-                     NULL);
-
-    cs_post_associate(post_i_mesh_id, _cs_join_post_param.writer_num);
-
-    if (n_g_new_b_faces > 0) {
-
-      int  post_b_mesh_id = cs_post_get_free_mesh_id();
-
-      BFT_REALLOC(mesh_name, strlen("BorderJoinedFaces_j") + 2 + 1, char);
-      sprintf(mesh_name,"%s%02d", "BorderJoinedFaces_j", join_param.num);
-
-      cs_post_add_mesh(post_b_mesh_id,
-                       mesh_name,
-                       0,
-                       0,
-                       n_new_b_faces,
-                       NULL,
-                       NULL,
-                       post_b_faces);
+                     NULL,
+                     post_b_faces);
 
-      cs_post_associate(post_b_mesh_id, _cs_join_post_param.writer_num);
-    }
+    cs_post_associate(post_b_mesh_id, _cs_join_post_param.writer_num);
 
   }
 
@@ -660,38 +636,35 @@ cs_join_post_dump_mesh(const char            *basename,
                        const cs_join_mesh_t  *mesh,
                        cs_join_param_t        param)
 {
-  int  rank;
-  cs_join_mesh_t  *tmp;
+  int  rank, len;
+
+  cs_join_mesh_t  *tmp = NULL;
+  char  *fullname = NULL;
 
   const  int  n_ranks = cs_glob_n_ranks;
   const  int  rank_id = CS_MAX(cs_glob_rank_id, 0);
 
-#if 1 && defined(DEBUG) && !defined(NDEBUG) /* Dump mesh structure */
-  if (param.verbosity > 2) {
-
-    int  len;
-    FILE  *dbg_file = NULL;
-    char  *filename = NULL;
+  /* Define a specific name for the output */
 
-    len = strlen("JoinDBG_.dat") + strlen(basename) + 4 + 2 + 1;
-    BFT_MALLOC(filename, len, char);
-    sprintf(filename, "Join%02dDBG_%s%04d.dat",
-            param.num, basename, rank_id);
-    dbg_file = fopen(filename, "w");
+  len = strlen("JoinDBG_.dat") + strlen(basename) + 4 + 2 + 1;
+  BFT_MALLOC(fullname, len, char);
+  sprintf(fullname, "Join%02dDBG_%s%04d.dat",
+          param.num, basename, rank_id);
 
+#if 0 && defined(DEBUG) && !defined(NDEBUG) /* Dump mesh structure */
+  if (param.verbosity > 2) {
+    FILE  *dbg_file = NULL;
+    dbg_file = fopen(fullname, "w");
     cs_join_mesh_dump_file(dbg_file, mesh);
-
     fflush(dbg_file);
-    BFT_FREE(filename);
     fclose(dbg_file);
-
   }
 #endif
 
   if (_cs_join_post_initialized == true && param.verbosity > 3) {
 
     if (n_ranks == 1)
-      cs_join_post_mesh(basename, mesh);
+      cs_join_post_mesh(fullname, mesh);
 
     else { /* Parallel */
 
@@ -717,6 +690,8 @@ cs_join_post_dump_mesh(const char            *basename,
     } /* End of parallel treatment */
   }
 
+  BFT_FREE(fullname);
+
 #if defined(HAVE_MPI)
   if (n_ranks > 1)
     MPI_Barrier(cs_glob_mpi_comm);
diff --git a/src/base/cs_join_set.c b/src/base/cs_join_set.c
index 65d3a45..5701172 100644
--- a/src/base/cs_join_set.c
+++ b/src/base/cs_join_set.c
@@ -3,7 +3,7 @@
  *     This file is part of the Code_Saturne Kernel, element of the
  *     Code_Saturne CFD tool.
  *
- *     Copyright (C) 2008-2009 EDF S.A., France
+ *     Copyright (C) 2008-2010 EDF S.A., France
  *
  *     contact: saturne-support at edf.fr
  *
@@ -125,6 +125,155 @@ _coupled_adapted_gnum_shellsort(int         l,
 
 }
 
+/*----------------------------------------------------------------------------
+ * Test if an array of local numbers with stride 2 is lexicographically
+ * ordered.
+ *
+ * parameters:
+ *   number   <-- array of all entity numbers (number of entity i
+ *                given by number[i] or number[list[i] - 1])
+ *   nb_ent   <-- number of entities considered
+ *
+ * returns:
+ *   1 if ordered, 0 otherwise.
+ *----------------------------------------------------------------------------*/
+
+static int
+_order_local_test_s2(const fvm_lnum_t  number[],
+                     size_t            n_elts)
+{
+  size_t i = 0;
+
+  assert (number != NULL || n_elts == 0);
+
+  for (i = 1 ; i < n_elts ; i++) {
+    size_t i_prev, k;
+    cs_bool_t unordered = false;
+    i_prev = i-1;
+    for (k = 0; k < 2; k++) {
+      if (number[i_prev*2 + k] < number[i*2 + k])
+        break;
+      else if (number[i_prev*2 + k] > number[i*2 + k])
+        unordered = true;
+    }
+    if (unordered == true)
+      break;
+  }
+
+  if (i == n_elts || n_elts == 0)
+    return 1;
+  else
+    return 0;
+}
+
+/*----------------------------------------------------------------------------
+ * Descend binary tree for the lexicographical ordering of an local numbering
+ * array of stride 2.
+ *
+ * parameters:
+ *   number    <-- pointer to numbers of entities that should be ordered.
+ *   level     <-- level of the binary tree to descend
+ *   n_elts    <-- number of entities in the binary tree to descend
+ *   order     <-> ordering array
+ *----------------------------------------------------------------------------*/
+
+inline static void
+_order_descend_tree_s2(const fvm_lnum_t  number[],
+                       size_t            level,
+                       const size_t      n_elts,
+                       fvm_lnum_t        order[])
+{
+  size_t i_save, i1, i2, j, lv_cur;
+
+  i_save = (size_t)(order[level]);
+
+  while (level <= (n_elts/2)) {
+
+    lv_cur = (2*level) + 1;
+
+    if (lv_cur < n_elts - 1) {
+
+      i1 = (size_t)(order[lv_cur+1]);
+      i2 = (size_t)(order[lv_cur]);
+
+      for (j = 0; j < 2; j++) {
+        if (number[i1*2 + j] != number[i2*2 + j])
+          break;
+      }
+
+      if (j < 2) {
+        if (number[i1*2 + j] > number[i2*2 + j])
+          lv_cur++;
+      }
+
+    }
+
+    if (lv_cur >= n_elts) break;
+
+    i1 = i_save;
+    i2 = (size_t)(order[lv_cur]);
+
+    for (j = 0; j < 2; j++) {
+      if (number[i1*2 + j] != number[i2*2 + j])
+        break;
+    }
+
+    if (j == 2) break;
+    if (number[i1*2 + j] >= number[i2*2 + j]) break;
+
+    order[level] = order[lv_cur];
+    level = lv_cur;
+
+  }
+
+  order[level] = i_save;
+}
+
+/*----------------------------------------------------------------------------
+ * Order array of local numbers with stride 2 lexicographically.
+ *
+ * parameters:
+ *   number   <-- array of entity numbers
+ *   order    --> pre-allocated ordering table
+ *   n_elts   <-- number of entities considered
+ *----------------------------------------------------------------------------*/
+
+static void
+_order_local_s2(const fvm_lnum_t  number[],
+                fvm_lnum_t        order[],
+                const size_t      n_elts)
+{
+  size_t i;
+  fvm_lnum_t o_save;
+
+  assert (number != NULL || n_elts == 0);
+
+  /* Initialize ordering array */
+
+  for (i = 0 ; i < n_elts ; i++)
+    order[i] = i;
+
+  if (n_elts < 2)
+    return;
+
+  /* Create binary tree */
+
+  i = (n_elts / 2) ;
+  do {
+    i--;
+    _order_descend_tree_s2(number, i, n_elts, order);
+  } while (i > 0);
+
+  /* Sort binary tree */
+
+  for (i = n_elts - 1 ; i > 0 ; i--) {
+    o_save   = order[0];
+    order[0] = order[i];
+    order[i] = o_save;
+    _order_descend_tree_s2(number, 0, i, order);
+  }
+}
+
 /*============================================================================
  * Public function definitions
  *===========================================================================*/
@@ -161,7 +310,7 @@ cs_join_rset_create(cs_int_t  max_size)
 /*----------------------------------------------------------------------------
  * Destroy a cs_join_rset_t structure.
  *
- * parameter:
+ * parameters:
  *   set <-- pointer to pointer to the cs_join_rset_t structure to destroy
  *---------------------------------------------------------------------------*/
 
@@ -273,7 +422,7 @@ cs_join_eset_check_size(cs_int_t          request_size,
 /*----------------------------------------------------------------------------
  * Destroy a cs_join_eset_t structure.
  *
- * parameter:
+ * parameters:
  *   equiv_set <-- pointer to pointer to the structure to destroy
  *---------------------------------------------------------------------------*/
 
@@ -306,8 +455,6 @@ cs_join_eset_clean(cs_join_eset_t  **eset)
   cs_join_eset_t  *new_eset = NULL;
   cs_join_eset_t  *_eset = *eset;
 
-  assert(sizeof(fvm_gnum_t) == sizeof(fvm_lnum_t));
-
   if (_eset == NULL)
     return;
 
@@ -316,18 +463,14 @@ cs_join_eset_clean(cs_join_eset_t  **eset)
 
   BFT_MALLOC(order, _eset->n_equiv, fvm_lnum_t);
 
-  if (fvm_order_local_test_s(NULL,
-                             (fvm_gnum_t *)_eset->equiv_couple,
-                             2,
-                             _eset->n_equiv) == false) {
+  if (_order_local_test_s2(_eset->equiv_couple,
+                           _eset->n_equiv) == false) {
 
     /* Order equiv_lst */
 
-    fvm_order_local_allocated_s(NULL,
-                                (fvm_gnum_t *)_eset->equiv_couple,
-                                2,
-                                order,
-                                _eset->n_equiv);
+    _order_local_s2(_eset->equiv_couple,
+                    order,
+                    _eset->n_equiv);
 
   }
   else
@@ -749,6 +892,8 @@ cs_join_gset_copy(const cs_join_gset_t  *src)
   for (i = 0; i < src->n_elts + 1; i++)
     copy->index[i] = src->index[i];
 
+  BFT_MALLOC(copy->g_list, copy->index[copy->n_elts], fvm_gnum_t);
+
   for (i = 0; i < src->index[src->n_elts]; i++)
     copy->g_list[i] = src->g_list[i];
 
@@ -1003,6 +1148,8 @@ cs_join_gset_invert(const cs_join_gset_t  *set)
 /*----------------------------------------------------------------------------
  * Delete redudancies in a cs_join_gset_t structure.
  *
+ * Output set has an ordered sub-list for each element in set.
+ *
  * parameters:
  *   set <-> pointer to the structure to clean
  *---------------------------------------------------------------------------*/
@@ -1222,7 +1369,10 @@ cs_join_gset_single_order(const cs_join_gset_t  *set,
 /*----------------------------------------------------------------------------
  * Compress a g_list such as for each element "e" in g_elts:
  *  - there is no redundancy for the linked elements of set->g_list
- *  - there is no element in set->g_list < e
+ *  - there is no element in set->g_list < e except if this element is not
+ *    present in g_elts
+ *
+ * g_list and g_elts must be ordered before calling this function
  *
  * parameters:
  *   set <-> pointer to the structure to work with
@@ -1251,17 +1401,41 @@ cs_join_gset_compress(cs_join_gset_t  *set)
 
     if (end - start > 0) {
 
-      cs_sort_gnum_shell(start, end, set->g_list);
+      /* Sub-lists must be ordered */
 
       if (cur < set->g_list[start])
         set->g_list[shift++] = set->g_list[start];
+      else if (cur > set->g_list[start]) {
+
+        int  id = cs_search_g_binary(i+1,
+                                     set->g_list[start],
+                                     set->g_elts);
 
-      for (j = start + 1; j < end; j++)
-        if (cur < set->g_list[j])
+        if (id == -1) /* Not found. Keep it. */
+          set->g_list[shift++] = set->g_list[start];
+
+      }
+
+      for (j = start + 1; j < end; j++) {
+
+        if (cur < set->g_list[j]) {
           if (set->g_list[j-1] != set->g_list[j])
             set->g_list[shift++] = set->g_list[j];
+        }
+        else if (cur > set->g_list[j]) {
 
-    }
+          int  id = cs_search_g_binary(i+1,
+                                       set->g_list[j],
+                                       set->g_elts);
+
+          if (id == -1) /* Not found. Keep it. */
+            set->g_list[shift++] = set->g_list[j];
+
+        }
+
+      } /* End of loop on sub-elements */
+
+    } /* end - start > 0 */
 
     save = end;
     set->index[i+1] = shift;
@@ -1271,10 +1445,8 @@ cs_join_gset_compress(cs_join_gset_t  *set)
   /* Reshape cs_join_gset_t structure if necessary */
 
   if (save != set->index[set->n_elts]) {
-
     assert(save > set->index[set->n_elts]);
     BFT_REALLOC(set->g_list, set->index[set->n_elts], fvm_gnum_t);
-
   }
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
@@ -1369,10 +1541,415 @@ cs_join_gset_merge_elts(cs_join_gset_t  *set,
 
 /*----------------------------------------------------------------------------
  * Synchronize a cs_join_gset_t structure and distribute the resulting set
+ * over the rank using a round-robin distribution. Elements in sync_set
+ * are ordered and there is no redundancy but list may have redundancies.
+ * Use cs_join_gset_clean() to remove redundancies in g_list.
+ *
+ * parameters:
+ *   loc_set  <-> pointer to the local structure to work with
+ *   comm     <-- mpi_comm on which synchro. and distribution take place
+ *
+ * returns:
+ *   a synchronized and distributed cs_join_gset_t structure.
+ *---------------------------------------------------------------------------*/
+
+cs_join_gset_t *
+cs_join_gset_robin_sync(cs_join_gset_t  *loc_set,
+                        MPI_Comm         comm)
+{
+  int  i, j, shift, elt_id;
+  int  rank, local_rank, n_ranks, n_recv_elts, n_sub_elts;
+  fvm_gnum_t  gnum;
+
+  cs_int_t  *send_count = NULL, *recv_count = NULL;
+  cs_int_t  *send_shift = NULL, *recv_shift = NULL;
+  fvm_gnum_t  *send_buffer = NULL, *recv_buffer = NULL;
+  cs_join_gset_t  *sync_set = NULL;
+
+  MPI_Comm_rank(comm, &local_rank);
+  MPI_Comm_size(comm, &n_ranks);
+
+  /* Allocate parameters for MPI functions */
+
+  BFT_MALLOC(send_count, n_ranks, cs_int_t);
+  BFT_MALLOC(recv_count, n_ranks, cs_int_t);
+  BFT_MALLOC(send_shift, n_ranks + 1, cs_int_t);
+  BFT_MALLOC(recv_shift, n_ranks + 1, cs_int_t);
+
+  /* Initialization */
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  /* Synchronize list definition for each global element */
+
+  for (i = 0; i < loc_set->n_elts; i++) {
+    rank = (loc_set->g_elts[i] - 1) % n_ranks;
+    send_count[rank] += 1;
+  }
+
+  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, comm);
+
+  send_shift[0] = 0;
+  recv_shift[0] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++) {
+    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
+    recv_shift[rank + 1] = recv_shift[rank] + recv_count[rank];
+  }
+
+  n_recv_elts = recv_shift[n_ranks];
+
+  /* Define sync_set: a distributed cs_join_gset_t structure which
+     synchronize data over the ranks */
+
+  sync_set = cs_join_gset_create(n_recv_elts);
+
+  /* Synchronize list definition for each global element */
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  for (i = 0; i < loc_set->n_elts; i++) {
+
+    rank = (loc_set->g_elts[i] - 1) % n_ranks;
+    n_sub_elts = loc_set->index[i+1] - loc_set->index[i];
+    send_count[rank] += 2 + n_sub_elts;
+
+  }
+
+  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, comm);
+
+  send_shift[0] = 0;
+  recv_shift[0] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++) {
+    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
+    recv_shift[rank + 1] = recv_shift[rank] + recv_count[rank];
+  }
+
+  /* Fill send_buffer: global number and number of elements in index */
+
+  BFT_MALLOC(send_buffer, send_shift[n_ranks], fvm_gnum_t);
+  BFT_MALLOC(recv_buffer, recv_shift[n_ranks], fvm_gnum_t);
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  for (i = 0; i < loc_set->n_elts; i++) {
+
+    gnum = loc_set->g_elts[i];
+    rank = (gnum - 1) % n_ranks;
+    shift = send_shift[rank] + send_count[rank];
+    n_sub_elts = loc_set->index[i+1] - loc_set->index[i];
+
+    send_buffer[shift++] = gnum;
+    send_buffer[shift++] = n_sub_elts;
+
+    for (j = 0; j < n_sub_elts; j++)
+      send_buffer[shift + j] = loc_set->g_list[loc_set->index[i] + j];
+
+    send_count[rank] += 2 + n_sub_elts;
+
+  }
+
+  MPI_Alltoallv(send_buffer, send_count, send_shift, FVM_MPI_GNUM,
+                recv_buffer, recv_count, recv_shift, FVM_MPI_GNUM,
+                comm);
+
+  n_recv_elts = recv_shift[n_ranks];
+
+  /* Partial free memory */
+
+  BFT_FREE(send_buffer);
+  BFT_FREE(send_count);
+  BFT_FREE(send_shift);
+  BFT_FREE(recv_count);
+  BFT_FREE(recv_shift);
+
+  /* Fill sync_set->index and define a new recv_count for the next comm. */
+
+  i = 0; /* position in recv_buffer */
+  elt_id = 0; /* position of the element in sync_set */
+
+  while (i < n_recv_elts) {
+
+    sync_set->g_elts[elt_id] = recv_buffer[i++];
+    n_sub_elts = recv_buffer[i++];
+    sync_set->index[elt_id+1] = n_sub_elts;
+    i += n_sub_elts;
+    elt_id++;
+
+  } /* End of loop on ranks */
+
+  /* Build index on elements of sync_set */
+
+  for (i = 0; i < sync_set->n_elts; i++)
+    sync_set->index[i+1] += sync_set->index[i];
+
+  BFT_MALLOC(sync_set->g_list,
+             sync_set->index[sync_set->n_elts],
+             fvm_gnum_t);
+
+  /* Fill g_list of sync_set */
+
+  i = 0; /* position in recv_buffer */
+  elt_id = 0; /* position of the element in sync_set */
+
+  while (i < n_recv_elts) {
+
+    i++; /* element numbering */
+    shift = sync_set->index[elt_id];
+    n_sub_elts = recv_buffer[i++];
+
+    for (j = 0; j < n_sub_elts; j++)
+      sync_set->g_list[j + shift] = recv_buffer[i++];
+
+    elt_id++;
+
+  } /* End of loop on ranks */
+
+  BFT_FREE(recv_buffer);
+
+  /* Return pointer */
+
+  cs_join_gset_merge_elts(sync_set, 0); /* sync_set elts are not ordered */
+
+  return  sync_set;
+}
+
+/*----------------------------------------------------------------------------
+ * Update a local cs_join_gset_t structure from a distributed and
+ * synchronized cs_join_gset_t structure. Round-robin distribution is used
+ * to store synchronized elements.
+ *
+ * loc_set should not have redundant elements.
+ *
+ * parameters:
+ *   sync_set <-- pointer to the structure which holds a synchronized block
+ *   loc_set  <-> pointer to a local structure holding elements to update
+ *   comm     <-- comm on which synchronization and distribution take place
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_gset_robin_update(const cs_join_gset_t  *sync_set,
+                          cs_join_gset_t        *loc_set,
+                          MPI_Comm               comm)
+{
+  int  i, j, k, shift, elt_id, start, end;
+  int  rank, local_rank, n_ranks, n_sub_elts, n_recv_elts;
+  fvm_gnum_t  gnum;
+
+  cs_int_t  *send_count = NULL, *recv_count = NULL;
+  cs_int_t  *send_shift = NULL, *recv_shift = NULL, *wanted_rank_index = NULL;
+  fvm_gnum_t  *send_buffer = NULL, *recv_buffer = NULL, *wanted_elts = NULL;
+
+  /* Sanity checks */
+
+  assert(sync_set != NULL);
+
+  /* Build a cs_join_block_info_t structure */
+
+  MPI_Comm_rank(comm, &local_rank);
+  MPI_Comm_size(comm, &n_ranks);
+
+  /* Allocate parameters for MPI functions */
+
+  BFT_MALLOC(send_count, n_ranks, cs_int_t);
+  BFT_MALLOC(recv_count, n_ranks, cs_int_t);
+  BFT_MALLOC(send_shift, n_ranks + 1, cs_int_t);
+  BFT_MALLOC(recv_shift, n_ranks + 1, cs_int_t);
+  BFT_MALLOC(wanted_rank_index, n_ranks + 1, cs_int_t);
+
+  /* Initialization */
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  /* Get a synchronized list definition for each global element */
+
+  for (i = 0; i < loc_set->n_elts; i++) {
+    rank = (loc_set->g_elts[i] - 1) % n_ranks;
+    send_count[rank] += 1;
+  }
+
+  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, comm);
+
+  send_shift[0] = 0;
+  wanted_rank_index[0] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++) {
+    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
+    wanted_rank_index[rank + 1] = wanted_rank_index[rank] + recv_count[rank];
+  }
+
+  /* Fill send_buffer: global number */
+
+  BFT_MALLOC(send_buffer, send_shift[n_ranks], fvm_gnum_t);
+  BFT_MALLOC(wanted_elts, wanted_rank_index[n_ranks], fvm_gnum_t);
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  for (i = 0; i < loc_set->n_elts; i++) {
+
+    gnum = loc_set->g_elts[i];
+    rank = (gnum - 1) % n_ranks;
+    shift = send_shift[rank] + send_count[rank];
+
+    send_buffer[shift] = gnum;
+    send_count[rank] += 1;
+
+  }
+
+  MPI_Alltoallv(send_buffer, send_count, send_shift, FVM_MPI_GNUM,
+                wanted_elts, recv_count, wanted_rank_index, FVM_MPI_GNUM,
+                comm);
+
+  /* Send new list definition holding by sync_set to ranks which have
+     request it */
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++) {
+
+    for (i = wanted_rank_index[rank]; i < wanted_rank_index[rank+1]; i++) {
+
+      elt_id = cs_search_g_binary(sync_set->n_elts,
+                                  wanted_elts[i],
+                                  sync_set->g_elts);
+
+      assert(elt_id != -1);
+
+      wanted_elts[i] = elt_id;
+      n_sub_elts = sync_set->index[elt_id+1] - sync_set->index[elt_id];
+      send_count[rank] +=  2 + n_sub_elts; /* glob. num,
+                                              n_sub_elts,
+                                              g_list */
+
+    }
+
+  } /* End of loop on ranks */
+
+  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, comm);
+
+  send_shift[0] = 0;
+  recv_shift[0] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++) {
+    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
+    recv_shift[rank + 1] = recv_shift[rank] + recv_count[rank];
+  }
+
+  BFT_REALLOC(send_buffer, send_shift[n_ranks], fvm_gnum_t);
+  BFT_MALLOC(recv_buffer, recv_shift[n_ranks], fvm_gnum_t);
+
+  for (i = 0; i < n_ranks; i++)
+    send_count[i] = 0;
+
+  for (rank = 0; rank < n_ranks; rank++) {
+
+    for (i = wanted_rank_index[rank]; i < wanted_rank_index[rank+1]; i++) {
+
+      shift = send_shift[rank] + send_count[rank];
+      elt_id = wanted_elts[i];
+
+      start = sync_set->index[elt_id];
+      end = sync_set->index[elt_id+1];
+      n_sub_elts = end - start;
+
+      send_buffer[shift++] = sync_set->g_elts[elt_id];
+      send_buffer[shift++] = n_sub_elts;
+
+      for (j = start, k = 0; j < end; j++, k++)
+        send_buffer[shift+k] = sync_set->g_list[j];
+
+      send_count[rank] +=  2 + n_sub_elts; /* glob. num, n_sub_elts, g_list */
+
+    }
+
+  } /* End of loop on ranks */
+
+  MPI_Alltoallv(send_buffer, send_count, send_shift, FVM_MPI_GNUM,
+                recv_buffer, recv_count, recv_shift, FVM_MPI_GNUM,
+                comm);
+
+  n_recv_elts = recv_shift[n_ranks];
+
+  /* Partial memory free */
+
+  BFT_FREE(send_buffer);
+  BFT_FREE(send_count);
+  BFT_FREE(send_shift);
+  BFT_FREE(recv_count);
+  BFT_FREE(recv_shift);
+
+  /* Re-initialize loc_set
+     As loc_set->g_elts and sync_set->g_elts are ordered, it's easier.
+     We can take values as they come */
+
+  /* First redefine index */
+
+  assert(loc_set->index[0] == 0);
+
+  for (i = 0; i < loc_set->n_elts; i++)
+    loc_set->index[i+1] = 0;
+
+  i = 0; /* id in recv_buffer */
+  j = 0; /* id in g_elts */
+
+  while (i < n_recv_elts) {
+
+    gnum = recv_buffer[i++];
+
+    assert(loc_set->g_elts[j] = gnum);
+
+    n_sub_elts = recv_buffer[i++];
+    loc_set->index[j+1] = n_sub_elts;
+
+    i += n_sub_elts;
+    j++; /* go to the next elements */
+
+  } /* End of loop on elements of recv_buffer */
+
+  /* Define the new index */
+
+  for (i = 0; i < loc_set->n_elts; i++)
+    loc_set->index[i+1] += loc_set->index[i];
+
+  BFT_REALLOC(loc_set->g_list, loc_set->index[loc_set->n_elts], fvm_gnum_t);
+
+  i = 0; /* id in recv_buffer */
+  j = 0; /* id in g_elts */
+
+  while (i < n_recv_elts) {
+
+    gnum = recv_buffer[i++];
+    n_sub_elts = recv_buffer[i++];
+
+    assert(loc_set->g_elts[j] = gnum);
+
+    for (k = 0; k < n_sub_elts; k++)
+      loc_set->g_list[loc_set->index[j] + k] = recv_buffer[i + k];
+
+    i += n_sub_elts;
+    j++; /* go to the next elements */
+
+  } /* End of loop on elements of recv_buffer */
+
+  BFT_FREE(recv_buffer);
+  BFT_FREE(wanted_elts);
+  BFT_FREE(wanted_rank_index);
+
+}
+
+/*----------------------------------------------------------------------------
+ * Synchronize a cs_join_gset_t structure and distribute the resulting set
  * over the rank by block
  *
  * parameters:
- *   n_g_elts <-- global number of elements
+ *   max_gnum <-- max global number in global element numbering
  *   loc_set  <-> pointer to the local structure to work with
  *   comm     <-- mpi_comm on which synchro. and distribution take place
  *
@@ -1381,9 +1958,9 @@ cs_join_gset_merge_elts(cs_join_gset_t  *set,
  *---------------------------------------------------------------------------*/
 
 cs_join_gset_t *
-cs_join_gset_sync_by_block(fvm_gnum_t       n_g_elts,
-                           cs_join_gset_t  *loc_set,
-                           MPI_Comm         comm)
+cs_join_gset_block_sync(fvm_gnum_t       max_gnum,
+                        cs_join_gset_t  *loc_set,
+                        MPI_Comm         comm)
 {
   int  i, j, shift, block_id;
   int  rank, local_rank, n_ranks, n_recv_elts, n_sub_elts;
@@ -1395,13 +1972,13 @@ cs_join_gset_sync_by_block(fvm_gnum_t       n_g_elts,
   fvm_gnum_t  *send_buffer = NULL, *recv_buffer = NULL;
   cs_join_gset_t  *sync_set = NULL;
 
-  if (n_g_elts == 0)
+  if (max_gnum == 0)
     return  sync_set;
 
   MPI_Comm_rank(comm, &local_rank);
   MPI_Comm_size(comm, &n_ranks);
 
-  block_info = cs_join_get_block_info(n_g_elts, n_ranks, local_rank);
+  block_info = cs_join_get_block_info(max_gnum, n_ranks, local_rank);
 
   /* Allocate parameters for MPI functions */
 
@@ -1544,18 +2121,20 @@ cs_join_gset_sync_by_block(fvm_gnum_t       n_g_elts,
  * Update a local cs_join_gset_t structure from a distributed and
  * synchronized cs_join_gset_t structure.
  *
+ * Loc_set should not have redundant elements.
+ *
  * parameters:
- *   n_g_elts <-- global number of elements
+ *   max_gnum <-- max global number in global element numbering
  *   sync_set <-- pointer to the structure which holds a synchronized block
  *   loc_set  <-> pointer to a local structure holding elements to update
  *   comm     <-- comm on which synchronization and distribution take place
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_gset_update_from_block(fvm_gnum_t             n_g_elts,
-                               const cs_join_gset_t  *sync_set,
-                               cs_join_gset_t        *loc_set,
-                               MPI_Comm               comm)
+cs_join_gset_block_update(fvm_gnum_t             max_gnum,
+                          const cs_join_gset_t  *sync_set,
+                          cs_join_gset_t        *loc_set,
+                          MPI_Comm               comm)
 {
   int  i, j, k, shift, block_id, start, end;
   int  rank, local_rank, n_ranks, n_sub_elts, n_recv_elts;
@@ -1566,21 +2145,19 @@ cs_join_gset_update_from_block(fvm_gnum_t             n_g_elts,
   cs_int_t  *send_shift = NULL, *recv_shift = NULL, *wanted_rank_index = NULL;
   fvm_gnum_t  *send_buffer = NULL, *recv_buffer = NULL, *wanted_elts = NULL;
 
-  if (n_g_elts == 0)
+  if (max_gnum == 0)
     return;
 
   /* Sanity checks */
 
   assert(sync_set != NULL);
 
-  /* loc_set should not have redundant elements. */
-
   /* Build a cs_join_block_info_t structure */
 
   MPI_Comm_rank(comm, &local_rank);
   MPI_Comm_size(comm, &n_ranks);
 
-  block_info = cs_join_get_block_info(n_g_elts, n_ranks, local_rank);
+  block_info = cs_join_get_block_info(max_gnum, n_ranks, local_rank);
 
   /* Allocate parameters for MPI functions */
 
@@ -1847,7 +2424,7 @@ void
 cs_join_gset_dump(FILE                  *file,
                   const cs_join_gset_t  *set)
 {
-  int  i, j, n_matches;
+  int  i, j;
 
   if (set == NULL)
     return;
@@ -1861,14 +2438,55 @@ cs_join_gset_dump(FILE                  *file,
 
   for (i = 0; i < set->n_elts; i++) {
 
-    n_matches = set->index[i+1] - set->index[i];
+    int  s = set->index[i], e = set->index[i+1];
+    int  n_matches = e-s;
+    int  n_loops = n_matches/10;
+
+    fprintf(file, "Global num: %8llu | subsize: %3d |",
+            (unsigned long long)set->g_elts[i], n_matches);
+
+    for (j = 0; j < n_loops; j++) {
+      if (j == 0)
+        fprintf(file,
+                "%8llu %8llu %8llu %8llu %8llu "
+                "%8llu %8llu %8llu %8llu %8llu\n",
+                (unsigned long long)set->g_list[s+ 10*j],
+                (unsigned long long)set->g_list[s+ 10*j + 1],
+                (unsigned long long)set->g_list[s+ 10*j + 2],
+                (unsigned long long)set->g_list[s+ 10*j + 3],
+                (unsigned long long)set->g_list[s+ 10*j + 4],
+                (unsigned long long)set->g_list[s+ 10*j + 5],
+                (unsigned long long)set->g_list[s+ 10*j + 6],
+                (unsigned long long)set->g_list[s+ 10*j + 7],
+                (unsigned long long)set->g_list[s+ 10*j + 8],
+                (unsigned long long)set->g_list[s+ 10*j + 9]);
+      else
+        fprintf(file, "                                     "
+                "%8llu %8llu %8llu %8llu %8llu "
+                "%8llu %8llu %8llu %8llu %8llu\n",
+                (unsigned long long)set->g_list[s+ 10*j],
+                (unsigned long long)set->g_list[s+ 10*j + 1],
+                (unsigned long long)set->g_list[s+ 10*j + 2],
+                (unsigned long long)set->g_list[s+ 10*j + 3],
+                (unsigned long long)set->g_list[s+ 10*j + 4],
+                (unsigned long long)set->g_list[s+ 10*j + 5],
+                (unsigned long long)set->g_list[s+ 10*j + 6],
+                (unsigned long long)set->g_list[s+ 10*j + 7],
+                (unsigned long long)set->g_list[s+ 10*j + 8],
+                (unsigned long long)set->g_list[s+ 10*j + 9]);
+    }
 
-    fprintf(file, "Global num.: %8u | n_matches : %3d |",
-            set->g_elts[i], n_matches);
+    if (e - s+10*n_loops > 0) {
+      for (j = s + 10*n_loops; j < e; j++) {
+        if (j == s + 10*n_loops && n_loops > 0)
+          fprintf(file,"                                     ");
+        fprintf(file,"%8llu ", (unsigned long long)set->g_list[j]);
+      }
+      fprintf(file,"\n");
+    }
 
-    for (j = set->index[i]; j < set->index[i+1]; j++)
-      fprintf(file, "%8u ", set->g_list[j]);
-    fprintf(file, "\n");
+    if (n_matches == 0)
+      fprintf(file,"\n");
 
   } /* End of loop on boxes */
 
diff --git a/src/base/cs_join_split.c b/src/base/cs_join_split.c
index d896c40..6c72725 100644
--- a/src/base/cs_join_split.c
+++ b/src/base/cs_join_split.c
@@ -114,7 +114,7 @@ typedef struct {
 
   fvm_gnum_t    n_g_subfaces;     /* Global number of subfaces after splitting */
   fvm_gnum_t   *subface_gconnect; /* Subface -> glob. vertex list */
-  fvm_gnum_t   *subface_gnum;    /* Subface global numbering */
+  fvm_gnum_t   *subface_gnum;     /* Subface global numbering */
 
 } face_builder_t;
 
@@ -211,6 +211,47 @@ _cosine(double   v1[],
 }
 
 /*----------------------------------------------------------------------------
+ * Compute the bounding box related to a face in which reconstruction
+ * is allowed.
+ *
+ * parameters:
+ *  m      <--  pointer to a cs_join_mesh_t structure
+ *  fid    <--  face id
+ *  f_min  -->  min coordinates for bounding box
+ *  f_max  -->  max coordinates for bounding box
+ *---------------------------------------------------------------------------*/
+
+inline static void
+_face_bbox(const cs_join_mesh_t  *m,
+           int                    fid,
+           double                 f_min[],
+           double                 f_max[])
+{
+  int  i, k;
+
+  const double  eps = 1e-5;
+  const cs_join_vertex_t  *vertices = m->vertices;
+
+  for (i = m->face_vtx_idx[fid] - 1; i < m->face_vtx_idx[fid+1] - 1; i++) {
+
+    int  vid = m->face_vtx_lst[i] - 1;
+    double  tol = (1 + eps) * vertices[vid].tolerance;
+
+    for (k = 0; k < 3; k++) {
+
+      double  v_min = vertices[vid].coord[k] - tol;
+      double  v_max = vertices[vid].coord[k] + tol;
+
+      f_min[k] = CS_MIN(f_min[k], v_min);
+      f_max[k] = CS_MAX(f_max[k], v_max);
+
+    }
+
+  } /* End of loop on face vertices */
+
+}
+
+/*----------------------------------------------------------------------------
  * Locally renumber an indexed list of global elements according to an
  * ordering array.
  *
@@ -614,428 +655,551 @@ _dump_face_builder(cs_int_t               face_id,
 }
 
 /*----------------------------------------------------------------------------
- * Split the current face into sub-faces under the "plane" tolerance
- * (check if two faces are coplanear).
+ * Step for building subfaces.
+ * Find the best face (in sense of coplanarity) among faces sharing the
+ * current edge to test.
  *
  * parameters:
- *   face_id       <-- face_id of the current in the cs_join_mesh_t struct.
- *   block_id      <-- current id in face_builder_t structure
- *   plane         <-- tolerance parameter to check coplanearity
- *   max_subfaces  <-- maximum number of sub faces
- *   verbosity     <-- level of accuracy in information display
- *   face_normal   <-- normal for each face of the mesh
- *   work          <-- cs_join_mesh_t structure
- *   edge_face_idx <-- "edge -> face" connect. index
- *   edge_face_lst <-- "edge -> face" connect. list
- *   builder       <-> face_builder structure
- *   head_edges    <-> pointer to a resizable set structure
- *   subface_edges <-> pointer to a resizable set structure
- *   ext_edges     <-> pointer to a resizable set structure
- *   int_edges     <-> pointer to a resizable set structure
+ *   param       <-- set of parameters for the joining operation
+ *   eid         <-- id of the current edge to test
+ *   fid         <-- fid of the current in the cs_join_mesh_t struct.
+ *   fnorm       <-- normal of the current face to rebuild
+ *   adj_fnorm   <-- normal of the best adj face (if found)
+ *   face_normal <-- normal for each face of the mesh
+ *   e2f_idx     <-- "edge -> face" connect. index
+ *   e2f_lst     <-- "edge -> face" connect. list
  *
  * returns:
- *   an error code (enum: cs_join_split_error_t)
+ *   true if an adjacent face was found else false
  *---------------------------------------------------------------------------*/
 
-static cs_join_split_error_t
-_split_face(cs_int_t                face_id,
-            cs_int_t                block_id,
-            double                  plane,
-            int                     max_subfaces,
-            int                     verbosity,
-            const cs_real_t         face_normal[],
-            const cs_join_mesh_t   *work,
-            const cs_join_edges_t  *edges,
-            const cs_int_t         *edge_face_idx,
-            const cs_int_t         *edge_face_lst,
-            face_builder_t         *builder,
-            cs_join_rset_t        **head_edges,
-            cs_join_rset_t        **subface_edges,
-            cs_join_rset_t        **ext_edges,
-            cs_join_rset_t        **int_edges)
+static cs_bool_t
+_find_best_adj_face(cs_join_param_t         param,
+                    cs_int_t                eid,
+                    cs_int_t                fid,
+                    double                  fnorm[3],
+                    double                  adj_fnorm[3],
+                    const double            face_normal[],
+                    const cs_int_t         *e2f_idx,
+                    const cs_int_t         *e2f_lst)
 {
-  cs_int_t  i, j, k, i1, i2, i_int, i_ext;
-  cs_int_t  first_vid, vid1, vid2;
-  cs_int_t  subface_shift, connect_shift, connect_start;
-  cs_int_t   next_vertex, next_edge;
-  cs_real_t  face_norm[3], v1v2_vect[3], connect_vect[3];
+  cs_int_t  j, k, adj_fid;
+  double  dprod, dprod2, test_fnorm[3];
 
-  cs_real_t  min_max_d = 0.0;
-  cs_int_t  n_subfaces = 0, head_edge_shift = 0;
-  cs_int_t  start_id = work->face_vtx_idx[face_id]-1;
-  cs_int_t  end_id = work->face_vtx_idx[face_id+1]-1;
+  int  best_fid = -1;
+  double  max_plane = -DBL_MAX;
+  cs_bool_t  respect_plane = false;
 
-  cs_real_t  max_coord[3] = {-DBL_MAX, -DBL_MAX, -DBL_MAX};
-  cs_real_t  min_coord[3] = {DBL_MAX, DBL_MAX, DBL_MAX};
-
-  cs_join_rset_t  *_head_edges = *head_edges;
-  cs_join_rset_t  *_subface_edges = *subface_edges;
-  cs_join_rset_t  *_ext_edges = *ext_edges;
-  cs_join_rset_t  *_int_edges = *int_edges;
-
-  const cs_join_vertex_t  *vertices = work->vertices;
-  const cs_real_t  min_limit_cos = -1.1, max_limit_cos = 1.1;
-  const cs_real_t  plane2 = plane * plane;
-  const cs_real_t  eps_dot_prod = 1e-8;
+  const double  plane2 = param.plane_criteria;
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
-  cs_bool_t  face_tst = ( face_id == 20758 || face_id == 30105 ||
-                          face_id == 20759 || face_id == 34385 ? true : false);
-  cs_bool_t  tst_dbg = (verbosity > 2 && face_tst ? true : false);
+#define _DBGTST 1
+  cs_bool_t  tst_dbg = ( fid==492 || fid==1039 || fid==744 || fid==262 ||
+                         fid==546 || fid==1057 || fid==564 ? true : false);
+#else
+#define _DBGTST 0
 #endif
 
-  /* To be implemented ... */
-  cs_int_t  *face_face_connect = NULL;
+  /*
+    if (f2f_connect == NULL)  What we already do...
+    else  To be implemented ....
+  */
 
-  /* Min./Max. coordinates of the current face */
+  /* Loop on faces sharing this edge */
 
-  for (i = start_id; i < end_id; i++) {
+  for (j = e2f_idx[eid]; j < e2f_idx[eid+1]; j++) {
 
-    cs_int_t  vid = work->face_vtx_lst[i] - 1;
+    adj_fid = e2f_lst[j] - 1;
 
-    for (j = 0; j < 3; j++) {
-      min_coord[j] = CS_MIN(min_coord[j], vertices[vid].coord[j]);
-      max_coord[j] = CS_MAX(max_coord[j], vertices[vid].coord[j]);
-    }
+    if (adj_fid != fid) {
 
-  }
+      for (k = 0; k < 3; k++)
+        test_fnorm[k] = face_normal[3*adj_fid+k];
 
-  for (j = 0; j < 3; j++)
-    min_max_d = CS_MAX(min_max_d, max_coord[j] - min_coord[j]);
+      dprod = _dot_product(test_fnorm, fnorm);
+      dprod2 = dprod * dprod;
 
-  for (j = 0; j < 3; j++) {
-    min_coord[j] -= 0.5 * min_max_d;
-    max_coord[j] += 0.5 * min_max_d;
-  }
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+      if (tst_dbg)
+        bft_printf("\tAdjFace: %d dp: %10.8e dp2: %10.8e Vs plane2: %10.8e;"
+                   " AdjFNorm: [%g %g %g]; FNorm: [%g %g %g]\n",
+                   adj_fid+1, dprod, dprod2, plane2, test_fnorm[0],
+                   test_fnorm[1], test_fnorm[2], fnorm[0], fnorm[1], fnorm[2]);
+#endif
 
-  /* Fill the current face normal */
+      if (dprod2 > plane2) { /* A better face has been found */
 
-  for (j = 0; j < 3; j++)
-    face_norm[j] = face_normal[3*face_id+j];
+        respect_plane = true;
+        if (dprod2 > max_plane) {
+          best_fid = adj_fid;
+          max_plane = dprod2;
+          if (dprod > 0.0) {
+            for (k = 0; k < 3; k++)
+              adj_fnorm[k] = face_normal[3*best_fid+k];
+          }
+          else {
+            for (k = 0; k < 3; k++)
+              adj_fnorm[k] = -face_normal[3*best_fid+k];
+          }
+        }
 
-  /* Loop on head edges */
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+        if (tst_dbg)
+          bft_printf("\t-> Adj face OK (best: %d, max: %10.8e)\n",
+                     best_fid+1, max_plane);
+#endif
 
-  subface_shift = builder->face_index[block_id];
-  connect_shift = builder->subface_index->array[subface_shift];
-  connect_start = connect_shift;
+      } /* dprod2 > plane2 */
 
-  assert(connect_start == builder->subface_connect->n_elts);
+    }
+    else {  /* If adj_fid == fid => the best choice */
 
-  while (_head_edges->n_elts > 0) { /* Loop until there is one head edge */
+      assert(adj_fid == fid);
+      respect_plane = true;
 
-    _int_edges->n_elts = 0;
-    head_edge_shift = 0;
-    _subface_edges->n_elts = 0;
+      for (k = 0; k < 3; k++)
+        adj_fnorm[k] = fnorm[k];
 
-    assert(_head_edges->n_elts == _ext_edges->n_elts);
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+      if (tst_dbg) bft_printf("\t Adj face is current face\n");
+#endif
 
-    while (head_edge_shift < _head_edges->n_elts) { /* Build a new sub-face */
+      /* Anayway, it's the best choice  */
+      return respect_plane;
 
-      cs_int_t  head_edge_num = _head_edges->array[head_edge_shift];
-      cs_int_t  edge_num = head_edge_num;
-      cs_int_t  edge_id = FVM_ABS(edge_num) - 1;
+    }
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-      if (tst_dbg)
-        bft_printf(" face_gnum: %u, head_shift: %d, edge_num: %d\n",
-                   work->face_gnum[face_id], head_edge_shift, edge_num);
+  } /* End of loop on faces sharing this edge */
+
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+  if (tst_dbg && respect_plane)
+    bft_printf("\tAdjFace: %d AdjFNorm: [%5.3e %5.3e %5.3e]\n",
+               best_fid+1, adj_fnorm[0], adj_fnorm[1], adj_fnorm[2]);
 #endif
 
-      if (edge_num > 0) {
-        vid1 = edges->def[2*edge_id] - 1;
-        vid2 = edges->def[2*edge_id+1] - 1;
-      }
-      else {
-        vid1 = edges->def[2*edge_id+1] - 1;
-        vid2 = edges->def[2*edge_id] - 1;
-      }
+  return respect_plane;
+}
 
-      cs_join_rset_resize(&(builder->subface_connect), connect_shift + 1);
-      cs_join_rset_resize(&_subface_edges, _subface_edges->n_elts);
+/*----------------------------------------------------------------------------
+ * Step for building subfaces.
+ * Find the next edge and vertex numbers from a given edge.
+ *
+ * parameters:
+ *   param       <-- set of parameters for the joining operation
+ *   fid         <-- fid of the current in the cs_join_mesh_t struct.
+ *   vid1        <-- first vertex id of the current edge
+ *   vid2        <-- second vertex id of the current edge
+ *   face_normal <-- normal for each face of the mesh
+ *   work        <-- cs_join_mesh_t structure
+ *   e2f_idx     <-- "edge -> face" connect. index
+ *   e2f_lst     <-- "edge -> face" connect. list
+ *   next_edge   --> pointer to the next edge number found
+ *   next_vertex --> pointer to the next vertex number found
+ *
+ * returns:
+ *   an error code (enum: cs_join_split_error_t)
+ *---------------------------------------------------------------------------*/
 
-      builder->subface_connect->array[connect_shift++] = vid1+1;
-      builder->subface_connect->array[connect_shift++] = vid2+1;
+static cs_join_split_error_t
+_find_next(cs_join_param_t         param,
+           cs_int_t                fid,
+           cs_int_t                vid1,
+           cs_int_t                vid2,
+           cs_real_t               max_coord[3],
+           cs_real_t               min_coord[3],
+           const double            face_normal[],
+           const cs_join_mesh_t   *work,
+           const cs_join_edges_t  *edges,
+           const cs_int_t         *e2f_idx,
+           const cs_int_t         *e2f_lst,
+           cs_int_t               *next_edge,
+           cs_int_t               *next_vertex)
+{
+  cs_int_t  i, j, k;
+  double  norm, dprod, adj_fnorm[3], fnorm[3], v1v2[3], v2v3[3];
 
-      _subface_edges->array[_subface_edges->n_elts++] = edge_num;
+  /* Look for the connected vertices and its associated edge */
 
-      first_vid = vid1;
+  cs_int_t  v2v_s = edges->vtx_idx[vid2];
+  cs_int_t  v2v_e = edges->vtx_idx[vid2+1];
+  cs_int_t  n_connect_vertices = v2v_e - v2v_s;
+
+  cs_int_t  *f2f_connect = NULL;   /* To be implemented ... */
+
+  const cs_join_vertex_t  *vertices = work->vertices;
+  const double  min_limit_cos = -1.1, max_limit_cos = 1.1;
+  const double  eps_dot_prod = 1e-8;
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
-      if (tst_dbg)
-        bft_printf("  v1: %u, v2: %u, first: %u\n", vertices[vid1].gnum,
-                   vertices[vid2].gnum, vertices[first_vid].gnum);
+#define _DBGTST 1
+  cs_bool_t  tst_dbg = ( fid==492 || fid==1039 || fid==744 || fid==262 ||
+                         fid==546 || fid==1057 || fid==564 ? true : false);
+#else
+#define _DBGTST 0
 #endif
 
-      while (vid2 != first_vid) {
-
-        /* Look for the connected vertices and its associated edge */
+  if (f2f_connect != NULL)
+    bft_error(__FILE__, __LINE__, 0,
+              _("  face splitting with face -> face"
+                " connectivity is not yet implemented\n"));
 
-        cs_int_t  v2v_start = edges->vtx_idx[vid2];
-        cs_int_t  v2v_end = edges->vtx_idx[vid2+1];
-        cs_int_t  n_connect_vertices = v2v_end - v2v_start;
+  for (j = 0; j < 3; j++)
+    fnorm[j] = face_normal[3*fid+j];
 
-        next_edge = 0;
-        next_vertex = 0; /* To enable a check at the end */
+  *next_edge = 0;
+  *next_vertex = 0; /* To enable a check at the end */
 
-        if (n_connect_vertices > 2) { /* Look for the edge which is
-                                         the most on the left */
+  if (n_connect_vertices > 2) { /* Look for the edge which is
+                                   the most on the left */
 
-          cs_int_t  left_next_edge = -1, left_next_vertex = -1;
-          cs_int_t  right_next_edge = -1, right_next_vertex = -1;
-          cs_real_t  left_min_cos = max_limit_cos;
-          cs_real_t  right_max_cos = min_limit_cos;
+    cs_int_t  left_next_edge = -1, left_next_vertex = -1;
+    cs_int_t  right_next_edge = -1, right_next_vertex = -1;
+    cs_real_t  left_min_cos = max_limit_cos;
+    cs_real_t  right_max_cos = min_limit_cos;
 
-          for (j = 0; j < 3; j++)
-            v1v2_vect[j] = vertices[vid2].coord[j]- vertices[vid1].coord[j];
+    for (k = 0; k < 3; k++)
+      v1v2[k] = vertices[vid2].coord[k]- vertices[vid1].coord[k];
+    norm = _norm(v1v2);
+    for (k = 0; k < 3; k++)
+      v1v2[k] /= norm;
 
-          /* Loop on connected vertices */
+    /* Loop on connected vertices */
 
-          for (i = v2v_start; i < v2v_end; i++) {
+    for (i = v2v_s; i < v2v_e; i++) {
 
-            cs_int_t  connect_vid = edges->adj_vtx_lst[i]-1;
+      cs_int_t  vid3 = edges->adj_vtx_lst[i]-1;
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-            if (tst_dbg)
-              bft_printf("  (v2v_id: %d) Next vertex connected to v2 to test: %u\n",
-                         i, vertices[connect_vid].gnum);
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+      if (tst_dbg)
+        bft_printf("  Next vtx to test: << %9u >> (v2v_idx: %d)\n",
+                   vertices[vid3].gnum, i);
 #endif
 
-            if (connect_vid != vid1) {
+      if (vid3 != vid1) {
 
-              cs_bool_t  is_inside = true;
-              cs_int_t  connect_edge_id = CS_ABS(edges->edge_lst[i]) - 1;
+        cs_bool_t  is_in_bbox = true;
+        cs_int_t  connect_eid = CS_ABS(edges->edge_lst[i]) - 1;
 
-              /* Test if the connected vertex is inside the face */
+        /* Test if the connected vertex is inside the face */
 
-              for (k = 0; k < 3; k++)
-                if (  vertices[connect_vid].coord[k] < min_coord[k]
-                   || vertices[connect_vid].coord[k] > max_coord[k])
-                  is_inside = false;
+        for (k = 0; k < 3; k++)
+          if (   vertices[vid3].coord[k] < min_coord[k]
+              || vertices[vid3].coord[k] > max_coord[k])
+            is_in_bbox = false;
 
-              if (is_inside == true) {
+        if (is_in_bbox == true) {
 
-                cs_bool_t  found = false;
+          cs_bool_t  respect_plane = _find_best_adj_face(param,
+                                                         connect_eid, fid,
+                                                         fnorm, adj_fnorm,
+                                                         face_normal,
+                                                         e2f_idx, e2f_lst);
 
-                for (k = 0; k < 3; k++)
-                  connect_vect[k] =  vertices[connect_vid].coord[k]
-                                   - vertices[vid2].coord[k];
+          if (respect_plane == true) {
 
-                /* Loop on faces sharing this edge */
+            /* Continue to build the new sub-face connectivity.
+               adj_edge_id is in the plane as edge_id
 
-                for (j = edge_face_idx[connect_edge_id];
-                     (j < edge_face_idx[connect_edge_id+1] && found == false);
-                     j++) {
+               We look for the edge which is the most on the
+               left among all the adjacent edges.
 
-                  cs_int_t  adj_face_id = edge_face_lst[j] - 1;
+                                        V3   |
+                                         \   |   /
+                       adj. edge : E2 =>  \  |  /
+                                           \ | /      Left part
+                                            \|/
+               current edge : E1 => V1------V2------  ............
+                                            /|\
+                                           / | \      Right part
+                                          /  |  \
+                                         /   |   \
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-                  if (tst_dbg)
-                    bft_printf("\t Adj face (%u) through edge (%u)\n",
-                               work->face_gnum[adj_face_id],
-                               edges->gnum[connect_edge_id]);
-#endif
+               E2 is in the left part if :
+                 - angle A between E1 and E2 is in [0, Pi[
+                 - i.e. sin(A) >= 0
+                    ->   ->  ->            ->
+                 - (E1 X E2).n  >= 0 where n is the face normal vector
 
-                  if (adj_face_id != face_id) {
+                 Edge which is the most on the left is the one which has
+                 the minimal cos(A)
 
-                    cs_real_t  dprod, dprod2;
-                    cs_real_t  adj_face_norm[3];
+                 If there is no edge in the left part, we choose the edge
+                 in the right part with the biggest cos(A) */
 
-                    for (k = 0; k < 3; k++)
-                      adj_face_norm[k] = face_normal[3*adj_face_id+k];
+            double  cprod[3], mean_normal[3], cosine;
 
-                    dprod = _dot_product(adj_face_norm, face_norm);
-                    dprod2 = dprod * dprod;
+            for (k = 0; k < 3; k++) {
+              v2v3[k] = vertices[vid3].coord[k] - vertices[vid2].coord[k];
+              mean_normal[k] = 0.5 * (fnorm[k] + adj_fnorm[k]);
+            }
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-                    if (tst_dbg)
-                      bft_printf("\t dp: %g, dp2: %g Vs plane: %g -"
-                                 " AdjNorm: [%g %g %g] - Norm: [%g %g %g]\n",
-                                 dprod, dprod2, plane, adj_face_norm[0],
-                                 adj_face_norm[1], adj_face_norm[2],
-                                 face_norm[0], face_norm[1], face_norm[2]);
-#endif
+            norm = _norm(v2v3);
+            for (k = 0; k < 3; k++)
+              v2v3[k] /= norm;
 
-                    if (dprod2 > plane2) {
+            _cross_product(v1v2, v2v3, cprod);
+            dprod = _dot_product(cprod, mean_normal);
+            cosine = _cosine(v1v2, v2v3);
 
-                      if (face_face_connect == NULL) {
-                        found = true;
+            if (dprod >= -eps_dot_prod * _norm(cprod)) {
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-                        if (tst_dbg)
-                          bft_printf("\t -> Adj face is OK\n");
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+              if (tst_dbg)
+                bft_printf("\tLeft choice >> cos: %10.8e / min_cos: %10.8e\n"
+                           "\t         and dprod: %10.8e / crit: %10.8e\n",
+                           cosine, left_min_cos, dprod,
+                           -eps_dot_prod*_norm(cprod));
 #endif
-                      }
-                      else { /* To be implemented ... */
+              /* Left part. We choose the edge with the smallest cosine */
+              if (cosine < left_min_cos) {
+                left_min_cos = cosine;
+                left_next_vertex = vid3 + 1;
+                left_next_edge = edges->edge_lst[i];
+              }
 
-                        assert(face_face_connect != NULL);
-                        bft_error(__FILE__, __LINE__, 0,
-                                  _("  face splitting with face -> face"
-                                    " connectivity is not yet implemented\n"));
+            }
+            else { /* In the right part. We choose the edge with
+                      the biggest cosine. */
+
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+              if (tst_dbg)
+                bft_printf("\tRight choice >> cos: %10.8e / max_cos: %10.8e\n"
+                           "\t          and dprod: %10.8e / crit: %10.8e\n",
+                           cosine, right_max_cos, dprod,
+                           -eps_dot_prod*_norm(cprod));
+#endif
 
-                        /* Check if adj_face_id+1 is in face-face connect. */
-                      }
+              if (cosine > right_max_cos) {
+                right_max_cos = cosine;
+                right_next_vertex = vid3 + 1;
+                right_next_edge = edges->edge_lst[i];
+              }
 
-                    }
+            } /* End if dot_prod < 0 */
 
-                  } /* End if adj_face_id != face_id */
-                  else {
+          } /* End if respect_plane = true */
 
-                    assert(adj_face_id == face_id);
-                    found = true;
+        } /* The connected vertex is inside the face bounding box */
 
-                  }
+      } /* vid3 != vid1 */
 
-                } /* End of loop on faces sharing this edge */
+    } /* End of loop on connected vertices */
 
-                if (found == true) {
+    if (left_min_cos < max_limit_cos) {
+      *next_edge = left_next_edge;
+      *next_vertex = left_next_vertex;
+    }
+    else if (right_max_cos > min_limit_cos) {
+      *next_edge = right_next_edge;
+      *next_vertex = right_next_vertex;
+    }
+    else if (   left_min_cos  >= max_limit_cos
+             && right_max_cos <= min_limit_cos)
+      return OPEN_CYCLE_ERROR;
+
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+    if (tst_dbg)
+      bft_printf(" [Result] >> next_vtx: %u; next_edge: %u\n",
+                 vertices[*next_vertex-1].gnum,
+                 edges->gnum[CS_ABS(*next_edge)-1]);
+#endif
 
-                  /* Continue to build the new sub-face connectivity.
-                     adj_edge_id is in the plane as edge_id
+  } /* End if n_connect_vertices > 2 */
 
-                     We look for the edge which is the most on the
-                     left among all the adjacent edges.
+  else if (n_connect_vertices == 2) {
 
-                                                 |
-                                             \   |   /
-                    adj. edge : E2 ==>        \  |  /
-                                               \ | /      Left part
-                                                \|/
-                    current edge : E1 ==> -->----o------  ............
-                                                /|\
-                                               / | \      Right part
-                                              /  |  \
-                                             /   |   \
+    /* Loop on connected vertices */
 
-                    E2 is in the left part if :
-                     - angle A between E1 and E2 is in [0, Pi[
-                     - i.e. sin(A) >= 0
-                        ->   ->  ->            ->
-                     - (E1 X E2).n  >= 0 where n is the face normal vector
+    for (i = v2v_s; i < v2v_e; i++) {
 
-                     Edge which is the most on the left is the one which has
-                     the minimal cos(A)
+      cs_int_t  vid3 = edges->adj_vtx_lst[i]-1;
 
-                     If there is no edge in the left part, we choose the edge
-                     in the right part with the biggest cos(A)
+      if (vid3 != vid1) {
+        *next_edge = edges->edge_lst[i];
+        *next_vertex = vid3 + 1;
+      }
 
-                  */
+    } /* End of loop on connected vertices */
 
-                  cs_real_t  cprod[3], dprod, cosine;
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+    if (tst_dbg)
+      bft_printf(" [Result] >> next_vtx: %u; next_edge: %u (ONLY 2)\n",
+                 vertices[*next_vertex-1].gnum,
+                 edges->gnum[CS_ABS(*next_edge)-1]);
+#endif
 
-                  _cross_product(v1v2_vect, connect_vect, cprod);
-                  dprod = _dot_product(cprod, face_norm);
-                  cosine = _cosine(v1v2_vect, connect_vect);
+  }
+  else { /* No connection */
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-                  if (tst_dbg)
-                    bft_printf("\t dot_prod: %g (DP>0=>min | DP<0=>max), cosine: %g\n",
-                               dprod, cosine);
-#endif
+    assert(n_connect_vertices < 2);
 
-                  if (dprod >= -eps_dot_prod * _norm(cprod) ) {
-                    /* Left part. We choose the edge with the smallest cosine */
+    bft_error(__FILE__, __LINE__, 0,
+              _(" Joining operation : split face %d\n"
+                " Problem in the connectivity. Could not find a "
+                "connection with the vertex %d\n"), fid, vid1+1);
 
-                    if (cosine < left_min_cos) {
-                      left_min_cos = cosine;
-                      left_next_vertex = connect_vid + 1;
-                      left_next_edge = edges->edge_lst[i];
-                    }
 
-                  } /* dprod > 0 */
+  } /* End of test on the number of vertices connected to vid2 */
 
-                  else { /* In the right part. We choose the edge with
-                            the biggest cosine. */
+  assert(*next_edge != 0);
+  assert(*next_vertex != 0);
 
-                    if (cosine > right_max_cos) {
-                      right_max_cos = cosine;
-                      right_next_vertex = connect_vid + 1;
-                      right_next_edge = edges->edge_lst[i];
-                    }
+  return NO_SPLIT_ERROR;
 
-                  } /* End if dot_prod < 0 */
+}
 
-                } /* End if found = true */
+/*----------------------------------------------------------------------------
+ * Split the current face into sub-faces under the "plane" tolerance
+ * (check if two faces are coplanear).
+ *
+ * parameters:
+ *   fid       <-- fid of the current in the cs_join_mesh_t struct.
+ *   block_id      <-- current id in face_builder_t structure
+ *   plane         <-- tolerance parameter to check coplanearity
+ *   max_subfaces  <-- maximum number of sub faces
+ *   verbosity     <-- level of accuracy in information display
+ *   face_normal   <-- normal for each face of the mesh
+ *   work          <-- cs_join_mesh_t structure
+ *   e2f_idx <-- "edge -> face" connect. index
+ *   e2f_lst <-- "edge -> face" connect. list
+ *   builder       <-> face_builder structure
+ *   head_edges    <-> pointer to a resizable set structure
+ *   subface_edges <-> pointer to a resizable set structure
+ *   ext_edges     <-> pointer to a resizable set structure
+ *   int_edges     <-> pointer to a resizable set structure
+ *
+ * returns:
+ *   an error code (enum: cs_join_split_error_t)
+ *---------------------------------------------------------------------------*/
 
-              } /* The connected vertex is inside the face bounding box */
+static cs_join_split_error_t
+_split_face(cs_int_t                fid,
+            cs_int_t                block_id,
+            cs_join_param_t         param,
+            const cs_real_t         face_normal[],
+            const cs_join_mesh_t   *work,
+            const cs_join_edges_t  *edges,
+            const cs_int_t         *e2f_idx,
+            const cs_int_t         *e2f_lst,
+            face_builder_t         *builder,
+            cs_join_rset_t        **head_edges,
+            cs_join_rset_t        **subface_edges,
+            cs_join_rset_t        **ext_edges,
+            cs_join_rset_t        **int_edges)
+{
+  cs_int_t  j, k, i1, i2, i_int, i_ext;
+  cs_int_t  first_vid, vid1, vid2;
+  cs_int_t  subface_shift, connect_shift, connect_start;
+  cs_int_t   next_vertex, next_edge;
+  cs_join_split_error_t  status;
 
-            } /* connect_vid != vid1 */
+  cs_int_t  n_subfaces = 0, head_edge_shift = 0;
+  cs_real_t  max_coord[3] = {-DBL_MAX, -DBL_MAX, -DBL_MAX};
+  cs_real_t  min_coord[3] = {DBL_MAX, DBL_MAX, DBL_MAX};
+  cs_join_rset_t  *_head_edges = *head_edges;
+  cs_join_rset_t  *_subface_edges = *subface_edges;
+  cs_join_rset_t  *_ext_edges = *ext_edges;
+  cs_join_rset_t  *_int_edges = *int_edges;
 
-          } /* End of loop on connected vertices */
+  const fvm_gnum_t  *fgnum = work->face_gnum;
+  const int  max_subfaces = param.max_sub_faces;
+  const int  verbosity = param.verbosity;
 
-          if (left_min_cos < max_limit_cos) {
-            next_edge = left_next_edge;
-            next_vertex = left_next_vertex;
-          }
-          else if (right_max_cos > min_limit_cos) {
-            next_edge = right_next_edge;
-            next_vertex = right_next_vertex;
-          }
-          else if (   left_min_cos  >= max_limit_cos
-                   && right_max_cos <= min_limit_cos) {
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+#define _DBGTST 1
+  cs_bool_t  tst_dbg = ( fid==492 || fid==1039 || fid==744 || fid==262 ||
+                         fid==546 || fid==1057 || fid==564 ? true : false);
+  const cs_join_vertex_t  *vertices = work->vertices;
+#else
+#define _DBGTST 0
+#endif
 
-            /* Set return pointers */
+  /* Bounding box:  min./max. coordinates of vertices allowed for
+     reconstruction */
 
-            *head_edges = _head_edges;
-            *ext_edges = _ext_edges;
-            *int_edges = _int_edges;
-            *subface_edges = _subface_edges;
+  _face_bbox(work, fid, min_coord, max_coord);
 
-            if (verbosity > 1)
-              bft_printf("\nWarning: open cycle for global face %u\n",
-                         work->face_gnum[face_id]);
+  /* Loop on head edges */
 
-            return OPEN_CYCLE_ERROR; /* open cycle */
+  subface_shift = builder->face_index[block_id];
+  connect_shift = builder->subface_index->array[subface_shift];
+  connect_start = connect_shift;
 
-          }
+  assert(connect_start == builder->subface_connect->n_elts);
 
-          assert(next_edge != 0);
-          assert(next_vertex != 0);
+  while (_head_edges->n_elts > 0) { /* Loop until there is one head edge */
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-          if (tst_dbg)
-            bft_printf(" Result: next_vertex: %u - next_edge: %u\n",
-                       vertices[next_vertex-1].gnum,
-                       edges->gnum[CS_ABS(next_edge)-1]);
-#endif
+    _int_edges->n_elts = 0;
+    head_edge_shift = 0;
+    _subface_edges->n_elts = 0;
 
-        } /* End if n_connect_vertices > 2 */
+    assert(_head_edges->n_elts == _ext_edges->n_elts);
 
-        else if (n_connect_vertices == 2) {
+    while (head_edge_shift < _head_edges->n_elts) { /* Build a new sub-face */
 
-          /* Loop on connected vertices */
+      cs_int_t  head_edge_num = _head_edges->array[head_edge_shift];
+      cs_int_t  edge_num = head_edge_num;
+      cs_int_t  edge_id = FVM_ABS(edge_num) - 1;
 
-          for (i = v2v_start; i < v2v_end; i++) {
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+      if (tst_dbg)
+        bft_printf(" fnum: %d, fgnum: %u, head_shift: %d, edge_num: %d\n",
+                   fid+1, fgnum[fid], head_edge_shift, edge_num);
+#endif
 
-            cs_int_t  connect_vid = edges->adj_vtx_lst[i]-1;
+      if (edge_num > 0) {
+        vid1 = edges->def[2*edge_id] - 1;
+        vid2 = edges->def[2*edge_id+1] - 1;
+      }
+      else {
+        vid1 = edges->def[2*edge_id+1] - 1;
+        vid2 = edges->def[2*edge_id] - 1;
+      }
 
-            if (connect_vid != vid1) {
-              next_edge = edges->edge_lst[i];
-              next_vertex = connect_vid + 1;
-            }
+      cs_join_rset_resize(&(builder->subface_connect), connect_shift + 1);
+      cs_join_rset_resize(&_subface_edges, _subface_edges->n_elts);
 
-          } /* End of loop on connected vertices */
+      builder->subface_connect->array[connect_shift++] = vid1+1;
+      builder->subface_connect->array[connect_shift++] = vid2+1;
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-          if (tst_dbg)
-            bft_printf(" Result (connect only by 2):"
-                       " next_vertex: %u - next_edge: %u\n",
-                       vertices[next_vertex-1].gnum,
-                       edges->gnum[CS_ABS(next_edge)-1]);
+      _subface_edges->array[_subface_edges->n_elts++] = edge_num;
+
+      first_vid = vid1;
+
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
+      if (tst_dbg)
+        bft_printf(" Current edge (v1,v2): [%u,%u]\n",
+                   vertices[vid1].gnum, vertices[vid2].gnum);
 #endif
 
-        }
-        else {
+      while (vid2 != first_vid) {
+
+        status = _find_next(param,
+                            fid,
+                            vid1, vid2,
+                            max_coord, min_coord,
+                            face_normal,
+                            work,
+                            edges,
+                            e2f_idx, e2f_lst,
+                            &next_edge, &next_vertex);
 
-          assert(n_connect_vertices < 2);
+        if (status == OPEN_CYCLE_ERROR) { /* Set return pointers */
 
-          bft_error(__FILE__, __LINE__, 0,
-                    _(" Joining operation : split face %d\n"
-                      " Problem in the connectivity. Could not find a "
-                      "connection with the vertex %d\n"),
-                    face_id, vid1+1);
+          *head_edges = _head_edges;
+          *ext_edges = _ext_edges;
+          *int_edges = _int_edges;
+          *subface_edges = _subface_edges;
 
+          if (verbosity > 2)
+            bft_printf(_(" Warning: open cycle for global face %u\n"),
+                       fgnum[fid]);
 
-        } /* End of test on the number of vertices connected to vid2 */
+          return OPEN_CYCLE_ERROR; /* open cycle */
+
+        }
+
+        assert(status == NO_SPLIT_ERROR);
 
         /* Add the next edge in the sub-face definition */
 
@@ -1045,7 +1209,6 @@ _split_face(cs_int_t                face_id,
         if (next_vertex != first_vid + 1) {
 
           /* Add the next vertex in the sub-face definition */
-
           cs_join_rset_resize(&(builder->subface_connect), connect_shift);
           builder->subface_connect->array[connect_shift++] = next_vertex;
 
@@ -1062,25 +1225,22 @@ _split_face(cs_int_t                face_id,
 
             cs_int_t e2 = CS_ABS(_subface_edges->array[i2]);
 
-            if (e1 == e2) {
-
-              /* Returns pointers */
+            if (e1 == e2) { /* Returns pointers */
 
               *head_edges = _head_edges;
               *ext_edges = _ext_edges;
               *int_edges = _int_edges;
               *subface_edges = _subface_edges;
 
-              if (verbosity > 1)
-                bft_printf("\nWarning: global face %u traversed twice.\n",
-                           work->face_gnum[face_id]);
+              if (verbosity > 2)
+                bft_printf(_(" Warning: global face %u scanned twice\n"),
+                           fgnum[fid]);
 
               return EDGE_TRAVERSED_TWICE_ERROR;  /* Face building problem */
 
             }
 
           }
-
         } /* End of loop on sub-face edges to check no-redundancy */
 
         /* Clean _head_edges if next_edge belongs to this list */
@@ -1106,33 +1266,30 @@ _split_face(cs_int_t                face_id,
           if (CS_ABS(next_edge) == CS_ABS(_ext_edges->array[i_ext]))
             break;
 
-        /* Test if next_edges is in the _int_edges list.
-             If not : store next_edge in the _int_edges list.
-             If yes : delete it.
-        */
-
         if (i_ext != 0 && i_ext == _ext_edges->n_elts) {
 
+          /* next_edge is not in _ext_edges
+             Test if next_edge is in the _int_edges list.
+               If not : store next_edge in the _int_edges list.
+               If yes : delete it. */
+
           for (i_int = 0; i_int < _int_edges->n_elts; i_int++)
             if (CS_ABS(next_edge) == CS_ABS(_int_edges->array[i_int]))
               break;
 
           if (i_int == _int_edges->n_elts) { /* Add next_edge to the list */
-
             cs_join_rset_resize(&_int_edges, _int_edges->n_elts);
             _int_edges->array[_int_edges->n_elts++] = next_edge;
-
           }
           else { /* Delete next_edge of the list */
 
             _int_edges->n_elts -= 1;
-
             for (k = i_int; k < _int_edges->n_elts; k++)
               _int_edges->array[k] = _int_edges->array[k+1];
 
           }
 
-        } /* Next_edge is an interior edge */
+        } /* Next_edge is not an ext_edges */
 
       } /* End of while vid2 != first_vid */
 
@@ -1150,23 +1307,21 @@ _split_face(cs_int_t                face_id,
       head_edge_shift++;
       n_subfaces++;
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
+#if _DBGTST && defined(DEBUG) && !defined(NDEBUG)
       if (tst_dbg)
         bft_printf(" END OF BUILDING subface %d\n\n", n_subfaces);
 #endif
 
-      if (n_subfaces > max_subfaces) { /* Too many sub-faces */
-
-        /* Set return pointers */
+      if (n_subfaces > max_subfaces) { /* Set return pointers */
 
         *head_edges = _head_edges;
         *ext_edges = _ext_edges;
         *int_edges = _int_edges;
         *subface_edges = _subface_edges;
 
-        if (verbosity > 1)
-          bft_printf("\nWarning: loop limit exceeded for global face %u\n.",
-                     work->face_gnum[face_id]);
+        if (verbosity > 2)
+          bft_printf(_(" Warning: loop limit reached for global face %u\n"),
+                     fgnum[fid]);
 
         return LOOP_LIMIT_ERROR;
       }
@@ -1255,13 +1410,16 @@ _indexed_is_greater(size_t           i1,
 
 /*----------------------------------------------------------------------------
  * Define a global numbering for the subfaces after splitting faces.
+ * Synchronize face connectivity.
  *
  * parameters:
- *   builder <-> pointer to a face builder structure
+ *   builder  <-> pointer to a face builder structure
+ *   work     <-- cs_join_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 static void
-_get_subface_gnum(face_builder_t  *builder)
+_get_subface_gnum(face_builder_t         *builder,
+                  const cs_join_mesh_t   *work)
 {
   cs_int_t  i, j, k, shift;
   fvm_gnum_t  min_val;
@@ -1270,10 +1428,11 @@ _get_subface_gnum(face_builder_t  *builder)
   cs_int_t  n_subfaces = builder->face_index[builder->n_faces];
   cs_int_t  *index = builder->subface_index->array;
   fvm_gnum_t  *gconnect = builder->subface_gconnect;
-  fvm_gnum_t  *glob_list = NULL, *tmp = NULL;
+  fvm_gnum_t  *glob_list = NULL, *tmp = NULL, *vgnum = NULL;
   fvm_io_num_t  *subface_io_num = NULL;
 
   const fvm_gnum_t  *global_num = NULL;
+  const cs_join_vertex_t  *vertices = work->vertices;
 
   assert(index != NULL);
 
@@ -1338,10 +1497,32 @@ _get_subface_gnum(face_builder_t  *builder)
 
   } /* End of loop on subfaces */
 
-  /* Copy glob_list as the new subface global connectivity */
+  /* Copy glob_list as the new subface global connectivity and
+     use it to define a synchronized sub-face connectivity */
+
+  BFT_MALLOC(vgnum, work->n_vertices, fvm_gnum_t);
+
+  for (i = 0; i < work->n_vertices; i++)
+    vgnum[i] = vertices[i].gnum;
+
+  for (i = 0; i < n_subfaces; i++) {
+
+    for (j = index[i]; j < index[i+1]; j++) {
+
+      gconnect[j] = glob_list[j];
 
-  for (i = 0; i < index[n_subfaces]; i++)
-    gconnect[i] = glob_list[i];
+      k = cs_search_g_binary(work->n_vertices,
+                             glob_list[j],
+                             vgnum);
+
+      assert(k != -1);
+      builder->subface_connect->array[j] = k+1;
+
+    }
+
+  } /* End of loop on subfaces */
+
+  BFT_FREE(vgnum);
 
   if (cs_glob_n_ranks > 1) { /* Parallel treatment */
 
@@ -1405,10 +1586,10 @@ _get_subface_gnum(face_builder_t  *builder)
       cs_int_t  start = index[i], end = index[i+1];
       cs_int_t  n_elts = end - start;
 
-      bft_printf(" subface %5d - gnum: %u - connect_size: %d - ",
+      bft_printf(" subface %5d - gnum: %10u - connect_size: %d - ",
                  i+1, builder->subface_gnum[i], n_elts);
       for (j = start; j < end; j++)
-        bft_printf(" %u ", glob_list[j]);
+        bft_printf(" %8u ", glob_list[j]);
       bft_printf("\n");
 
     }
@@ -1434,15 +1615,17 @@ _get_subface_gnum(face_builder_t  *builder)
  * Update a cs_join_mesh_t structure thanks to a face_builder_t structure.
  *
  * parameters:
- *   block_info <-- set of paramaters defining a contiguous distribution
- *   builder    <-- pointer to the distributed face builder structure
- *   mesh       <-> pointer to the local cs_join_mesh_t structure
+ *   block_info  <-- set of paramaters defining a contiguous distribution
+ *   builder     <-- pointer to the distributed face builder structure
+ *   mesh        <-> pointer to the local cs_join_mesh_t structure
+ *   p_o2n_hist  <-> pointer to old global face -> new local face numbering
  *---------------------------------------------------------------------------*/
 
 static void
 _update_mesh_after_split(cs_join_block_info_t    block_info,
                          face_builder_t         *builder,
-                         cs_join_mesh_t        **mesh)
+                         cs_join_mesh_t        **mesh,
+                         cs_join_gset_t        **p_o2n_hist)
 {
   cs_int_t  i, j, k, id, shift, n_subfaces, o_id;
   fvm_gnum_t  prev, cur;
@@ -1451,8 +1634,8 @@ _update_mesh_after_split(cs_join_block_info_t    block_info,
   char  *new_mesh_name = NULL;
   cs_int_t  *subfaces = NULL;
   fvm_lnum_t  *order = NULL;
-  cs_join_mesh_t  *init_mesh = *mesh;
-  cs_join_mesh_t  *new_mesh = NULL;
+  cs_join_gset_t  *o2n_hist = NULL;
+  cs_join_mesh_t  *init_mesh = *mesh, *new_mesh = NULL;
 
   /* Sanity checks */
 
@@ -1528,10 +1711,10 @@ _update_mesh_after_split(cs_join_block_info_t    block_info,
 
   for (i = 0; i < n_new_faces; i++) {
 
-    id = subfaces[i];
-    new_mesh->face_gnum[i] = builder->subface_gnum[id];
-    new_mesh->face_vtx_idx[i+1] =  builder->subface_index->array[id+1]
-                                 - builder->subface_index->array[id];
+      id = subfaces[i];
+      new_mesh->face_gnum[i] = builder->subface_gnum[id];
+      new_mesh->face_vtx_idx[i+1] =  builder->subface_index->array[id+1]
+                                   - builder->subface_index->array[id];
 
   } /* End of loop on new faces */
 
@@ -1571,39 +1754,8 @@ _update_mesh_after_split(cs_join_block_info_t    block_info,
   BFT_FREE(subfaces);
   BFT_FREE(order);
 
-  cs_join_mesh_destroy(&init_mesh);
-
-  /* Set return pointer */
-
-  *mesh = new_mesh;
-}
-
-/*----------------------------------------------------------------------------
- * For each new sub-face we keep a relation between new and old
- * face global number.
- *
- * parameters:
- *   mesh       <-- mesh on sub-faces after splitting
- *   block_info <-- set of paramaters defining a contiguous distribution
- *   builder    <-- pointer to the distributed face builder structure
- *
- * returns:
- *   a pointer to a cs_join_gset_t structure saving relation between new
- *   and old faces
- *---------------------------------------------------------------------------*/
-
-static cs_join_gset_t *
-_keep_history(cs_join_mesh_t        *mesh,
-              cs_join_block_info_t   block_info,
-              face_builder_t        *builder)
-{
-  cs_int_t  i, j;
-
-  cs_join_gset_t  *o2n_hist = NULL;
-
-  assert(mesh != NULL);
-
-  /* Create structure in which we keep the history of each new face */
+  /* Create a structure in which we keep a history of global
+     face numbering for each new face */
 
   o2n_hist = cs_join_gset_create(block_info.local_size);
 
@@ -1622,27 +1774,32 @@ _keep_history(cs_join_mesh_t        *mesh,
       o2n_hist->index[i] = builder->face_index[i];
 
     BFT_MALLOC(o2n_hist->g_list,
-               o2n_hist->index[o2n_hist->n_elts],
-               fvm_gnum_t);
+               o2n_hist->index[o2n_hist->n_elts], fvm_gnum_t);
 
     for (i = 0; i < builder->n_faces; i++) {
+
       for (j = builder->face_index[i]; j < builder->face_index[i+1]; j++) {
 
-        cs_int_t  id = cs_search_g_binary(mesh->n_faces,
-                                          builder->subface_gnum[j],
-                                          mesh->face_gnum);
+        id = cs_search_g_binary(new_mesh->n_faces,
+                                builder->subface_gnum[j],
+                                new_mesh->face_gnum);
 
         assert(id != -1);
-        o2n_hist->g_list[j] = id + 1;  /* store local face num. */
+        o2n_hist->g_list[j] = id + 1;  /* store local new face num. */
 
       }
-    }
+
+    } /* End of loop on initial faces */
 
   } /* block.local_size > 0 */
 
-  /* Free memory */
+  cs_join_mesh_destroy(&init_mesh);
+
+  /* Set return pointer */
+
+  *mesh = new_mesh;
+  *p_o2n_hist = o2n_hist;
 
-  return  o2n_hist;
 }
 
 /*============================================================================
@@ -1650,7 +1807,7 @@ _keep_history(cs_join_mesh_t        *mesh,
  *===========================================================================*/
 
 /*----------------------------------------------------------------------------
- * Build new faces after the vertex fusion operation. Split initial faces into
+ * Build new faces after the vertex merge operation. Split initial faces into
  * subfaces and keep the historic between initial/final faces.
  *
  * parameters:
@@ -1669,51 +1826,50 @@ cs_join_split_faces(cs_join_param_t          param,
                     cs_join_mesh_t         **work,
                     cs_join_gset_t         **old2new_history)
 {
-  cs_int_t  i, j, face_s, subface_s, block_id;
+  cs_int_t  fid, j, face_s, subface_s, block_id, vid;
+  fvm_gnum_t  vgnum;
   cs_join_split_error_t  code;
   cs_join_block_info_t  block_info;
 
-  cs_int_t  _n_problems = 0, n_face_problems = 0, n_max_face_vertices = 0;
-  cs_int_t  *edge_face_idx = NULL, *edge_face_lst = NULL;
+  cs_int_t  _n_problems = 0, n_face_problems = 0, n_max_face_vertices = 6;
+  cs_int_t  *e2f_idx = NULL, *e2f_lst = NULL;
   cs_join_gset_t  *_old2new_history = NULL;
   cs_join_rset_t  *open_cycle = NULL, *edge_traversed_twice = NULL;
   cs_join_rset_t  *loop_limit = NULL, *head_edges = NULL;
   cs_join_rset_t  *subface_edges = NULL, *ext_edges = NULL, *int_edges = NULL;
-  face_builder_t  *loc_builder = NULL;
-  cs_join_mesh_t  *_work = *work;
-
-  const double plane = cos(param.plane *acos(-1.0)/180.);
+  face_builder_t  *builder = NULL;
+  cs_join_mesh_t  *w = *work;
 
-  const cs_int_t  n_init_faces = _work->n_faces;
+  const cs_int_t  n_init_faces = w->n_faces;
   const int  n_ranks = cs_glob_n_ranks;
   const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
 
-  assert(_work != NULL);
+  assert(w != NULL);
   assert(edges != NULL);
 
   /* Use the cs_join_edges_t structure to build
      the "edge -> face" connectivity */
 
-  cs_join_mesh_get_edge_face_adj(_work, edges, &edge_face_idx, &edge_face_lst);
+  cs_join_mesh_get_edge_face_adj(w, edges, &e2f_idx, &e2f_lst);
 
   /* Define buffers to manage errors */
 
-  open_cycle = cs_join_rset_create(2);
-  edge_traversed_twice = cs_join_rset_create(2);
-  loop_limit = cs_join_rset_create(2);
+  open_cycle = cs_join_rset_create(3);
+  edge_traversed_twice = cs_join_rset_create(3);
+  loop_limit = cs_join_rset_create(3);
 
   /* Define buffers and structures to build the new faces */
 
-  head_edges = cs_join_rset_create(5);
-  subface_edges = cs_join_rset_create(5);
-  ext_edges = cs_join_rset_create(5);
-  int_edges = cs_join_rset_create(5);
+  head_edges = cs_join_rset_create(n_max_face_vertices);
+  subface_edges = cs_join_rset_create(n_max_face_vertices);
+  ext_edges = cs_join_rset_create(n_max_face_vertices);
+  int_edges = cs_join_rset_create(n_max_face_vertices);
 
   /* Compute block_size */
 
-  block_info = cs_join_get_block_info(_work->n_g_faces, n_ranks, local_rank);
+  block_info = cs_join_get_block_info(w->n_g_faces, n_ranks, local_rank);
 
-  loc_builder = _create_face_builder(block_info.local_size);
+  builder = _create_face_builder(block_info.local_size);
 
   /*
      We only have to treat faces for the current rank's block because the
@@ -1722,19 +1878,16 @@ cs_join_split_faces(cs_join_param_t          param,
      Main loop on faces.
   */
 
-  for (i = 0, block_id = 0; i < n_init_faces; i++) {
+  for (fid = 0, block_id = 0; fid < n_init_faces; fid++) {
 
-    int  block_rank = (_work->face_gnum[i] - 1)/block_info.size;
+    int  block_rank = (w->face_gnum[fid] - 1)/block_info.size;
 
     if (block_rank == local_rank) { /* This face is a "main" face for the
                                        local rank */
 
-      cs_int_t  n_face_vertices =
-        _work->face_vtx_idx[i+1] - _work->face_vtx_idx[i];
-
-      /* Manage list size */
+      int  n_face_vertices = w->face_vtx_idx[fid+1] - w->face_vtx_idx[fid];
 
-      if (n_face_vertices > n_max_face_vertices) {
+      if (n_face_vertices > n_max_face_vertices) { /* Manage list size */
 
         n_max_face_vertices = n_face_vertices;
         cs_join_rset_resize(&head_edges, n_face_vertices);
@@ -1746,40 +1899,31 @@ cs_join_split_faces(cs_join_param_t          param,
 
       /* Fill head_edges and ext_edges */
 
-      _define_head_and_ext_edges(i,  /* face_id */
-                                 _work,
-                                 edges,
-                                 head_edges,
-                                 ext_edges,
+      _define_head_and_ext_edges(fid,
+                                 w, edges,
+                                 head_edges, ext_edges,
                                  0); /* No permutation */
 
-      /* Store initial loc_builder state in case of code > 0 */
+      /* Store initial builder state in case of code > 0 */
 
-      face_s = loc_builder->face_index[block_id];
-      subface_s = loc_builder->subface_index->array[face_s];
+      face_s = builder->face_index[block_id];
+      subface_s = builder->subface_index->array[face_s];
 
       /* Split the current face into subfaces */
 
-      code = _split_face(i,       /* face_id */
-                         block_id,
-                         plane,
-                         param.max_sub_faces,
-                         param.verbosity,
+      code = _split_face(fid, block_id,
+                         param,
                          face_normal,
-                         _work,
-                         edges,
-                         edge_face_idx,
-                         edge_face_lst,
-                         loc_builder,
-                         &head_edges,
-                         &subface_edges,
-                         &ext_edges,
-                         &int_edges);
+                         w, edges,
+                         e2f_idx, e2f_lst,
+                         builder,
+                         &head_edges, &subface_edges,
+                         &ext_edges, &int_edges);
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
       if (param.verbosity > 1 && code != NO_SPLIT_ERROR) {
-        bft_printf(_("  Split face: %d with returned code: %d\n"), i+1, code);
-        _dump_face_builder(block_id, loc_builder);
+        bft_printf(_("  Split face %d >> returned code: %d\n"), fid+1, code);
+        _dump_face_builder(block_id, builder);
       }
 #endif
 
@@ -1795,36 +1939,27 @@ cs_join_split_faces(cs_join_param_t          param,
 
           /* Fill head_edges and ext_edges */
 
-          _define_head_and_ext_edges(i, /* face_id */
-                                     _work,
-                                     edges,
-                                     head_edges,
-                                     ext_edges,
+          _define_head_and_ext_edges(fid,
+                                     w, edges,
+                                     head_edges, ext_edges,
                                      _n_problems); /* permutation */
 
-          /* Retrieve initial loc_builder state */
+          /* Retrieve initial builder state */
 
-          loc_builder->face_index[block_id] = face_s;
-          loc_builder->subface_index->array[face_s] = subface_s;
-          loc_builder->subface_connect->n_elts = subface_s;
+          builder->face_index[block_id] = face_s;
+          builder->subface_index->array[face_s] = subface_s;
+          builder->subface_connect->n_elts = subface_s;
 
           /* Split the current face into subfaces */
 
-          code = _split_face(i,   /* face_id */
-                             block_id,
-                             plane,
-                             param.max_sub_faces,
-                             param.verbosity,
+          code = _split_face(fid, block_id,
+                             param,
                              face_normal,
-                             _work,
-                             edges,
-                             edge_face_idx,
-                             edge_face_lst,
-                             loc_builder,
-                             &head_edges,
-                             &subface_edges,
-                             &ext_edges,
-                             &int_edges);
+                             w, edges,
+                             e2f_idx, e2f_lst,
+                             builder,
+                             &head_edges, &subface_edges,
+                             &ext_edges, &int_edges);
 
           _n_problems++;
 
@@ -1838,20 +1973,20 @@ cs_join_split_faces(cs_join_param_t          param,
 
           case OPEN_CYCLE_ERROR:
             cs_join_rset_resize(&open_cycle, open_cycle->n_elts);
-            open_cycle->array[open_cycle->n_elts] = i + 1;
+            open_cycle->array[open_cycle->n_elts] = fid + 1;
             open_cycle->n_elts += 1;
             break;
 
           case EDGE_TRAVERSED_TWICE_ERROR:
             cs_join_rset_resize(&edge_traversed_twice,
                                 edge_traversed_twice->n_elts);
-            edge_traversed_twice->array[edge_traversed_twice->n_elts] = i + 1;
+            edge_traversed_twice->array[edge_traversed_twice->n_elts] = fid + 1;
             edge_traversed_twice->n_elts += 1;
             break;
 
           case LOOP_LIMIT_ERROR:
             cs_join_rset_resize(&loop_limit, loop_limit->n_elts);
-            loop_limit->array[loop_limit->n_elts] = i + 1;
+            loop_limit->array[loop_limit->n_elts] = fid + 1;
             loop_limit->n_elts += 1;
             break;
 
@@ -1867,33 +2002,32 @@ cs_join_split_faces(cs_join_param_t          param,
 
           /* Keep the initial face connectivity */
 
-          loc_builder->face_index[block_id] = face_s;
-          loc_builder->face_index[block_id+1] = face_s + 1;
+          builder->face_index[block_id] = face_s;
+          builder->face_index[block_id+1] = face_s + 1;
 
           /* face -> subface connectivity index update */
 
-          cs_join_rset_resize(&(loc_builder->subface_index), face_s+1);
+          cs_join_rset_resize(&(builder->subface_index), face_s+1);
 
-          loc_builder->subface_index->n_elts = face_s + 1;
-          loc_builder->subface_index->array[face_s] = subface_s;
-          loc_builder->subface_index->array[face_s+1]
-            = subface_s + n_face_vertices;
+          builder->subface_index->n_elts = face_s + 1;
+          builder->subface_index->array[face_s] = subface_s;
+          builder->subface_index->array[face_s+1] = subface_s + n_face_vertices;
 
           /* face -> subface connectivity list update */
 
-          cs_join_rset_resize(&(loc_builder->subface_connect),
+          cs_join_rset_resize(&(builder->subface_connect),
                               subface_s + n_face_vertices);
 
-          loc_builder->subface_connect->n_elts = subface_s + n_face_vertices;
+          builder->subface_connect->n_elts = subface_s + n_face_vertices;
 
           for (j = 0; j < n_face_vertices; j++)
-            loc_builder->subface_connect->array[subface_s + j]
-              = _work->face_vtx_lst[j + _work->face_vtx_idx[i] - 1];
+            builder->subface_connect->array[subface_s + j]
+              = w->face_vtx_lst[j + w->face_vtx_idx[fid] - 1];
 
           if (param.verbosity > 1) {
-            bft_printf("\n Keep initial connectivity for face %d (%u):\n",
-                       i+1, _work->face_gnum[i]);
-            _dump_face_builder(block_id, loc_builder);
+            bft_printf("\n Keep initial connectivity for face %d [%u]:\n",
+                       fid+1, w->face_gnum[fid]);
+            _dump_face_builder(block_id, builder);
           }
 
         } /* End if n_current_face_problems >= n_face_vertices */
@@ -1951,15 +2085,15 @@ cs_join_split_faces(cs_join_param_t          param,
 
       bft_printf
         (_("\n  *** WARNING ***\n"
-           "  Globally, %lu problem(s) found during the face splitting\n"
-           "     %12lu  open cycles,\n"
-           "     %12lu  edges traversed twice,\n"
-           "     %12lu  faces split into more than max_subfaces (= %d)\n\n"
+           "  Globally, %llu problem(s) found during the face splitting\n"
+           "     %12llu  open cycles,\n"
+           "     %12llu  edges traversed twice,\n"
+           "     %12llu  faces split into more than max_subfaces (= %d)\n\n"
            "    => Eventually modify joining parameters\n\n"),
-         (unsigned long)n_g_face_problems,
-         (unsigned long)n_g_open_cycles,
-         (unsigned long)n_g_edges_twice,
-         (unsigned long)n_g_loop_limit, param.max_sub_faces);
+         (unsigned long long)n_g_face_problems,
+         (unsigned long long)n_g_open_cycles,
+         (unsigned long long)n_g_edges_twice,
+         (unsigned long long)n_g_loop_limit, param.max_sub_faces);
       bft_printf_flush();
 
       assert(   n_g_face_problems
@@ -1971,21 +2105,27 @@ cs_join_split_faces(cs_join_param_t          param,
 
       if (n_g_open_cycles > 0)
         cs_join_post_faces_subset("OpenCycleErr",
-                                  _work,
+                                  w,
                                   open_cycle->n_elts,
                                   open_cycle->array);
 
       if (n_g_edges_twice > 0)
         cs_join_post_faces_subset("EdgeScannedTwiceErr",
-                                  _work,
+                                  w,
                                   edge_traversed_twice->n_elts,
                                   edge_traversed_twice->array);
 
-      if (n_g_loop_limit > 0)
+      if (n_g_loop_limit > 0) {
+        bft_printf(_(" At least one original face has been cut into more than"
+                     " %d subfaces\n. You can increase this parameter in"
+                     " usjoin() or usperi() by setting the advanced parameter"
+                     " maxsf.\n Be careful. It may produce mesh with"
+                     " a poor quality.\n"), param.max_sub_faces);
         cs_join_post_faces_subset("LoopLimitErr",
-                                  _work,
+                                  w,
                                   loop_limit->n_elts,
                                   loop_limit->array);
+      }
 
     } /* End of information display */
 
@@ -1993,45 +2133,42 @@ cs_join_split_faces(cs_join_param_t          param,
 
   /* Free vtx_struct structure */
 
-  BFT_FREE(edge_face_idx);
-  BFT_FREE(edge_face_lst);
+  BFT_FREE(e2f_idx);
+  BFT_FREE(e2f_lst);
 
-  { /* Define a global number for each new sub-faces */
-
-    cs_int_t  n_subfaces = loc_builder->face_index[loc_builder->n_faces];
-    cs_int_t  sub_connect_size = loc_builder->subface_index->array[n_subfaces];
+  /* Delete error management lists */
 
-    /* Define subface_gconnect */
+  cs_join_rset_destroy(&open_cycle);
+  cs_join_rset_destroy(&edge_traversed_twice);
+  cs_join_rset_destroy(&loop_limit);
 
-    BFT_MALLOC(loc_builder->subface_gconnect, sub_connect_size, fvm_gnum_t);
+  { /* Define a global number for each new sub-faces */
 
-    for (i = 0; i < sub_connect_size; i++) {
+    int  n_subfaces = builder->face_index[builder->n_faces];
+    int  sub_connect_size = builder->subface_index->array[n_subfaces];
 
-      cs_int_t  vid = loc_builder->subface_connect->array[i] - 1;
-      fvm_gnum_t  vgnum = _work->vertices[vid].gnum;
+    /* Define subface_gconnect */
 
-      loc_builder->subface_gconnect[i] = vgnum;
+    BFT_MALLOC(builder->subface_gconnect, sub_connect_size, fvm_gnum_t);
 
+    for (j = 0; j < sub_connect_size; j++) {
+      vid = builder->subface_connect->array[j] - 1;
+      vgnum = w->vertices[vid].gnum;
+      builder->subface_gconnect[j] = vgnum;
     }
 
-    _get_subface_gnum(loc_builder);
+    _get_subface_gnum(builder, w);
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
     bft_printf("\nFINAL BUILDER STATE\n");
-    for (i = 0; i < loc_builder->n_faces; i++)
-      _dump_face_builder(i, loc_builder);
+    for (fid = 0; fid < builder->n_faces; fid++)
+      _dump_face_builder(fid, builder);
 #endif
 
-    BFT_FREE(loc_builder->subface_gconnect);
+    BFT_FREE(builder->subface_gconnect);
 
   }
 
-  /* Delete error management lists */
-
-  cs_join_rset_destroy(&open_cycle);
-  cs_join_rset_destroy(&edge_traversed_twice);
-  cs_join_rset_destroy(&loop_limit);
-
   /* Update cs_join_mesh_t structure and keep a relation between
      new and old faces.
 
@@ -2050,27 +2187,24 @@ cs_join_split_faces(cs_join_param_t          param,
                        |                            | initial
                        |                            | face
                        `----------------------------'
-  */
 
-  /* Reduce the definition of the working mesh to the set of new
-     global face numbers built from the local block. */
+     Reduce the definition of the working mesh to the set of new
+     global face numbers built from the local block.
+     For each new sub-face we maintain a relation between new and old
+     face global number. Update also face state */
 
-  _update_mesh_after_split(block_info, loc_builder, &_work);
-
-  /* For each new sub-face we maintain a relation between new and old
-     face global number */
-
-  _old2new_history = _keep_history(_work,
-                                   block_info,
-                                   loc_builder);
+  _update_mesh_after_split(block_info,
+                           builder,
+                           &w,
+                           &_old2new_history);
 
   /* Free face_builder_t structure */
 
-  loc_builder = _destroy_face_builder(loc_builder);
+  builder = _destroy_face_builder(builder);
 
   /* Set return pointers */
 
-  *work = _work;
+  *work = w;
   *old2new_history = _old2new_history;
 }
 
@@ -2079,6 +2213,7 @@ cs_join_split_faces(cs_join_param_t          param,
  * Send back to the original rank the new face description.
  *
  * parameters:
+ *   param           <-- set of user-defined parameter
  *   work_mesh       <-- distributed mesh on faces to join
  *   gnum_rank_index <-- index on ranks for the old global face numbering
  *   o2n_hist        <-> old global face -> new local face numbering
@@ -2086,7 +2221,8 @@ cs_join_split_faces(cs_join_param_t          param,
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_split_update_struct(const cs_join_mesh_t   *work_mesh,
+cs_join_split_update_struct(const cs_join_param_t   param,
+                            const cs_join_mesh_t   *work_mesh,
                             const fvm_gnum_t        gnum_rank_index[],
                             cs_join_gset_t        **o2n_hist,
                             cs_join_mesh_t        **local_mesh)
@@ -2119,12 +2255,32 @@ cs_join_split_update_struct(const cs_join_mesh_t   *work_mesh,
 
     MPI_Comm  mpi_comm = fvm_parall_get_mpi_comm();
 
-    /* Save the initial global face numbering */
+    if (param.perio_num > 0) {
 
-    BFT_MALLOC(init_face_gnum, n_init_faces, fvm_gnum_t);
+      n_g_init_faces *= 2;
 
-    for (i = 0; i < n_init_faces; i++)
-      init_face_gnum[i] = _local_mesh->face_gnum[i];
+      /* Save the initial global face numbering */
+
+      BFT_MALLOC(init_face_gnum, 2*n_init_faces, fvm_gnum_t);
+
+      for (i = 0; i < n_init_faces; i++) {
+        init_face_gnum[2*i] = _local_mesh->face_gnum[i];
+        init_face_gnum[2*i+1] = _local_mesh->face_gnum[i]+1;
+      }
+
+      n_init_faces *= 2;
+
+    }
+    else {
+
+      /* Save the initial global face numbering */
+
+      BFT_MALLOC(init_face_gnum, n_init_faces, fvm_gnum_t);
+
+      for (i = 0; i < n_init_faces; i++)
+        init_face_gnum[i] = _local_mesh->face_gnum[i];
+
+    }
 
     /* Free some structures of the mesh */
 
@@ -2162,9 +2318,9 @@ cs_join_split_update_struct(const cs_join_mesh_t   *work_mesh,
 
     /* Synchronize _o2n_hist */
 
-    distrib_sync_hist = cs_join_gset_sync_by_block(n_g_init_faces,
-                                                   _o2n_hist,
-                                                   mpi_comm);
+    distrib_sync_hist = cs_join_gset_block_sync(n_g_init_faces,
+                                                _o2n_hist,
+                                                mpi_comm);
 
     cs_join_gset_destroy(&_o2n_hist);
     _o2n_hist = cs_join_gset_create(n_init_faces);
@@ -2174,39 +2330,16 @@ cs_join_split_update_struct(const cs_join_mesh_t   *work_mesh,
 
     BFT_FREE(init_face_gnum);
 
-    cs_join_gset_update_from_block(n_g_init_faces,
-                                   distrib_sync_hist,
-                                   _o2n_hist,
-                                   mpi_comm);
+    cs_join_gset_block_update(n_g_init_faces,
+                              distrib_sync_hist,
+                              _o2n_hist,
+                              mpi_comm);
 
     cs_join_gset_destroy(&distrib_sync_hist);
 
-
   }
 #endif /* HAVE_MPI */
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-  { /* Full dump of structures */
-
-    int  len;
-    FILE  *dbg_file = NULL;
-    char  *filename = NULL;
-
-    len = strlen("JoinDBG_o2nFaceHist.dat")+1+4;
-    BFT_MALLOC(filename, len, char);
-    sprintf(filename, "JoinDBG_o2nFaceHist%04d.dat",
-            CS_MAX(cs_glob_rank_id, 0));
-    dbg_file = fopen(filename, "w");
-
-    cs_join_gset_dump(dbg_file, _o2n_hist);
-
-    fflush(dbg_file);
-    BFT_FREE(filename);
-    fclose(dbg_file);
-
-  }
-#endif
-
   /* Set return pointers */
 
   *o2n_hist = _o2n_hist;
diff --git a/src/base/cs_join_update.c b/src/base/cs_join_update.c
index d31228f..ecef9b3 100644
--- a/src/base/cs_join_update.c
+++ b/src/base/cs_join_update.c
@@ -66,6 +66,7 @@
 
 #include "cs_search.h"
 #include "cs_sort.h"
+#include "cs_join_perio.h"
 #include "cs_join_post.h"
 #include "cs_join_util.h"
 
@@ -173,6 +174,63 @@ _normalize(double   v[])
 }
 
 /*----------------------------------------------------------------------------
+ * Compute face normal for the current face.
+ *
+ * parameters:
+ *   n_face_vertices <-- number of vertices defining the face
+ *   face_vtx_coord  <-- coordinates of each vertex of the face
+ *                        (size: n_face_vertices+1)
+ *   normal          <-> normal of the face (|normal| = 1)
+ *----------------------------------------------------------------------------*/
+
+static void
+_get_face_normal(cs_int_t          n_face_vertices,
+                 const cs_real_t   face_vtx_coord[],
+                 cs_real_t         normal[])
+{
+  cs_int_t  i, coord;
+  cs_real_t  v1[3], v2[3], tri_normal[3], barycenter[3];
+
+  cs_real_t  inv_n_face_vertices = 1/(double)n_face_vertices;
+
+  /* Initialization */
+
+  for (coord = 0; coord < 3; coord++) {
+    normal[coord] = 0.0;
+    barycenter[coord] = 0.0;
+  }
+
+  /* Compute face barycenter */
+
+  for (i = 0; i < n_face_vertices; i++)
+    for (coord = 0; coord < 3; coord++)
+      barycenter[coord] += face_vtx_coord[3*i+coord];
+
+  for (coord = 0; coord < 3; coord++)
+    barycenter[coord] *= inv_n_face_vertices;
+
+  /* Compute triangle normal and update face normal */
+
+  for (i = 0; i < n_face_vertices; i++) {
+
+    for (coord = 0; coord < 3; coord++) {
+      v1[coord] = face_vtx_coord[3*i     + coord] - barycenter[coord];
+      v2[coord] = face_vtx_coord[3*(i+1) + coord] - barycenter[coord];
+    }
+
+    _cross_product(v1, v2, tri_normal);
+
+    for (coord = 0; coord < 3; coord++) {
+      tri_normal[coord] *= 0.5;
+      normal[coord] += tri_normal[coord];
+    }
+
+  }
+
+  _normalize(normal);
+}
+
+/*----------------------------------------------------------------------------
  * Get the related edge id in edge_builder_t structure from a couple of
  * vertex ids.
  *
@@ -211,137 +269,13 @@ _get_join_edge_id(cs_int_t               v1_id,
 #if defined(HAVE_MPI)
 
 /*----------------------------------------------------------------------------
- * Retrieve the local new global numbering for the initial vertices from
- * the new vertex global numbering defined by block.
- *
- * parameters:
- *   mesh           <-- pointer of pointer to cs_mesh_t structure
- *   p_o2n_vtx_gnum <-> in : array on blocks on the new global vertex
- *                      out: local array on the new global vertex
- *---------------------------------------------------------------------------*/
-
-static void
-_get_local_o2n_vtx_gnum(cs_mesh_t    *mesh,
-                        fvm_gnum_t   *p_o2n_vtx_gnum[])
-{
-  cs_int_t  i, shift, rank;
-  fvm_gnum_t  new_gnum;
-
-  cs_int_t  *send_shift = NULL, *recv_shift = NULL;
-  cs_int_t  *send_count = NULL, *recv_count = NULL;
-  fvm_gnum_t  *send_glist = NULL, *recv_glist = NULL;
-  fvm_gnum_t  *block_gnum = *p_o2n_vtx_gnum;
-  fvm_gnum_t  *local_gnum = NULL;
-
-  MPI_Comm  mpi_comm = cs_glob_mpi_comm;
-
-  const int  n_ranks = cs_glob_n_ranks;
-  const int  local_rank = CS_MAX(cs_glob_rank_id, 0);
-  const cs_join_block_info_t  block_info
-    = cs_join_get_block_info(mesh->n_g_vertices,
-                             n_ranks,
-                             local_rank);
-
-  BFT_MALLOC(local_gnum, mesh->n_vertices, fvm_gnum_t);
-
-  /* Request the new vtx gnum related to the initial vtx gnum */
-
-  BFT_MALLOC(send_count, n_ranks, cs_int_t);
-  BFT_MALLOC(recv_count, n_ranks, cs_int_t);
-
-  for (i = 0; i < n_ranks; i++)
-    send_count[i] = 0;
-
-  for (i = 0; i < mesh->n_vertices; i++) {
-    rank = (mesh->global_vtx_num[i] - 1)/block_info.size;
-    send_count[rank] += 1;
-  }
-
-  MPI_Alltoall(send_count, 1, MPI_INT, recv_count, 1, MPI_INT, mpi_comm);
-
-  BFT_MALLOC(send_shift, n_ranks + 1, cs_int_t);
-  BFT_MALLOC(recv_shift, n_ranks + 1, cs_int_t);
-
-  send_shift[0] = 0;
-  recv_shift[0] = 0;
-
-  for (rank = 0; rank < n_ranks; rank++) {
-    send_shift[rank + 1] = send_shift[rank] + send_count[rank];
-    recv_shift[rank + 1] = recv_shift[rank] + recv_count[rank];
-  }
-
-  /* Build send_list */
-
-  BFT_MALLOC(send_glist, send_shift[n_ranks], fvm_gnum_t);
-  BFT_MALLOC(recv_glist, recv_shift[n_ranks], fvm_gnum_t);
-
-  for (i = 0; i < n_ranks; i++)
-    send_count[i] = 0;
-
-  for (i = 0; i < mesh->n_vertices; i++) {
-
-    rank = (mesh->global_vtx_num[i] - 1)/block_info.size;
-    shift = send_shift[rank] + send_count[rank];
-    send_glist[shift] = mesh->global_vtx_num[i];  /* Old global number */
-    send_count[rank] += 1;
-
-  }
-
-  MPI_Alltoallv(send_glist, send_count, send_shift, FVM_MPI_GNUM,
-                recv_glist, recv_count, recv_shift, FVM_MPI_GNUM,
-                mpi_comm);
-
-  /* Send back to the original rank the new global vertex number */
-
-  for (rank = 0; rank < n_ranks; rank++) {
-
-    for (i = recv_shift[rank]; i < recv_shift[rank+1]; i++) {
-
-      shift = recv_glist[i] - block_info.first_gnum;
-      new_gnum = block_gnum[shift];
-      recv_glist[i] = new_gnum;
-
-    }
-
-  } /* End of loop on ranks */
-
-  MPI_Alltoallv(recv_glist, recv_count, recv_shift, FVM_MPI_GNUM,
-                send_glist, send_count, send_shift, FVM_MPI_GNUM,
-                mpi_comm);
-
-  for (i = 0; i < n_ranks; i++)
-    send_count[i] = 0;
-
-  for (i = 0; i < mesh->n_vertices; i++) {
-
-    rank = (mesh->global_vtx_num[i] - 1)/block_info.size;
-    shift = send_shift[rank] + send_count[rank];
-    local_gnum[i] = send_glist[shift];  /* New global number */
-    send_count[rank] += 1;
-
-  }
-
-  BFT_FREE(send_count);
-  BFT_FREE(send_shift);
-  BFT_FREE(send_glist);
-  BFT_FREE(recv_glist);
-  BFT_FREE(recv_count);
-  BFT_FREE(recv_shift);
-  BFT_FREE(block_gnum);
-
-  /* Return pointer */
-
-  *p_o2n_vtx_gnum = local_gnum;
-}
-
-/*----------------------------------------------------------------------------
  * Update elements of a cs_mesh_t structure related to the vertices after the
- * fusion step.
+ * merge step.
  *
  * parameters:
- *  selection         -->  list of all implied entities in the joining op.
- *  o2n_vtx_id        <->  relation between init. and current local num.
- *  mesh              <->  pointer of pointer to cs_mesh_t structure
+ *   selection  --> list of all implied entities in the joining op.
+ *   o2n_vtx_id <-> relation between init. and current local num.
+ *   mesh       <-> pointer of pointer to cs_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 static void
@@ -361,7 +295,7 @@ _sync_single_vertices(const cs_join_select_t  *selection,
 
   const int  loc_rank = CS_MAX(cs_glob_rank_id, 0);
 
-  bft_printf("\n  Synchronization of the \"single\" elements after the fusion"
+  bft_printf("\n  Synchronization of the \"single\" elements after the merge"
              " step.\n");
   bft_printf_flush();
 
@@ -473,13 +407,13 @@ _sync_single_vertices(const cs_join_select_t  *selection,
  * Update cs_join_edges_t through the synchronization of "single" edges.
  *
  * parameters:
- *  selection         -->  list of all implied entities in the joining op.
- *  n_bm_vertices     -->  number of vertices in mesh before the merge step
- *  o2n_vtx_id        <->  relation between init. and current local num.
- *  n_j_vertices      -->  number of vertices in join_mesh
- *  join2mesh_vtx_id  <->  relation between join mesh and after fusion vertex
- *  join_edges        <->  pointer to a cs_join_edges_t structure
- *  mesh              <->  pointer of pointer to cs_mesh_t structure
+ *  selection        --> list of all implied entities in the joining op.
+ *  n_bm_vertices    --> number of vertices in mesh before the merge step
+ *  o2n_vtx_id       <-> relation between init. and current local num.
+ *  n_j_vertices     --> number of vertices in join_mesh
+ *  join2mesh_vtx_id <-> relation between join mesh and after merge vertex
+ *  join_edges       <-> pointer to a cs_join_edges_t structure
+ *  mesh             <-> pointer of pointer to cs_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 static void
@@ -984,22 +918,22 @@ _update_vertices_after_merge(const fvm_gnum_t       o2n_vtx_gnum[],
   cs_int_t  i, j, k, o_id, j_id;
   fvm_gnum_t  prev, cur;
 
-  cs_int_t  n_am_vertices = -1; /* af: after merge */
+  cs_int_t  n_am_vertices = -1; /* am: after merge */
   cs_real_t  *new_vtx_coord = NULL;
   cs_int_t   *o2n_vtx_id = NULL, *join2mesh_vtx_id = NULL;
   fvm_lnum_t  *order = NULL;
   fvm_gnum_t  *new_vtx_gnum = NULL, *tmp_vtx_gnum = NULL;
 
   const cs_int_t  n_bm_vertices = mesh->n_vertices; /* bm: before merge */
-  const cs_int_t  j_n_vertices = join_mesh->n_vertices;
+  const cs_int_t  n_j_vertices = join_mesh->n_vertices;
   const cs_join_vertex_t  *j_vertices = join_mesh->vertices;
-  const cs_int_t  n_vertices = n_bm_vertices + j_n_vertices;
+  const cs_int_t  n_vertices = n_bm_vertices + n_j_vertices;
   const int  n_ranks = cs_glob_n_ranks;
 
   /* Update initial vertices (local and global numbering) */
 
   BFT_MALLOC(o2n_vtx_id, n_bm_vertices, cs_int_t);
-  BFT_MALLOC(join2mesh_vtx_id, j_n_vertices, cs_int_t);
+  BFT_MALLOC(join2mesh_vtx_id, n_j_vertices, cs_int_t);
   BFT_MALLOC(tmp_vtx_gnum, n_vertices, fvm_gnum_t);
   BFT_MALLOC(new_vtx_gnum, n_vertices, fvm_gnum_t);
   BFT_MALLOC(order, n_vertices, cs_int_t);
@@ -1007,7 +941,7 @@ _update_vertices_after_merge(const fvm_gnum_t       o2n_vtx_gnum[],
   for (i = 0; i < n_bm_vertices; i++)
     tmp_vtx_gnum[i] = o2n_vtx_gnum[i];
 
-  for (i = 0, j = n_bm_vertices; i < j_n_vertices; i++, j++)
+  for (i = 0, j = n_bm_vertices; i < n_j_vertices; i++, j++)
     tmp_vtx_gnum[j] = j_vertices[i].gnum;
 
   fvm_order_local_allocated(NULL, tmp_vtx_gnum, order, n_vertices);
@@ -1029,12 +963,10 @@ _update_vertices_after_merge(const fvm_gnum_t       o2n_vtx_gnum[],
       assert(cur <= mesh->n_g_vertices);
 
       if (cur != prev) {
-
         n_am_vertices++;
         prev = cur;
         o2n_vtx_id[o_id] = n_am_vertices;
         new_vtx_gnum[n_am_vertices] = cur;
-
       }
       else
         o2n_vtx_id[o_id] = n_am_vertices;
@@ -1046,12 +978,10 @@ _update_vertices_after_merge(const fvm_gnum_t       o2n_vtx_gnum[],
       cur = j_vertices[j_id].gnum;
 
       if (cur != prev) {
-
         n_am_vertices++;
         prev = cur;
         new_vtx_gnum[n_am_vertices] = cur;
         join2mesh_vtx_id[j_id] = n_am_vertices;
-
       }
       else
         join2mesh_vtx_id[j_id] = n_am_vertices;
@@ -1073,16 +1003,16 @@ _update_vertices_after_merge(const fvm_gnum_t       o2n_vtx_gnum[],
              "old_n_vertices = %d - new_n_vertices = %d\n",
              n_bm_vertices, n_am_vertices);
   for (i = 0; i < n_bm_vertices; i++)
-    bft_printf("Old num : %7d (%9u) => New num : %7d (%9u)\n",
+    bft_printf("Old num : %7d (%9u) => New num : %7d (%9u) (%9u)\n",
                i+1, (n_ranks >1 ? mesh->global_vtx_num[i] : (fvm_gnum_t)i+1),
-               o2n_vtx_id[i]+1,  o2n_vtx_gnum[i]);
+               o2n_vtx_id[i]+1,  o2n_vtx_gnum[i], new_vtx_gnum[o2n_vtx_id[i]]);
   bft_printf_flush();
 #endif
 
   /* Update global vertex information */
 
   mesh->n_vertices = n_am_vertices;
-  mesh->n_g_vertices = mesh->n_vertices;
+  mesh->n_g_vertices =  new_vtx_gnum[n_am_vertices - 1];
 
   BFT_REALLOC(new_vtx_gnum, n_am_vertices, fvm_gnum_t);
   BFT_FREE(mesh->global_vtx_num);
@@ -1152,14 +1082,16 @@ _update_vertices_after_split(const cs_join_mesh_t  *join_mesh,
   fvm_gnum_t  *new_vtx_gnum = NULL, *tmp_vtx_gnum = NULL;
 
   const cs_int_t  n_bs_vertices = mesh->n_vertices; /* bs: before splitting */
-  const cs_int_t  j_n_vertices = join_mesh->n_vertices;
+  const cs_int_t  n_j_vertices = join_mesh->n_vertices;
   const cs_join_vertex_t  *j_vertices = join_mesh->vertices;
-  const cs_int_t  n_vertices = n_bs_vertices + j_n_vertices;
+  const cs_int_t  n_vertices = n_bs_vertices + n_j_vertices;
+
+  assert(mesh->global_vtx_num != NULL);
 
   /* Update initial vertices (local and global numbering) */
 
   BFT_MALLOC(o2n_vtx_id, n_bs_vertices, cs_int_t);
-  BFT_MALLOC(join2mesh_vtx_id, j_n_vertices, cs_int_t);
+  BFT_MALLOC(join2mesh_vtx_id, n_j_vertices, cs_int_t);
   BFT_MALLOC(tmp_vtx_gnum, n_vertices, fvm_gnum_t);
   BFT_MALLOC(new_vtx_gnum, n_vertices, fvm_gnum_t);
   BFT_MALLOC(order, n_vertices, fvm_lnum_t);
@@ -1167,13 +1099,15 @@ _update_vertices_after_split(const cs_join_mesh_t  *join_mesh,
   for (i = 0; i < n_bs_vertices; i++)
     tmp_vtx_gnum[i] = mesh->global_vtx_num[i];
 
-  for (i = 0, j = n_bs_vertices; i < j_n_vertices; i++, j++)
+  for (i = 0, j = n_bs_vertices; i < n_j_vertices; i++, j++)
     tmp_vtx_gnum[j] = j_vertices[i].gnum;
 
   fvm_order_local_allocated(NULL, tmp_vtx_gnum, order, n_vertices);
 
   /* Define o2n_vtx_id and join2mesh_vtx_id arrays */
 
+  assert(n_vertices > 0);
+
   if (order[0] < n_bs_vertices)
     prev = mesh->global_vtx_num[order[0]] + 1;
   else
@@ -1288,6 +1222,100 @@ _update_vertices_after_split(const cs_join_mesh_t  *join_mesh,
 }
 
 /*----------------------------------------------------------------------------
+ * Update border and interior face state
+ *
+ * parameters:
+ *  selection    <->  list of entities participating in the join operation
+ *  join_mesh    <--  pointer to a cs_join_mesh_t structure
+ *  mesh         <--  pointer of pointer to cs_mesh_t structure
+ *  j2m_vid      <--  relation between join mesh and after merge vertex
+ *---------------------------------------------------------------------------*/
+
+static void
+_update_face_state(cs_join_select_t        *selection,
+                   const cs_join_mesh_t    *join_mesh,
+                   const cs_mesh_t         *mesh,
+                   const cs_int_t           j2m_vid[])
+{
+  int  i, j, s, e;
+  cs_join_state_t  v_state, f_state;
+  cs_bool_t  have_new;
+
+  cs_join_state_t  *states = NULL;
+
+  BFT_MALLOC(states, mesh->n_vertices, cs_join_state_t);
+
+  /* Initialize */
+
+  for (i = 0; i < mesh->n_vertices; i++)
+    states[i] = CS_JOIN_STATE_UNDEF;
+
+  /* Update vertex state thanks to join_mesh */
+
+  for (i = 0; i < join_mesh->n_vertices; i++)
+    states[j2m_vid[i]] = join_mesh->vertices[i].state;
+
+  /* Border faces treatment */
+
+  for (i = 0; i < mesh->n_b_faces; i++) {
+
+    s = mesh->b_face_vtx_idx[i] - 1;
+    e = mesh->b_face_vtx_idx[i+1] - 1;
+    f_state = CS_JOIN_STATE_UNDEF;
+    have_new = false;
+
+    for (j = s; j < e; j++) {
+
+      v_state = states[mesh->b_face_vtx_lst[j] - 1];
+      f_state = CS_MAX(f_state, v_state);
+      if (v_state == CS_JOIN_STATE_NEW)
+        have_new = true;
+
+    }
+
+    if (f_state == CS_JOIN_STATE_ORIGIN && have_new == true)
+      f_state = CS_JOIN_STATE_MERGE;
+    else if (f_state == CS_JOIN_STATE_PERIO && have_new == true)
+      f_state = CS_JOIN_STATE_PERIO_MERGE;
+
+    selection->b_face_state[i] = f_state;
+
+  } /* End of loop on border faces */
+
+  /* Interior faces treatment */
+
+  for (i = 0; i < mesh->n_i_faces; i++) {
+
+    s = mesh->i_face_vtx_idx[i] - 1;
+    e = mesh->i_face_vtx_idx[i+1] - 1;
+    f_state = CS_JOIN_STATE_UNDEF;
+    have_new = false;
+
+    for (j = s; j < e; j++) {
+
+      v_state = states[mesh->i_face_vtx_lst[j] - 1];
+      f_state = CS_MAX(f_state, v_state);
+      if (v_state == CS_JOIN_STATE_NEW)
+        have_new = true;
+
+    }
+
+    if (f_state == CS_JOIN_STATE_ORIGIN && have_new == true)
+      f_state = CS_JOIN_STATE_MERGE;
+    else if (f_state == CS_JOIN_STATE_PERIO && have_new == true)
+      f_state = CS_JOIN_STATE_PERIO_MERGE;
+
+    selection->i_face_state[i] = f_state;
+
+  } /* End of loop on interior faces */
+
+  /* Free memory */
+
+  BFT_FREE(states);
+
+}
+
+/*----------------------------------------------------------------------------
  * Allocate and initialize the definition of a edge_builder_t structure.
  * Equivalent to build a local edge-based connectivity for the selected faces.
  *
@@ -1454,7 +1482,7 @@ _get_local_faces_connect(cs_int_t                 select_id,
                          cs_int_t                 am_tmp[])
 {
   cs_int_t  i, j, k, v_id, bm_shift;
-  fvm_gnum_t  new_gnum, v_gnum;
+  fvm_gnum_t  new_gnum;
 
   cs_int_t  fid = join_select->faces[select_id] - 1;
   fvm_gnum_t  fgnum = join_select->compact_face_gnum[select_id];
@@ -1467,7 +1495,6 @@ _get_local_faces_connect(cs_int_t                 select_id,
   cs_int_t  fst_match_id = -1;
 
   const cs_join_vertex_t  *vertices = join_mesh->vertices;
-  const int  n_ranks = cs_glob_n_ranks;
 
   assert(join_mesh->face_gnum[select_id] == fgnum);
 
@@ -1490,7 +1517,6 @@ _get_local_faces_connect(cs_int_t                 select_id,
   while (fst_match_id == -1 && bm_shift < n_bm_face_vertices) {
 
     v_id = bm_tmp[bm_shift];
-    v_gnum = (n_ranks > 1 ? mesh->global_vtx_num[v_id] : (fvm_gnum_t)v_id+1);
     new_gnum = o2n_vtx_gnum[v_id];
 
     for (k = 0; k < n_am_face_vertices; k++) {
@@ -2125,65 +2151,6 @@ _update_adj_face_connect(cs_int_t               n_adj_faces,
   *p_f2v_lst = new_f2v_lst;
 }
 
-/*----------------------------------------------------------------------------
- * Compute barycenter and face normal for the current face.
- *
- * parameters:
- *   n_face_vertices <-- number of vertices defining the face
- *   face_vtx_coord  <-- coordinates of each vertex of the face
- *                        (size: n_face_vertices+1)
- *   face_barycenter --> barycentre of the face
- *   face_normal     --> normal of the face (norm = face area)
- *----------------------------------------------------------------------------*/
-
-static void
-_get_face_quantity(cs_int_t         n_face_vertices,
-                   const cs_real_t  face_vtx_coord[],
-                   cs_real_t        face_barycenter[],
-                   cs_real_t        face_normal[])
-{
-  cs_int_t  i, coord;
-  cs_real_t  v1[3], v2[3], tri_normal[3];
-
-  cs_real_t  inv_n_face_vertices = 1/(double)n_face_vertices;
-
-  /* Initialization */
-
-  for (coord = 0; coord < 3; coord++) {
-    face_normal[coord] = 0.0;
-    face_barycenter[coord] = 0.0;
-  }
-
-  /* Compute face barycenter */
-
-  for (i = 0; i < n_face_vertices; i++)
-    for (coord = 0; coord < 3; coord++)
-      face_barycenter[coord] += face_vtx_coord[3*i+coord];
-
-  for (coord = 0; coord < 3; coord++)
-    face_barycenter[coord] *= inv_n_face_vertices;
-
-  /* Compute triangle normal and update face normal */
-
-  for (i = 0; i < n_face_vertices; i++) {
-
-    for (coord = 0; coord < 3; coord++) {
-      v1[coord] = face_vtx_coord[3*i     + coord] - face_barycenter[coord];
-      v2[coord] = face_vtx_coord[3*(i+1) + coord] - face_barycenter[coord];
-    }
-
-    _cross_product(v1, v2, tri_normal);
-
-    for (coord = 0; coord < 3; coord++) {
-      tri_normal[coord] *= 0.5;
-      face_normal[coord] += tri_normal[coord];
-    }
-
-  }
-
-  _normalize(face_normal);
-}
-
 #if defined(HAVE_MPI)
 
 /*----------------------------------------------------------------------------
@@ -2192,13 +2159,15 @@ _get_face_quantity(cs_int_t         n_face_vertices,
  * parameters:
  *   n2o_hist     <--  new -> old global face numbering
  *   join_select  <--  list all local entities implied in the joining op.
+ *   join_param   <--  set of user-defined parameter
  *   cell_gnum    <->  global cell number related to each old face
  *---------------------------------------------------------------------------*/
 
 static void
-_exchange_cell_gnum(const cs_join_gset_t    *n2o_hist,
-                    const cs_join_select_t  *join_select,
-                    fvm_gnum_t               cell_gnum[])
+_exchange_cell_gnum(const cs_join_gset_t     *n2o_hist,
+                    const cs_join_select_t   *join_select,
+                    cs_join_param_t           join_param,
+                    fvm_gnum_t                cell_gnum[])
 {
   int  i, j, rank, fid, shift;
   fvm_gnum_t  compact_fgnum;
@@ -2264,8 +2233,8 @@ _exchange_cell_gnum(const cs_join_gset_t    *n2o_hist,
                                                  n2o_hist->g_list[j],
                                                  reduce_index);
 
-      assert(reduce_rank != -1);
       assert(reduce_rank < reduce_size);
+      assert(reduce_rank != -1);
 
       rank = reduce_ids[reduce_rank];
       send_shift[rank+1] += 1;
@@ -2292,8 +2261,8 @@ _exchange_cell_gnum(const cs_join_gset_t    *n2o_hist,
                                                  n2o_hist->g_list[j],
                                                  reduce_index);
 
-      assert(reduce_rank != -1);
       assert(reduce_rank < reduce_size);
+      assert(reduce_rank != -1);
 
       rank = reduce_ids[reduce_rank];
       shift = send_shift[rank] + send_count[rank];
@@ -2343,21 +2312,50 @@ _exchange_cell_gnum(const cs_join_gset_t    *n2o_hist,
 
   /* Get the related global cell number for each received face */
 
-  for (rank = 0; rank < n_ranks; rank++) {
+  if (join_param.perio_num > 0) {
 
-    for (i = recv_shift[rank]; i < recv_shift[rank+1]; i++) {
+    for (rank = 0; rank < n_ranks; rank++) {
 
-      compact_fgnum = recv_gbuf[i];
-      fid = compact_fgnum - 1 - loc_rank_s;
+      for (i = recv_shift[rank]; i < recv_shift[rank+1]; i++) {
 
-      assert(loc_rank_s < compact_fgnum);
-      assert(compact_fgnum <= loc_rank_e);
+        compact_fgnum = recv_gbuf[i];
 
-      recv_gbuf[i] = join_select->cell_gnum[fid];
+        assert(loc_rank_s < compact_fgnum);
+        assert(compact_fgnum <= loc_rank_e);
 
-    }
+        /* Get the id in the original face selection */
 
-  } /* End of loop on ranks */
+        if (compact_fgnum % 2 == 0) /* Periodic face */
+          fid = (compact_fgnum - loc_rank_s)/2 - 1;
+        else /* Original face */
+          fid = (compact_fgnum - loc_rank_s)/2;
+
+        recv_gbuf[i] = join_select->cell_gnum[fid];
+
+      }
+
+    } /* End of loop on ranks */
+
+  }
+  else { /* Not a periodic case */
+
+    for (rank = 0; rank < n_ranks; rank++) {
+
+      for (i = recv_shift[rank]; i < recv_shift[rank+1]; i++) {
+
+        compact_fgnum = recv_gbuf[i];
+        fid = compact_fgnum - 1 - loc_rank_s;
+
+        assert(loc_rank_s < compact_fgnum);
+        assert(compact_fgnum <= loc_rank_e);
+
+        recv_gbuf[i] = join_select->cell_gnum[fid];
+
+      }
+
+    } /* End of loop on ranks */
+
+  } /* End if not a periodic case */
 
   /* Return values to send ranks */
 
@@ -2387,17 +2385,19 @@ _exchange_cell_gnum(const cs_join_gset_t    *n2o_hist,
  * Get the related global cell numbers connected to the old face numbers.
  *
  * parameters:
- *   join_select   <-- list of all implied entities in the joining op.
- *   n2o_face_hist <-- face history structure (new -> old)
- *   cell_gnum     --> pointer to the created array
+ *   join_select    <-- list of all implied entities in the joining op.
+ *   join_param     <-- set of user-defined parameter
+ *   n2o_face_hist  <-- face history structure (new -> old)
+ *   cell_gnum      --> pointer to the created array
  *---------------------------------------------------------------------------*/
 
 static void
 _get_linked_cell_gnum(const cs_join_select_t  *join_select,
+                      const cs_join_param_t    join_param,
                       const cs_join_gset_t    *n2o_face_hist,
                       fvm_gnum_t              *p_cell_gnum[])
 {
-  cs_int_t  i, j;
+  cs_int_t  i, j, fid;
   fvm_gnum_t  compact_fgnum;
 
   fvm_gnum_t  *cell_gnum = NULL;
@@ -2409,14 +2409,40 @@ _get_linked_cell_gnum(const cs_join_select_t  *join_select,
 
   if (n_ranks == 1) {
 
-    for (i = 0; i < n2o_face_hist->n_elts; i++) {
+    if (join_param.perio_num > 0) { /* Periodic case */
 
-      for (j = n2o_face_hist->index[i]; j < n2o_face_hist->index[i+1]; j++) {
-        compact_fgnum = n2o_face_hist->g_list[j];
-        cell_gnum[j] = join_select->cell_gnum[compact_fgnum - 1];
-      }
+      for (i = 0; i < n2o_face_hist->n_elts; i++) {
+
+        for (j = n2o_face_hist->index[i]; j < n2o_face_hist->index[i+1]; j++) {
+
+          compact_fgnum = n2o_face_hist->g_list[j];
+
+          if (compact_fgnum % 2 == 0) { /* Periodic face */
+            fid = compact_fgnum/2 - 1;
+            cell_gnum[j] = join_select->cell_gnum[fid];
+          }
+          else { /* Original face */
+            fid = compact_fgnum/2;
+            cell_gnum[j] = join_select->cell_gnum[fid];
+          }
 
-    } /* End of loop on n2o_face_hist elements */
+        }
+
+      } /* End of loop on n2o_face_hist elements */
+
+    }
+    else {
+
+      for (i = 0; i < n2o_face_hist->n_elts; i++) {
+
+        for (j = n2o_face_hist->index[i]; j < n2o_face_hist->index[i+1]; j++) {
+          compact_fgnum = n2o_face_hist->g_list[j];
+          cell_gnum[j] = join_select->cell_gnum[compact_fgnum - 1];
+        }
+
+      } /* End of loop on n2o_face_hist elements */
+
+    } /* Not a periodic case */
 
   }
 
@@ -2424,6 +2450,7 @@ _get_linked_cell_gnum(const cs_join_select_t  *join_select,
   if (n_ranks > 1)
     _exchange_cell_gnum(n2o_face_hist,
                         join_select,
+                        join_param,
                         cell_gnum);
 #endif
 
@@ -2434,13 +2461,500 @@ _get_linked_cell_gnum(const cs_join_select_t  *join_select,
 }
 
 /*----------------------------------------------------------------------------
- * Update mesh structure by adding new border faces after the face cutting
- * and deleting old one.
+ * Print information before calling bft_error()
  *
  * parameters:
- *   join_select      <-- list of all implied entities in the joining op.
- *   join_mesh        <-- pointer to the local cs_join_mesh_t structure
- *   join2mesh_vtx_id <-- relation between vertices in join_mesh/mesh
+ *   jfnum    <--  new sub join face to reorient
+ *   cgnum    <--  cgnum1 and cgnum2 related to this interior face
+ *   fnum     <--  related selected face num in original face
+ *   jmesh    <--  pointer to a cs_join_mesh_t structure
+ *---------------------------------------------------------------------------*/
+
+static void
+_print_error_info(cs_int_t                jfnum,
+                  const fvm_gnum_t        cgnum[],
+                  const cs_int_t          fnum[],
+                  const cs_join_mesh_t   *jmesh)
+{
+  int  i, vid;
+  int  jms = jmesh->face_vtx_idx[jfnum-1] - 1;
+  int  jme = jmesh->face_vtx_idx[jfnum] - 1;
+
+  bft_printf("\n   cgnum (%u, %u) - fnum: (%d, %d)\n",
+             cgnum[0], cgnum[1], fnum[0], fnum[1]);
+
+  bft_printf(_("  Join Face connectivity %d (%u): "),
+             jfnum, jmesh->face_gnum[jfnum-1]);
+  for (i = jms; i < jme; i++) {
+    vid = jmesh->face_vtx_lst[i] - 1;
+    bft_printf("%u ", jmesh->vertices[vid].gnum);
+  }
+  bft_printf("\n");
+  bft_printf_flush();
+
+  /* Define a specific name for the output */
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG) /* Dump mesh structure */
+  {
+    int  len;
+    FILE  *dbg_file = NULL;
+    char  *fullname = NULL;
+
+    const  int  rank_id = CS_MAX(cs_glob_rank_id, 0);
+
+    len = strlen("JoinDBG_ErrorOrient.dat") + 4 + 1;
+    BFT_MALLOC(fullname, len, char);
+    sprintf(fullname, "JoinDBG_ErrorOrient%04d.dat", rank_id);
+
+    dbg_file = fopen(fullname, "w");
+    cs_join_mesh_dump_file(dbg_file, jmesh);
+    fflush(dbg_file);
+    fclose(dbg_file);
+  }
+#endif
+
+  bft_error(__FILE__, __LINE__, 0,
+            _("  Cannot achieve to reorient the current joined face.\n"));
+
+}
+
+/*----------------------------------------------------------------------------
+ * Check if the orientation is the same between two faces thanks to its
+ * normal
+ *
+ * parameters:
+ *   omfnum  <--  old face number in mesh structure
+ *   jmfnum  <--  new face number in join mesh structure
+ *   mesh    <->  pointer to the original cs_mesh_t structure after the
+ *                merge step
+ *   jmesh   <--  pointer to a cs_join_mesh_t structure
+ *   dtmp    <->  work buffer of double
+ *   gtmp    <->  work buffer of gnum
+ *
+ * returns:
+ *  1 if in same orientation, else -1. Return 0 if there is a problem.
+ *---------------------------------------------------------------------------*/
+
+static int
+_get_geom_orient(cs_int_t                omfnum,
+                 cs_int_t                jmfnum,
+                 const cs_mesh_t        *mesh,
+                 const cs_join_mesh_t   *jmesh,
+                 double                  dtmp[])
+{
+  int  i, j, k, jvid, mvid;
+
+  int  ret = 0;
+  int  jmfid = jmfnum - 1, omfid = omfnum - 1;
+  int  jms = jmesh->face_vtx_idx[jmfid] - 1;
+  int  jme = jmesh->face_vtx_idx[jmfid+1] - 1;
+  int  ms = mesh->b_face_vtx_idx[omfid] - 1;
+  int  me = mesh->b_face_vtx_idx[omfid+1] - 1;
+  int  jsize = jme - jms, size = me - ms;
+  double  *jcoord = &(dtmp[0]);
+  double  *coord = &(dtmp[3*(jsize+1)]);
+  double  jnormal[3], normal[3];
+
+  /* Fill work buffers */
+
+  for (i = jms, j = 0; i < jme; i++, j++) {
+    jvid = jmesh->face_vtx_lst[i] - 1;
+    for (k = 0; k < 3; k++)
+      jcoord[3*j+k] = jmesh->vertices[jvid].coord[k];
+  }
+  jvid = jmesh->face_vtx_lst[jms] - 1;
+  for (k = 0; k < 3; k++)
+    jcoord[3*j+k] = jmesh->vertices[jvid].coord[k];
+
+  for (i = ms, j = 0; i < me; i++, j++) {
+    mvid = mesh->b_face_vtx_lst[i] - 1;
+    for (k = 0; k < 3; k++)
+      coord[3*j+k] = mesh->vtx_coord[3*mvid+k];
+  }
+  mvid = mesh->b_face_vtx_lst[ms] - 1;
+  for (k = 0; k < 3; k++)
+    coord[3*j+k] = mesh->vtx_coord[3*mvid+k];
+
+  _get_face_normal(jsize, jcoord, jnormal);
+  _get_face_normal(size, coord, normal);
+
+  if (_dot_product(jnormal, normal) < 0)
+    ret = -1;
+  else if (_dot_product(jnormal, normal) > 0)
+    ret = 1;
+
+  return ret;
+}
+
+/*----------------------------------------------------------------------------
+ * Check if the orientation is the same between two faces thanks to its
+ * topology
+ *
+ * parameters:
+ *   omfnum  <--  old face number in mesh structure
+ *   jmfnum  <--  new face number in join mesh structure
+ *   mesh    <->  pointer to the original cs_mesh_t structure after the
+ *                merge step
+ *   jmesh   <--  pointer to a cs_join_mesh_t structure
+ *   tmp     <->  work buffer
+ *
+ * returns:
+ *  1 if in same orientation, else -1. If no common edge was found, return 0
+ *---------------------------------------------------------------------------*/
+
+static int
+_get_topo_orient(cs_int_t                omfnum,
+                 cs_int_t                jmfnum,
+                 const cs_mesh_t        *mesh,
+                 const cs_join_mesh_t   *jmesh,
+                 fvm_gnum_t              gtmp[])
+{
+  int  i, j, k, jvid, mvid;
+  fvm_gnum_t  ref1, ref2;
+
+  int  ret = 0;
+  int  jmfid = jmfnum - 1, omfid = omfnum - 1;
+  int  jms = jmesh->face_vtx_idx[jmfid] - 1;
+  int  jme = jmesh->face_vtx_idx[jmfid+1] - 1;
+  int  ms = mesh->b_face_vtx_idx[omfid] - 1;
+  int  me = mesh->b_face_vtx_idx[omfid+1] - 1;
+  int  jsize = jme - jms, size = me - ms;
+  fvm_gnum_t  *jconnect = &(gtmp[0]);
+  fvm_gnum_t  *connect = &(gtmp[jsize+1]);
+
+  /* Fill work buffers
+     mesh->global_vtx_num is always allocated even if in serial run */
+
+  for (i = jms, k = 0; i < jme; i++, k++) {
+    jvid = jmesh->face_vtx_lst[i] - 1;
+    jconnect[k] = jmesh->vertices[jvid].gnum;
+  }
+  jvid = jmesh->face_vtx_lst[jms] - 1;
+  jconnect[k] = jmesh->vertices[jvid].gnum;
+
+  for (i = ms, k = 0; i < me; i++, k++) {
+    mvid = mesh->b_face_vtx_lst[i] - 1;
+    connect[k] = mesh->global_vtx_num[mvid];
+  }
+  mvid = mesh->b_face_vtx_lst[ms] - 1;
+  connect[k] = mesh->global_vtx_num[mvid];
+
+  /* Find a common edge between the two face connectivities */
+
+  for (i = 0; i < jsize && ret == 0; i++) {
+
+    ref1 = jconnect[i];
+    ref2 = jconnect[i+1];
+
+    for (j = 0; j < size; j++) {
+      if (ref2 == connect[j])
+        if (ref1 == connect[j+1])
+          ret = -1; /* Opposite scan order */
+      if (ref1 == connect[j])
+        if (ref2 == connect[j+1])
+          ret = 1; /* Same scan order */
+    }
+
+  }
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf("\n JoinFace num: %d - connect: [", jmfnum);
+  for (k = 0; k < jsize; k++)
+    bft_printf(" %u", jconnect[k]);
+  bft_printf(" %u]\n", jconnect[jsize]);
+  bft_printf(" OldMeshFace num: %d - connect: [", omfnum);
+  for (k = 0; k < size; k++)
+    bft_printf(" %u", connect[k]);
+  bft_printf(" %u]\n", connect[size]);
+  bft_printf("ret: %d\n", ret);
+  bft_printf_flush();
+#endif
+
+  return ret;
+}
+
+/*----------------------------------------------------------------------------
+ * Check if the orientation is the same between two faces. Topological algo.
+ *
+ * parameters:
+ *   jfnum    <--  new sub join face to reorient
+ *   cgnum    <--  cgnum1 and cgnum2 related to this interior face
+ *   fnum     <--  related selected face num in original face
+ *   mesh     <->  pointer to the original cs_mesh_t structure after the
+ *                 merge step
+ *   jmesh    <--  pointer to a cs_join_mesh_t structure
+ *   ltmp     <->  work buffer to store local connectivity
+ *   dtmp     <->  work buffer to compute face normal (only in geometric algo)
+ *   gtmp     <->  work buffer to store global numbering
+ *---------------------------------------------------------------------------*/
+
+static void
+_reorient(cs_int_t                jfnum,
+          fvm_gnum_t              cgnum[],
+          cs_int_t                fnum[],
+          const cs_mesh_t        *mesh,
+          const cs_join_mesh_t   *jmesh,
+          cs_int_t                ltmp[],
+          fvm_gnum_t              gtmp[],
+          double                  dtmp[])
+{
+  int  i, k, orient_tag;
+
+  int  jms = jmesh->face_vtx_idx[jfnum-1] - 1;
+  int  jme = jmesh->face_vtx_idx[jfnum] - 1;
+  int  n_face_vertices = jme - jms;
+
+  if (cs_glob_n_ranks == 1)
+    if (fnum[0] == 0 || fnum[1] == 0)
+      _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+  /* Get the right orientation. We assume that all original border faces
+     have a right orientation i.e. outward normal orientation */
+
+  if (cgnum[0] < cgnum[1]) { /* fnum[0] forces the orientation */
+
+    if (fnum[0] > 0) { /* fnum[0] belongs to local_rank */
+
+      orient_tag = _get_topo_orient(fnum[0], jfnum, mesh, jmesh, gtmp);
+
+      if (orient_tag == -1) { /* fnum[0] and jfnum don't share the same
+                                 orientation => Re-orient */
+
+        for (i = jms, k = 0; i < jme; i++, k++)
+          ltmp[k] = jmesh->face_vtx_lst[i];
+        for (i = jms + 1, k = 1; i < jme; i++, k++)
+          jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+      }
+      else if (orient_tag == 0) { /* Edge not found in fnum[0] */
+
+        if (fnum[1] < 1) { /* Switch to a geometrical test
+                              fnum[1] should own a common edge and orientation
+                              should be opposite to fnum[0].
+                              So we test face orientation and check this
+                              assumption. */
+
+          orient_tag = _get_geom_orient(fnum[0], jfnum, mesh, jmesh, dtmp);
+
+          if (orient_tag < 0) { /* Need to reorient */
+
+            for (i = jms, k = 0; i < jme; i++, k++)
+              ltmp[k] = jmesh->face_vtx_lst[i];
+            for (i = jms + 1, k = 1; i < jme; i++, k++)
+              jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+          }
+          else if (orient_tag == 0)
+            _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+        }
+        else { /* fnum[1] > 0 */
+
+          orient_tag = _get_topo_orient(fnum[1], jfnum, mesh, jmesh, gtmp);
+
+          if (orient_tag == 1) { /* fnum[1] and jfnum share the same
+                                    orientation => Re-orient */
+
+            for (i = jms, k = 0; i < jme; i++, k++)
+              ltmp[k] = jmesh->face_vtx_lst[i];
+            for (i = jms + 1, k = 1; i < jme; i++, k++)
+              jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+          }
+          else if (orient_tag == 0) { /* Edge not found in fnum[1] */
+
+            /* Switch to a geometrical test */
+
+            orient_tag = _get_geom_orient(fnum[1], jfnum, mesh, jmesh, dtmp);
+
+            if (orient_tag == 1) { /* fnum[1] and jfnum share the same
+                                      orientation => Re-orient */
+
+              for (i = jms, k = 0; i < jme; i++, k++)
+                ltmp[k] = jmesh->face_vtx_lst[i];
+              for (i = jms + 1, k = 1; i < jme; i++, k++)
+                jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+            }
+            else if (orient_tag == 0)
+              _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+          }
+
+        } /* fnum[1] */
+
+      } /* Edge not found in fnum[0] */
+
+    } /* fnum[0] > 0 */
+
+    else { /* fnum[0] < 1 */
+
+      if (fnum[1] > 0) {
+
+        orient_tag = _get_topo_orient(fnum[1], jfnum, mesh, jmesh, gtmp);
+
+        if (orient_tag == 1) { /* fnum[1] and jfnum share the same orientation
+                                  => Re-orient */
+
+          for (i = jms, k = 0; i < jme; i++, k++)
+            ltmp[k] = jmesh->face_vtx_lst[i];
+          for (i = jms + 1, k = 1; i < jme; i++, k++)
+            jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+        }
+        else if (orient_tag == 0) {
+
+          /* Switch to a geometrical test */
+
+          orient_tag = _get_geom_orient(fnum[1], jfnum, mesh, jmesh, dtmp);
+
+          if (orient_tag == 1) { /* fnum[1] and jfnum share the same
+                                    orientation => Re-orient */
+
+            for (i = jms, k = 0; i < jme; i++, k++)
+              ltmp[k] = jmesh->face_vtx_lst[i];
+            for (i = jms + 1, k = 1; i < jme; i++, k++)
+              jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+          }
+          else if (orient_tag == 0) /* Geom. and topo. tests fail */
+            _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+        }
+
+      } /* fnum[1] > 0 */
+
+      else  /* fnum[1] < 1 && fnum[0] < 1 */
+        _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+    } /* fnum[0] < 1 */
+
+  }
+  else { /* cgnum[0] > cgnum[1] => fnum[1] forces the orientation  */
+
+    if (fnum[1] > 0) { /* fnum[1] belongs to local_rank */
+
+      orient_tag = _get_topo_orient(fnum[1], jfnum, mesh, jmesh, gtmp);
+
+      if (orient_tag == -1) { /* fnum[1] and jfnum don't share the same
+                                 orientation => re-orient */
+
+        for (i = jms, k = 0; i < jme; i++, k++)
+          ltmp[k] = jmesh->face_vtx_lst[i];
+        for (i = jms + 1, k = 1; i < jme; i++, k++)
+          jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+      }
+      else if (orient_tag == 0) { /* Edge not found in fnum[1] */
+
+        if (fnum[0] < 1) { /* Switch to a geomtrical test
+                              fnum[1] should own a common edge and orientation
+                              should be opposite to fnum[0].
+                              So we test face orientation and check this
+                              assumption. */
+
+          orient_tag = _get_geom_orient(fnum[1], jfnum, mesh, jmesh, dtmp);
+
+          if (orient_tag < 0) { /* Need to reorient */
+
+            for (i = jms, k = 0; i < jme; i++, k++)
+              ltmp[k] = jmesh->face_vtx_lst[i];
+            for (i = jms + 1, k = 1; i < jme; i++, k++)
+              jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+          }
+          else if (orient_tag == 0)  /* Geom. and topo. tests fail */
+            _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+        }
+        else { /* fnum[0] > 0 */
+
+          orient_tag = _get_topo_orient(fnum[0], jfnum, mesh, jmesh, gtmp);
+
+          if (orient_tag == 1) { /* fnum[0] and jfnum share the same
+                                    orientation => re-orient */
+
+            for (i = jms, k = 0; i < jme; i++, k++)
+              ltmp[k] = jmesh->face_vtx_lst[i];
+            for (i = jms + 1, k = 1; i < jme; i++, k++)
+              jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+          }
+          else if (orient_tag == 0) { /* Edge not found in fnum[0] */
+
+            /* Switch to a geometrical test */
+
+            orient_tag = _get_geom_orient(fnum[0], jfnum, mesh, jmesh, dtmp);
+
+            if (orient_tag == 1) { /* Need to reorient */
+
+              for (i = jms, k = 0; i < jme; i++, k++)
+                ltmp[k] = jmesh->face_vtx_lst[i];
+              for (i = jms + 1, k = 1; i < jme; i++, k++)
+                jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+            }
+            else if (orient_tag == 0)  /* Geom. and topo. tests fail */
+              _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+          }
+
+        } /* fnum[0] > 0 */
+
+      } /* Edge not found in fnum[1] */
+
+    }
+    else { /* fnum[1] < 1 */
+
+      if (fnum[0] > 0) { /* fnum[0] belongs to local_rank */
+
+        orient_tag = _get_topo_orient(fnum[0], jfnum, mesh, jmesh, gtmp);
+
+        if (orient_tag == 1) { /* fnum[0] and jfnum share the same
+                                  orientation => re-orient */
+
+          for (i = jms, k = 0; i < jme; i++, k++)
+            ltmp[k] = jmesh->face_vtx_lst[i];
+          for (i = jms + 1, k = 1; i < jme; i++, k++)
+            jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+        }
+        else if (orient_tag == 0) { /* Edge not found in fnum[0] */
+
+          /* Switch to a geometrical test */
+
+          orient_tag = _get_geom_orient(fnum[0], jfnum, mesh, jmesh, dtmp);
+
+          if (orient_tag == 1) { /* Need to reorient */
+
+            for (i = jms, k = 0; i < jme; i++, k++)
+              ltmp[k] = jmesh->face_vtx_lst[i];
+            for (i = jms + 1, k = 1; i < jme; i++, k++)
+              jmesh->face_vtx_lst[i] = ltmp[n_face_vertices - k];
+
+          }
+          else if (orient_tag == 0)  /* Geom. and topo. tests fail */
+            _print_error_info(jfnum, cgnum, fnum, jmesh);
+
+        }
+
+      } /* fnum[0] > 0 */
+
+    } /* fnum[1] < 1 */
+
+  } /* cgnum[1] < cgnum[0] */
+
+}
+
+/*----------------------------------------------------------------------------
+ * Update mesh structure by adding new border faces after the face cutting
+ * and deleting old one.
+ *
+ * parameters:
+ *   join_select      <-- list of all implied entities in the joining op.
+ *   join_param       <-- set of user-defined parameter
+ *   jmesh            <-- pointer to the local cs_join_mesh_t structure
+ *   join2mesh_vtx_id <-- relation between vertices in join_mesh/mesh
  *   n_new_b_faces    <-- local number of border faces after the joining
  *   new_face_type    <-- type (border/interior) of new faces
  *   n2o_face_hist    <-- face history structure (new -> old)
@@ -2449,21 +2963,23 @@ _get_linked_cell_gnum(const cs_join_select_t  *join_select,
 
 static void
 _add_new_border_faces(const cs_join_select_t     *join_select,
-                      const cs_join_mesh_t       *join_mesh,
+                      const cs_join_param_t       join_param,
+                      const cs_join_mesh_t       *jmesh,
                       const cs_int_t              join2mesh_vtx_id[],
                       cs_int_t                    n_new_b_faces,
                       const cs_join_face_type_t   new_face_type[],
                       const cs_join_gset_t       *n2o_face_hist,
                       cs_mesh_t                  *mesh)
 {
-  cs_int_t  i, j, select_id, vid, fid, shift, n_face_vertices;
+  cs_int_t  i, j, k, select_id, vid, fid, shift;
+  cs_int_t  n_face_vertices, max_size, orient_tag;
   fvm_gnum_t  compact_old_fgnum;
 
   cs_int_t  n_ib_faces = mesh->n_b_faces, n_fb_faces = 0;
   fvm_gnum_t  n_g_ib_faces = mesh->n_g_b_faces;
-  cs_int_t  *new_f2v_idx = NULL, *new_f2v_lst = NULL;
+  cs_int_t  *new_f2v_idx = NULL, *new_f2v_lst = NULL, *ltmp = NULL;
   cs_int_t  *new_face_family = NULL, *new_face_cells = NULL;
-  fvm_gnum_t  *new_fgnum = NULL;
+  fvm_gnum_t  *new_fgnum = NULL, *gtmp = NULL;
 
   const int  n_ranks = cs_glob_n_ranks;
   const int  rank = CS_MAX(cs_glob_rank_id, 0);
@@ -2481,6 +2997,17 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
   if (n_ranks > 1)
     BFT_MALLOC(new_fgnum, n_fb_faces, fvm_gnum_t);
 
+  max_size = 0;
+  for (i = 0; i < n_ib_faces; i++)
+    max_size = CS_MAX(max_size,
+                      mesh->b_face_vtx_idx[i+1]-mesh->b_face_vtx_idx[i]);
+  for (i = 0; i < jmesh->n_faces; i++)
+    max_size = CS_MAX(max_size,
+                      jmesh->face_vtx_idx[i+1]-jmesh->face_vtx_idx[i]);
+
+  BFT_MALLOC(gtmp, 2*(max_size+1), fvm_gnum_t);
+  BFT_MALLOC(ltmp, max_size, cs_int_t);
+
   /* Delete faces included in join_selection. Add other initial faces.
       - face -> vertex index
       - face -> cells connectivity
@@ -2521,10 +3048,14 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
   /* Add faces resulting from the joining operation */
 
   if (n_new_b_faces > 0) {
-    for (i = 0; i < join_mesh->n_faces; i++) {
+    for (i = 0; i < jmesh->n_faces; i++) {
 
       if (new_face_type[i] == CS_JOIN_FACE_BORDER) {
 
+        int  jms = jmesh->face_vtx_idx[i] - 1;
+        int  jme = jmesh->face_vtx_idx[i+1] - 1;
+
+        n_face_vertices = jme - jms;
         shift = n2o_face_hist->index[i];
         compact_old_fgnum = n2o_face_hist->g_list[shift];
 
@@ -2532,23 +3063,56 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
         assert(rank_start <= compact_old_fgnum);
         assert(compact_old_fgnum < rank_end);
 
-        fid = join_select->faces[compact_old_fgnum - rank_start] - 1;
+        if (join_param.perio_num > 0) {
+          fid = (compact_old_fgnum - rank_start)/2;
+          fid = join_select->faces[fid] - 1;
+        }
+        else
+          fid = join_select->faces[compact_old_fgnum - rank_start] - 1;
 
         new_face_cells[n_fb_faces] = mesh->b_face_cells[fid];
         new_face_family[n_fb_faces] = mesh->b_face_family[fid];
 
         if (n_ranks > 1)
-          new_fgnum[n_fb_faces] = join_mesh->face_gnum[i] + n_g_ib_faces;
+          new_fgnum[n_fb_faces] = jmesh->face_gnum[i] + n_g_ib_faces;
+
+        /* Check orientation: fid forces the orientation */
+
+        orient_tag = _get_topo_orient(fid+1, i+1, mesh, jmesh, gtmp);
+
+        if (orient_tag == -1) { /* Different orientation => re-orient*/
+          for (j = jms, k = 0; j < jme; j++, k++)
+            ltmp[k] = jmesh->face_vtx_lst[j];
+          for (j = jms + 1, k = 1; j < jme; j++, k++)
+          jmesh->face_vtx_lst[j] = ltmp[n_face_vertices - k];
+        }
+        else if (orient_tag == 0) { /* No common edge found */
+
+          for (j = jms; j < jme; j++) {
+            vid = jmesh->face_vtx_lst[j] - 1;
+            bft_printf(" %d (%u)", vid+1, jmesh->vertices[vid].gnum);
+          }
+          bft_printf("\n");
+          bft_printf_flush();
+
+          bft_error(__FILE__, __LINE__, 0,
+                    _("  Cannot achieve to reorient the current joined"
+                      " face with face %d (selected face).\n"), fid+1);
+
+        }
 
         n_fb_faces++;
-        n_face_vertices =
-          join_mesh->face_vtx_idx[i+1] - join_mesh->face_vtx_idx[i];
         new_f2v_idx[n_fb_faces] = n_face_vertices;
 
       } /* If new border face */
 
       else if (new_face_type[i] == CS_JOIN_FACE_MULTIPLE_BORDER) {
 
+        int  jms = jmesh->face_vtx_idx[i] - 1;
+        int  jme = jmesh->face_vtx_idx[i+1] - 1;
+
+        n_face_vertices = jme - jms;
+
         for (j = n2o_face_hist->index[i]; j < n2o_face_hist->index[i+1]; j++) {
 
           compact_old_fgnum = n2o_face_hist->g_list[j];
@@ -2558,20 +3122,45 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
 
             /* Initial selected border face must be in the selection */
 
-            fid = join_select->faces[compact_old_fgnum - rank_start] - 1;
+            if (join_param.perio_num > 0) {
+              fid = (compact_old_fgnum - rank_start)/2;
+              fid = join_select->faces[fid] - 1;
+            }
+            else
+              fid = join_select->faces[compact_old_fgnum - rank_start] - 1;
+
             new_face_cells[n_fb_faces] = mesh->b_face_cells[fid];
             new_face_family[n_fb_faces] = mesh->b_face_family[fid];
 
+            /* Check orientation: fid forces the orientation */
+
+            orient_tag = _get_topo_orient(fid+1, i+1, mesh, jmesh, gtmp);
+
+            if (orient_tag < 0) { /* Different orientation => re-orient*/
+              for (j = jms, k = 0; j < jme; j++, k++)
+                ltmp[k] = jmesh->face_vtx_lst[j];
+              for (j = jms + 1, k = 1; j < jme; j++, k++)
+                jmesh->face_vtx_lst[j] = ltmp[n_face_vertices - k];
+            }
+            else if (orient_tag == 0) { /* No common edge found */
+
+              for (j = jms; j < jme; j++)
+                vid = jmesh->face_vtx_lst[j] - 1;
+
+              bft_error(__FILE__, __LINE__, 0,
+                        _("  Cannot achieve to reorient the current joined"
+                          " face with face %d (selected face).\n"), fid+1);
+
+            }
+
           }
 
         }
 
         if (n_ranks > 1)
-          new_fgnum[n_fb_faces] = join_mesh->face_gnum[i] + n_g_ib_faces;
+          new_fgnum[n_fb_faces] = jmesh->face_gnum[i] + n_g_ib_faces;
 
         n_fb_faces++;
-        n_face_vertices =
-          join_mesh->face_vtx_idx[i+1] - join_mesh->face_vtx_idx[i];
         new_f2v_idx[n_fb_faces] = n_face_vertices;
 
       }
@@ -2580,6 +3169,9 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
 
   } /* If n_new_b_faces > 0 */
 
+  BFT_FREE(gtmp);
+  BFT_FREE(ltmp);
+
   assert(mesh->n_b_faces == n_fb_faces);
 
   /* Build index */
@@ -2618,15 +3210,15 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
   }
 
   if (n_new_b_faces > 0) {
-    for (i = 0; i < join_mesh->n_faces; i++) {
+    for (i = 0; i < jmesh->n_faces; i++) {
       if (   new_face_type[i] == CS_JOIN_FACE_BORDER
           || new_face_type[i] == CS_JOIN_FACE_MULTIPLE_BORDER) {
 
         shift = new_f2v_idx[n_fb_faces] - 1;
 
-        for (j = join_mesh->face_vtx_idx[i]-1;
-             j < join_mesh->face_vtx_idx[i+1]-1; j++) {
-          vid = join_mesh->face_vtx_lst[j] - 1;
+        for (j = jmesh->face_vtx_idx[i]-1;
+             j < jmesh->face_vtx_idx[i+1]-1; j++) {
+          vid = jmesh->face_vtx_lst[j] - 1;
           new_f2v_lst[shift++] = join2mesh_vtx_id[vid] + 1;
         }
 
@@ -2675,10 +3267,12 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
 
 /*----------------------------------------------------------------------------
  * Update mesh structure by adding new interior faces after the face split.
+ * Orient new interior faces.
  *
  * parameters:
  *   join_select      <-- list of all implied entities in the joining op.
- *   join_mesh        <-- pointer to the local cs_join_mesh_t structure
+ *   join_param       <-- set of user-defined parameter
+ *   jmesh            <-- pointer to the local cs_join_mesh_t structure
  *   join2mesh_vtx_id <-- relation between vertices in join_mesh/mesh
  *   cell_gnum        <-- global cell num. related to each initial face
  *   n_new_i_faces    <-- local number of interior faces after the joining
@@ -2690,7 +3284,8 @@ _add_new_border_faces(const cs_join_select_t     *join_select,
 
 static void
 _add_new_interior_faces(const cs_join_select_t     *join_select,
-                        const cs_join_mesh_t       *join_mesh,
+                        const cs_join_param_t       join_param,
+                        cs_join_mesh_t             *jmesh,
                         const cs_int_t              join2mesh_vtx_id[],
                         const fvm_gnum_t            cell_gnum[],
                         cs_int_t                    n_new_i_faces,
@@ -2699,9 +3294,12 @@ _add_new_interior_faces(const cs_join_select_t     *join_select,
                         const cs_join_gset_t       *n2o_face_hist,
                         cs_mesh_t                  *mesh)
 {
-  cs_int_t  i, j, k, vid, shift, n_face_vertices, fid[2];
+  cs_int_t  i, j, k, vid, id, shift, fnum[2], max_size;
   fvm_gnum_t  compact_fgnum, cgnum[2];
 
+  fvm_gnum_t  *gtmp = NULL;
+  double  *dtmp = NULL;
+  cs_int_t  *ltmp = NULL;
   cs_int_t  n_fi_faces = 0, n_ii_faces = mesh->n_i_faces;
   cs_int_t  *new_f2v_idx = mesh->i_face_vtx_idx;
   cs_int_t  *new_f2v_lst = mesh->i_face_vtx_lst;
@@ -2712,8 +3310,10 @@ _add_new_interior_faces(const cs_join_select_t     *join_select,
 
   const int  n_ranks = cs_glob_n_ranks;
   const int  rank = CS_MAX(cs_glob_rank_id, 0);
-  const fvm_gnum_t  loc_rank_s = join_select->compact_rank_index[rank];
-  const fvm_gnum_t  loc_rank_e = join_select->compact_rank_index[rank+1];
+  const fvm_gnum_t  rank_start = join_select->compact_rank_index[rank] + 1;
+  const fvm_gnum_t  rank_end = join_select->compact_rank_index[rank+1] + 1;
+
+  assert(mesh->global_vtx_num != NULL); /* Even if in serial run */
 
   n_fi_faces = n_ii_faces + n_new_i_faces;
   mesh->n_i_faces = n_fi_faces;
@@ -2723,6 +3323,21 @@ _add_new_interior_faces(const cs_join_select_t     *join_select,
   BFT_REALLOC(new_face_cells, 2*n_fi_faces, cs_int_t);
   BFT_REALLOC(new_face_family, n_fi_faces, cs_int_t);
 
+  max_size = 0;
+  for (i = 0; i < jmesh->n_faces; i++)
+    if (new_face_type[i] == CS_JOIN_FACE_INTERIOR)
+      max_size = CS_MAX(max_size,
+                        jmesh->face_vtx_idx[i+1]-jmesh->face_vtx_idx[i]);
+  for (i = 0; i < join_select->n_faces; i++) {
+    id = join_select->faces[i] - 1;
+    max_size = CS_MAX(max_size,
+                      mesh->b_face_vtx_idx[id+1]-mesh->b_face_vtx_idx[id]);
+  }
+
+  BFT_MALLOC(dtmp, 6*(max_size+1), double);
+  BFT_MALLOC(gtmp, 2*(max_size+1), fvm_gnum_t);
+  BFT_MALLOC(ltmp, max_size, cs_int_t);
+
   /* Add faces resulting from the joining operation
      - face -> vertex index
      - face -> cells connectivity
@@ -2730,61 +3345,96 @@ _add_new_interior_faces(const cs_join_select_t     *join_select,
   */
 
   n_fi_faces = n_ii_faces;
-  for (i = 0; i < join_mesh->n_faces; i++) {
+  for (i = 0; i < jmesh->n_faces; i++) {
 
     if (new_face_type[i] == CS_JOIN_FACE_INTERIOR) {
 
+      int  jms = jmesh->face_vtx_idx[i] - 1;
+      int  jme = jmesh->face_vtx_idx[i+1] - 1;
+      int  n_face_vertices = jme - jms;
+
       for (j = n2o_face_hist->index[i], k = 0;
            j < n2o_face_hist->index[i+1]; j++, k++) {
 
         cgnum[k] = cell_gnum[j];
         compact_fgnum = n2o_face_hist->g_list[j];
 
-        if (loc_rank_s < compact_fgnum && compact_fgnum <= loc_rank_e)
-          fid[k] = join_select->faces[compact_fgnum - loc_rank_s - 1] - 1;
+        if (rank_start <= compact_fgnum && compact_fgnum < rank_end) {
+
+          if (join_param.perio_num > 0) {
+
+            id = (compact_fgnum - rank_start)/2;
+            if (compact_fgnum % 2 == 0) /* Periodic face */
+              fnum[k] = -join_select->faces[id];
+            else /* Original face */
+              fnum[k] = join_select->faces[id];
+
+          }
+          else /* Not a periodic operation */
+            fnum[k] = join_select->faces[compact_fgnum - rank_start];
+
+        }
         else
-          fid[k] = -1;
+          fnum[k] = 0;
 
       }
 
-      if (cgnum[0] < cgnum[1]) { /* Keep the same order */
+      if (cgnum[0] < cgnum[1]) { /* Keep the same order and fnum[0]
+                                    forces the orientation */
 
-        if (fid[0] > -1)
-          new_face_cells[2*n_fi_faces] = mesh->b_face_cells[fid[0]];
+        if (fnum[0] > 0)
+          new_face_cells[2*n_fi_faces] = mesh->b_face_cells[fnum[0]-1];
         else
-          new_face_cells[2*n_fi_faces] = 0; /* Cell is on a distant rank */
+          new_face_cells[2*n_fi_faces] = 0; /* Cell is on a distant rank
+                                               or periodic */
 
-        if (fid[1] > -1)
-          new_face_cells[2*n_fi_faces+1] = mesh->b_face_cells[fid[1]];
+        if (fnum[1] > 0)
+          new_face_cells[2*n_fi_faces+1] = mesh->b_face_cells[fnum[1]-1];
         else
-          new_face_cells[2*n_fi_faces+1] = 0; /* Cell is on a distant rank */
+          new_face_cells[2*n_fi_faces+1] = 0; /* Cell is on a distant rank
+                                                 or periodic */
 
       }
-      else {
+      else { /* cgnum[1] < cgnum[0] and fnum[1] forces the orientation  */
 
-        if (fid[0] > -1)
-          new_face_cells[2*n_fi_faces+1] = mesh->b_face_cells[fid[0]];
+        if (fnum[0] > 0)
+          new_face_cells[2*n_fi_faces+1] = mesh->b_face_cells[fnum[0]-1];
         else
-          new_face_cells[2*n_fi_faces+1] = 0; /* Cell is on a distant rank */
+          new_face_cells[2*n_fi_faces+1] = 0; /* Cell is on a distant rank
+                                                 or periodic */
 
-        if (fid[1] > -1)
-          new_face_cells[2*n_fi_faces] = mesh->b_face_cells[fid[1]];
+        if (fnum[1] > 0)
+          new_face_cells[2*n_fi_faces] = mesh->b_face_cells[fnum[1]-1];
         else
-          new_face_cells[2*n_fi_faces] = 0; /* Cell is on a distant rank */
+          new_face_cells[2*n_fi_faces] = 0; /* Cell is on a distant rank
+                                               or periodic */
 
       }
 
-      new_face_family[n_fi_faces] = default_family; /* Default value.
-                                                       TODO: Define real family
-                                                    */
+      /* Re-orient face in order to be consistent with the new i_face_cells */
 
+      if (fnum[0] > 0 || fnum[1] > 0)
+        _reorient(i+1, cgnum, fnum, mesh, jmesh, ltmp, gtmp, dtmp);
+      else
+        if (join_param.perio_num == 0 || cs_glob_n_ranks == 1)
+          bft_error(__FILE__, __LINE__, 0,
+                    _(" Incoherency found before interior face orientation"
+                      " checking.\n"
+                      " Join face %d (%u) and related faces [%d, %d]\n"),
+                    i+1, jmesh->face_gnum[i], fnum[0], fnum[1]);
+
+      /* Default value. TODO: Define real family */
+      new_face_family[n_fi_faces] = default_family;
       n_fi_faces++;
-      n_face_vertices = join_mesh->face_vtx_idx[i+1]-join_mesh->face_vtx_idx[i];
       new_f2v_idx[n_fi_faces] = n_face_vertices;
 
-    }
+    } /* New interior face */
+
+  } /* End of loop on jmesh faces */
 
-  } /* End of loop on join_mesh faces */
+  BFT_FREE(dtmp);
+  BFT_FREE(gtmp);
+  BFT_FREE(ltmp);
 
   assert(mesh->n_i_faces == n_fi_faces);
 
@@ -2798,14 +3448,14 @@ _add_new_interior_faces(const cs_join_select_t     *join_select,
   /* Define the face -> vertex connectivity list */
 
   n_fi_faces = n_ii_faces;
-  for (i = 0; i < join_mesh->n_faces; i++) {
+  for (i = 0; i < jmesh->n_faces; i++) {
     if (new_face_type[i] == CS_JOIN_FACE_INTERIOR) {
 
       shift = new_f2v_idx[n_fi_faces]-1;
 
-      for (j = join_mesh->face_vtx_idx[i]-1;
-           j < join_mesh->face_vtx_idx[i+1]-1; j++) {
-        vid = join_mesh->face_vtx_lst[j]-1;
+      for (j = jmesh->face_vtx_idx[i]-1;
+           j < jmesh->face_vtx_idx[i+1]-1; j++) {
+        vid = jmesh->face_vtx_lst[j]-1;
         new_f2v_lst[shift++] = join2mesh_vtx_id[vid] + 1;
       }
       n_fi_faces++;
@@ -2821,9 +3471,9 @@ _add_new_interior_faces(const cs_join_select_t     *join_select,
     BFT_REALLOC(new_fgnum, mesh->n_i_faces, fvm_gnum_t);
 
     n_fi_faces = n_ii_faces;
-    for (i = 0; i < join_mesh->n_faces; i++)
+    for (i = 0; i < jmesh->n_faces; i++)
       if (new_face_type[i] == CS_JOIN_FACE_INTERIOR)
-        new_fgnum[n_fi_faces++] = join_mesh->face_gnum[i] + n_g_ii_faces;
+        new_fgnum[n_fi_faces++] = jmesh->face_gnum[i] + n_g_ii_faces;
 
     new_io_num = fvm_io_num_create(NULL, new_fgnum, n_fi_faces, 0);
     new_io_gnum = fvm_io_num_get_global_num(new_io_num);
@@ -2920,205 +3570,123 @@ _get_default_family(cs_mesh_t  *mesh)
 }
 
 /*----------------------------------------------------------------------------
- * Re-orientation of joined faces. Check and correct if needed.
+ * Delete unused vertices
  *
  * parameters:
- *   mesh            <-- pointer to cs_mesh_t structure
- *   n_old_i_faces   <-- initial number of interior faces
- *   n_old_b_faces   <-- initial number of border faces
- *   n_select_cells  <-- number of cells in the selection
- *   cell_selection  <-- selection array (size: mesh->n_cells)
- *   select_cell_cen --> cell center for the selected cells
+ *   param   <-- set of user-defined parameter
+ *   mesh    <-> cs_mesh_t structure to clean
  *---------------------------------------------------------------------------*/
 
 static void
-_reorient_faces(cs_mesh_t       *mesh,
-                cs_int_t         n_old_i_faces,
-                cs_int_t         n_old_b_faces,
-                cs_int_t         n_select_cells,
-                const cs_int_t   cell_selection[],
-                cs_real_t        select_cell_cen[])
+_clean_vertices(const cs_join_param_t   param,
+                cs_mesh_t              *mesh)
 {
-  cs_int_t  i, j, k, shift, s, e, vid, cid1, cid2, n_face_vertices;
-  cs_real_t  dot_prod;
-
-  cs_int_t  max_connect = 0;
-  cs_int_t  *face_connect = NULL;
-  cs_real_t  face_barycenter[3], face_normal[3], vect[3];
-  cs_real_t  *face_vtx_coord = NULL;
-
-  /* Remark:
-     n_select_cells == join_select->n_faces (see _get_select_cell_cen() ) */
-
-  /* Compute max face -> vertex connect. */
-
-  for (i = n_old_b_faces - n_select_cells; i < mesh->n_b_faces; i++)
-    max_connect = CS_MAX(max_connect,
-                         mesh->b_face_vtx_idx[i+1] - mesh->b_face_vtx_idx[i]);
-
-  for (i = n_old_i_faces; i < mesh->n_i_faces; i++)
-    max_connect = CS_MAX(max_connect,
-                         mesh->i_face_vtx_idx[i+1] - mesh->i_face_vtx_idx[i]);
-
-  BFT_MALLOC(face_vtx_coord, 3*(max_connect+1), cs_real_t);
-  BFT_MALLOC(face_connect, max_connect, cs_int_t);
-
-  /* Border faces */
-
-  for (i = n_old_b_faces - n_select_cells; i < mesh->n_b_faces; i++) {
-
-    /* Define face_vtx_coord */
-
-    s = mesh->b_face_vtx_idx[i] - 1;
-    e = mesh->b_face_vtx_idx[i+1] - 1;
-    n_face_vertices = e - s;
-    shift = 0;
-
-    for (j = s; j < e; j++) {
-
-      vid = mesh->b_face_vtx_lst[j] - 1;
-      face_connect[shift] = vid + 1;
-      for (k = 0; k < 3; k++)
-        face_vtx_coord[3*shift+k] = mesh->vtx_coord[3*vid+k];
-      shift++;
-
-    }
-
-    vid = mesh->b_face_vtx_lst[s] - 1;
-    for (k = 0; k < 3; k++)
-      face_vtx_coord[3*shift+k] = mesh->vtx_coord[3*vid+k];
-
-    /* Compute face barycenter and face normal */
+  int  i, j, k, vid;
 
-    _get_face_quantity(n_face_vertices,
-                       face_vtx_coord,
-                       face_barycenter,
-                       face_normal);  /* unitary */
+  cs_int_t  n_i_vertices = mesh->n_vertices, n_f_vertices = 0;
+  cs_int_t  *tag = NULL;
 
-    /*  Cb: cell barycenter
-        Fb: face barycenter
-        Nf: face normal
-                            --->   ->
-        Good orientation if CbFb . Nf > 0
-        Else if reorientation is required.
-    */
+  const int  n_ranks = cs_glob_n_ranks;
 
-    cid1 = mesh->b_face_cells[i] - 1;
-    assert(cid1 > -1);
-    cid1 = cell_selection[cid1];
-    assert(cid1 > -1);
+  assert(mesh != NULL);
 
-    for (k = 0; k < 3; k++)
-      vect[k] = face_barycenter[k] - select_cell_cen[3*cid1+k];
+  /* Tag vertices really used in the mesh definition */
 
-    _normalize(vect);
-    dot_prod = _dot_product(vect, face_normal);
+  BFT_MALLOC(tag, n_i_vertices, cs_int_t);
 
-    if (dot_prod < 0.0)
-      for (j = s, k = n_face_vertices-1; j < e; j++, k--)
-        mesh->b_face_vtx_lst[j] = face_connect[k];
+  for (i = 0; i < n_i_vertices; i++)
+    tag[i] = 0;
 
-  } /* End of loop on border faces */
+  for (i = 0; i < mesh->n_i_faces; i++)
+    for (j = mesh->i_face_vtx_idx[i]-1; j < mesh->i_face_vtx_idx[i+1]-1; j++)
+      tag[mesh->i_face_vtx_lst[j] - 1] = 1;
 
-  /* Interior faces */
+  for (i = 0; i < mesh->n_b_faces; i++)
+    for (j = mesh->b_face_vtx_idx[i]-1; j < mesh->b_face_vtx_idx[i+1]-1; j++)
+      tag[mesh->b_face_vtx_lst[j] - 1] = 1;
 
-  for (i = n_old_i_faces; i < mesh->n_i_faces; i++) {
+  for (i = 0; i < n_i_vertices; i++)
+    if (tag[i] > 0)
+      n_f_vertices++;
 
-    /* Define face_vtx_coord */
+  if (param.verbosity > 2)
+    bft_printf(_("  Delete %d local vertices not used in mesh definition.\n"),
+               n_i_vertices - n_f_vertices);
 
-    s = mesh->i_face_vtx_idx[i] - 1;
-    e = mesh->i_face_vtx_idx[i+1] - 1;
-    n_face_vertices = e - s;
-    shift = 0;
+  mesh->n_vertices = n_f_vertices;
+  mesh->n_g_vertices = n_f_vertices;
 
-    for (j = s; j < e; j++) {
+  /* Update global vertex information */
 
-      vid = mesh->i_face_vtx_lst[j] - 1;
-      face_connect[shift] = vid + 1;
-      for (k = 0; k < 3; k++)
-        face_vtx_coord[3*shift+k] = mesh->vtx_coord[3*vid+k];
-      shift++;
+  if (n_ranks == 1) /* not more useful for sequential computations */
+    BFT_FREE(mesh->global_vtx_num);
 
-    }
+  if (n_ranks > 1) {
 
-    vid = mesh->i_face_vtx_lst[s] - 1;
-    for (k = 0; k < 3; k++)
-      face_vtx_coord[3*shift+k] = mesh->vtx_coord[3*vid+k];
+    fvm_io_num_t  *vtx_io_num = NULL;
+    const fvm_gnum_t  *io_gnum = NULL;
 
-    /* Compute face barycenter and face normal */
+    /* Define a new compact global vertex numbering */
 
-    _get_face_quantity(n_face_vertices,
-                       face_vtx_coord,
-                       face_barycenter,
-                       face_normal);
+    n_f_vertices = 0;
+    for (i = 0; i < n_i_vertices; i++)
+      if (tag[i] > 0)
+        mesh->global_vtx_num[n_f_vertices++] = mesh->global_vtx_num[i];
 
-    /*  Cb1: cell barycenter for cell 1
-        Cb2: cell barycenter for cell 2
-        Fb : face barycenter
-        Nf : face normal
+    BFT_REALLOC(mesh->global_vtx_num, n_f_vertices, fvm_gnum_t);
 
-        if only Cb1 is available:
-                              ---->   ->
-          Good orientation if Cb1Fb . Nf > 0
+    vtx_io_num = fvm_io_num_create(NULL,
+                                   mesh->global_vtx_num,
+                                   mesh->n_vertices,
+                                   0); /* Not shared */
 
-        else:
-                              ----->   ->
-          Good orientation if Cb1Cb2 . Nf > 0
-    */
+    io_gnum = fvm_io_num_get_global_num(vtx_io_num);
+    mesh->n_g_vertices = fvm_io_num_get_global_count(vtx_io_num);
 
-    /* If we are on a parallel frontier: i_face_cell[] = 0 */
+    for (i = 0; i < mesh->n_vertices; i++)
+      mesh->global_vtx_num[i] = io_gnum[i];
 
-    cid1 = mesh->i_face_cells[2*i] - 1;
-    cid2 = mesh->i_face_cells[2*i+1] - 1;
+    fvm_io_num_destroy(vtx_io_num);
 
-    if (cid1 > -1)
-      cid1 = cell_selection[cid1];
-    if (cid2 > -1)
-      cid2 = cell_selection[cid2];
+  }
 
-    if (cid2 < 0) { /* Parallel frontier. cid2 not available */
+  /* Compact vertex coordinates */
 
-      assert(cs_glob_n_ranks > 1);
+  n_f_vertices = 0;
+  for (i = 0; i < n_i_vertices; i++) {
+    if (tag[i] > 0) {
 
+      tag[i] = n_f_vertices + 1;
       for (k = 0; k < 3; k++)
-        vect[k] = face_barycenter[k] - select_cell_cen[3*cid1+k];
-
-      _normalize(vect);
-      dot_prod = _dot_product(vect, face_normal);
+        mesh->vtx_coord[3*n_f_vertices+k] = mesh->vtx_coord[3*i+k];
+      n_f_vertices++;
 
     }
-    else if (cid1 < 0) {
-
-      assert(cs_glob_n_ranks > 1);
+  }
 
-      for (k = 0; k < 3; k++)
-        vect[k] = select_cell_cen[3*cid2+k] - face_barycenter[k];
+  BFT_REALLOC(mesh->vtx_coord, 3*mesh->n_vertices, fvm_coord_t);
 
-      _normalize(vect);
-      dot_prod = _dot_product(vect, face_normal);
+  /* Update interior face connectivity */
 
+  for (i = 0; i < mesh->n_i_faces; i++) {
+    for (j = mesh->i_face_vtx_idx[i]-1;
+         j < mesh->i_face_vtx_idx[i+1]-1; j++) {
+      vid = mesh->i_face_vtx_lst[j] - 1;
+      mesh->i_face_vtx_lst[j] = tag[vid];
     }
-    else {
-
-      for (k = 0; k < 3; k++)
-        vect[k] = select_cell_cen[3*cid2+k] - select_cell_cen[3*cid1+k];
-
-      _normalize(vect);
-      dot_prod = _dot_product(vect, face_normal);
+  }
 
+  /* Update border face connectivity */
 
+  for (i = 0; i < mesh->n_b_faces; i++) {
+    for (j = mesh->b_face_vtx_idx[i]-1;
+         j < mesh->b_face_vtx_idx[i+1]-1; j++) {
+      vid = mesh->b_face_vtx_lst[j] - 1;
+      mesh->b_face_vtx_lst[j] = tag[vid];
     }
+  }
 
-    if (dot_prod < 0.0) /* Re-orient */
-      for (j = s, k = n_face_vertices-1; j < e; j++, k--)
-        mesh->i_face_vtx_lst[j] = face_connect[k];
-
-  } /* End of loop on interior faces */
-
-  /* Free memory */
-
-  BFT_FREE(face_vtx_coord);
-  BFT_FREE(face_connect);
+  BFT_FREE(tag);
 
 }
 
@@ -3229,53 +3797,21 @@ _delete_edges(cs_int_t        s,
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_update_mesh_after_merge(cs_join_param_t          join_param,
-                                const cs_join_select_t  *join_select,
-                                fvm_gnum_t               o2n_vtx_gnum[],
-                                cs_join_mesh_t          *join_mesh,
-                                cs_mesh_t               *mesh)
+cs_join_update_mesh_after_merge(cs_join_param_t        join_param,
+                                cs_join_select_t      *join_select,
+                                fvm_gnum_t             o2n_vtx_gnum[],
+                                cs_join_mesh_t        *join_mesh,
+                                cs_mesh_t             *mesh)
 {
-  cs_int_t  i, j, shift, select_id, adj_id, old_id, new_num;
+  cs_int_t  i, j, select_id, adj_id, old_id, new_num;
 
   cs_int_t  *o2n_vtx_id = NULL, *join2mesh_vtx_id = NULL;
   edge_builder_t  *edge_builder = NULL;
 
-  const cs_int_t  n_bm_vertices = mesh->n_vertices; /* bf: before merge */
-  const cs_int_t  n_ranks = cs_glob_n_ranks;
+  const cs_int_t  n_bm_vertices = mesh->n_vertices; /* bm: before merge */
 
   edge_builder = _init_edge_builder(join_select, mesh);
 
-  /* Build an array keeping relation between old/new global vertex num. */
-
-  if (n_ranks == 1) {
-
-    fvm_gnum_t  *loc_vtx_gnum = NULL;
-
-    BFT_MALLOC(loc_vtx_gnum, n_bm_vertices, fvm_gnum_t);
-
-    /* Initialize array */
-
-    for (i = 0; i < n_bm_vertices; i++)
-      loc_vtx_gnum[i] = i+1;
-
-    /* Update value for selected vertices */
-
-    for (i = 0, shift = 0;
-         i < n_bm_vertices && shift < join_select->n_vertices; i++) {
-      if (i + 1 == join_select->vertices[shift])
-        loc_vtx_gnum[i] = o2n_vtx_gnum[shift++];
-    }
-
-    BFT_FREE(o2n_vtx_gnum);
-    o2n_vtx_gnum = loc_vtx_gnum;
-
-  } /* End if serial mode */
-
-#if defined(HAVE_MPI)
-  if (n_ranks > 1)
-    _get_local_o2n_vtx_gnum(mesh, &o2n_vtx_gnum);
-#endif
-
   /* Update mesh structure. Define new vertices */
 
   _update_vertices_after_merge
@@ -3459,6 +3995,10 @@ cs_join_update_mesh_after_merge(cs_join_param_t          join_param,
 
   }
 
+  /* Update face state */
+
+  _update_face_state(join_select, join_mesh, mesh, join2mesh_vtx_id);
+
   /* Post if required */
 
   if (join_param.verbosity > 2)
@@ -3476,81 +4016,33 @@ cs_join_update_mesh_after_merge(cs_join_param_t          join_param,
  * parameters:
  *   join_param      <-- set of parameters for the joining operation
  *   join_select     <-- list of all implied entities in the joining op.
- *   o2n_face_hist   <-- relation between faces before/after the joining
- *   join_mesh       <-- pointer to the local cs_join_mesh_t structure
+ *   n2o_face_hist   <-- relation between faces before/after the joining
+ *   join_mesh       <-> pointer to the local cs_join_mesh_t structure
  *   mesh            <-> pointer of pointer to cs_mesh_t structure
  *---------------------------------------------------------------------------*/
 
 void
 cs_join_update_mesh_after_split(cs_join_param_t          join_param,
                                 const cs_join_select_t  *join_select,
-                                const cs_join_gset_t    *o2n_face_hist,
-                                const cs_join_mesh_t    *join_mesh,
+                                const cs_join_gset_t    *n2o_face_hist,
+                                cs_join_mesh_t          *join_mesh,
                                 cs_mesh_t               *mesh)
 {
   int  i, j, n_matches, default_family;
 
-  fvm_gnum_t  n_g_new_b_faces = 0;
-  cs_int_t  n_new_i_faces = 0, n_new_b_faces = 0;
-  cs_int_t  n_old_i_faces = mesh->n_i_faces;
-  cs_int_t  n_old_b_faces = mesh->n_b_faces;
+  fvm_gnum_t  n_g_new_b_faces = 0, n_g_multiple_bfaces = 0;
+  cs_int_t  n_new_i_faces = 0, n_new_b_faces = 0, n_undef_faces = 0;
+  cs_int_t  n_multiple_bfaces = 0;
+  cs_int_t  n_old_i_faces = mesh->n_i_faces, n_old_b_faces = mesh->n_b_faces;
   cs_int_t  *join2mesh_vtx_id = NULL;
   fvm_gnum_t  *cell_gnum = NULL;
   cs_join_face_type_t  *new_face_type = NULL;
-  cs_join_gset_t  *n2o_face_hist = NULL;
-  cs_int_t  n_select_cells = join_select->n_faces; /* because border faces */
-  cs_int_t  *cell_selection = join_select->cell_filter;
-  cs_real_t  *select_cell_cen = join_select->cell_cen;
 
   const int  n_ranks = cs_glob_n_ranks;
 
   assert(mesh != NULL);
   assert(join_mesh != NULL);
 
-  /* Invert face historic */
-
-  n2o_face_hist = cs_join_gset_invert(o2n_face_hist);
-
-#if defined(HAVE_MPI)
-  if (n_ranks > 1) {
-
-    cs_join_gset_t  *n2o_sync_block = NULL;
-    MPI_Comm  mpi_comm = cs_glob_mpi_comm;
-
-    n2o_sync_block = cs_join_gset_sync_by_block(join_mesh->n_g_faces,
-                                                n2o_face_hist,
-                                                mpi_comm);
-
-    cs_join_gset_update_from_block(join_mesh->n_g_faces,
-                                   n2o_sync_block,
-                                   n2o_face_hist,
-                                   mpi_comm);
-
-    cs_join_gset_destroy(&n2o_sync_block);
-
-  }
-#endif
-
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-  {
-    int  len;
-    FILE  *dbg_file = NULL;
-    char  *filename = NULL;
-
-    len = strlen("JoinDBG_n2oFaceHist.dat")+1+2+4;
-    BFT_MALLOC(filename, len, char);
-    sprintf(filename, "Join%02dDBG_n2oFaceHist%04d.dat",
-            join_param.num, CS_MAX(cs_glob_rank_id, 0));
-    dbg_file = fopen(filename, "w");
-
-    cs_join_gset_dump(dbg_file, n2o_face_hist);
-
-    fflush(dbg_file);
-    BFT_FREE(filename);
-    fclose(dbg_file);
-  }
-#endif
-
   /* Get new subfaces evolution */
 
   assert(n2o_face_hist->n_elts == join_mesh->n_faces);
@@ -3570,7 +4062,7 @@ cs_join_update_mesh_after_split(cs_join_param_t          join_param,
       n_new_i_faces += 1;
       new_face_type[i] = CS_JOIN_FACE_INTERIOR;
     }
-    else {
+    else if (n_matches > 2) {
 
       if (join_param.verbosity > 1) {
         bft_printf(_("  Warning: Face %d (%u) has more than two ancestors.\n"
@@ -3586,34 +4078,91 @@ cs_join_update_mesh_after_split(cs_join_param_t          join_param,
       new_face_type[i] = CS_JOIN_FACE_MULTIPLE_BORDER;
 
     }
+    else {
+
+      n_undef_faces += 1;
+      new_face_type[i] = CS_JOIN_FACE_UNDEFINED;
+      n_multiple_bfaces += 1;
+
+      bft_printf(_("  Warning: Face %d (%u) has no ancestor.\n"),
+                 i+1, join_mesh->face_gnum[i]);
+      for (j = n2o_face_hist->index[i]; j < n2o_face_hist->index[i+1]; j++)
+        bft_printf(" %u", n2o_face_hist->g_list[j]);
+      bft_printf("\n");
+
+    }
 
   } /* End of loop on faces */
 
-  if (join_param.verbosity > 0)
+  if (join_param.verbosity > 1)
     bft_printf(_("\n  Local configuration after the joining operation:\n"
                  "    Number of interior faces to add: %9d\n"
                  "    Number of border faces to add  : %9d\n"),
                n_new_i_faces, n_new_b_faces);
 
-  if (n_ranks == 1)
+  if (n_ranks == 1) {
     n_g_new_b_faces = n_new_b_faces;
+    n_g_multiple_bfaces = n_multiple_bfaces;
+  }
 
 #if defined(HAVE_MPI)
   if (n_ranks > 1) {
 
+    fvm_gnum_t _loc[3], _glob[3];
     MPI_Comm  mpi_comm = cs_glob_mpi_comm;
 
-    MPI_Allreduce(&n_new_b_faces, &n_g_new_b_faces, 1, FVM_MPI_GNUM,
-                  MPI_SUM, mpi_comm);
+    _loc[0] = n_new_b_faces;
+    _loc[1] = n_undef_faces;
+    _loc[2] = n_multiple_bfaces;
 
-    if (cs_glob_rank_id <= 0)
-      bft_printf(_("\n  Global configuration after the joining operation:\n"
-                   "     Global number of border faces to add : %10u\n"),
-                 n_g_new_b_faces);
+    MPI_Allreduce(_loc, _glob, 3, FVM_MPI_GNUM, MPI_SUM, mpi_comm);
+
+    n_g_new_b_faces = _glob[0];
+    n_g_multiple_bfaces = _glob[2];
+
+    if (_glob[1] > 0)
+      bft_error(__FILE__, __LINE__, 0,
+                _(" There are %u undefined faces with no ancestor.\n"
+                  " Cannot continue the joining algorithm.\n"), _glob[1]);
 
   }
 #endif
 
+  /* Print information about new mesh configuration */
+
+  bft_printf(_("\n  Global configuration after the joining operation:\n"
+               "     Global number of border faces to add: %10llu\n"),
+             (unsigned long long)n_g_new_b_faces);
+
+  if (n_g_multiple_bfaces > 0) {
+
+    cs_int_t *multiple_bfaces = NULL;
+
+    bft_printf(_("     Global number of multiple border faces: %10llu\n"),
+               (unsigned long long)n_g_multiple_bfaces);
+
+    /* Post-treatment of the implied faces */
+
+    if (n_multiple_bfaces > 0) {
+
+      BFT_MALLOC(multiple_bfaces, n_multiple_bfaces, cs_int_t);
+
+      n_multiple_bfaces = 0;
+      for (i = 0; i < join_mesh->n_faces; i++)
+        if (new_face_type[i] ==CS_JOIN_FACE_MULTIPLE_BORDER)
+          multiple_bfaces[n_multiple_bfaces++] = i+1;
+
+    }
+
+    cs_join_post_faces_subset("MultipleBorderFaces",
+                              join_mesh,
+                              n_multiple_bfaces,
+                              multiple_bfaces);
+
+    BFT_FREE(multiple_bfaces);
+
+  }
+
   /* Get the family number to assign by default to the interior faces */
 
   default_family = _get_default_family(mesh);
@@ -3630,23 +4179,23 @@ cs_join_update_mesh_after_split(cs_join_param_t          join_param,
 
   /* Get associated global cell number */
 
-  _get_linked_cell_gnum(join_select, n2o_face_hist, &cell_gnum);
+  _get_linked_cell_gnum(join_select, join_param, n2o_face_hist, &cell_gnum);
 
 #if 0 && defined(DEBUG) && !defined(NDEBUG)
   bft_printf("\n  List of linked global cell number\n");
   for (i = 0; i < n2o_face_hist->index[n2o_face_hist->n_elts]; i++)
-    bft_printf(" %9d - %10u - %10u\n",
+    bft_printf(" %9d - Old face: %10u - Cell gnum: %10u\n",
                i, n2o_face_hist->g_list[i], cell_gnum[i]);
   bft_printf_flush();
 #endif
 
   /*  Update mesh structure:
         - Update first the interior faces because we need the global
-          numbering of the initial border faces
-        - Then update border faces
-  */
+          numbering of the initial border faces and its connectivity
+        - Then update border faces  */
 
   _add_new_interior_faces(join_select,
+                          join_param,
                           join_mesh,
                           join2mesh_vtx_id,
                           cell_gnum,
@@ -3657,6 +4206,7 @@ cs_join_update_mesh_after_split(cs_join_param_t          join_param,
                           mesh);
 
   _add_new_border_faces(join_select,
+                        join_param,
                         join_mesh,
                         join2mesh_vtx_id,
                         n_new_b_faces,
@@ -3664,41 +4214,16 @@ cs_join_update_mesh_after_split(cs_join_param_t          join_param,
                         n2o_face_hist,
                         mesh);
 
-  /* Re-orientaton of joined faces if needed */
-
-  _reorient_faces(mesh,
-                  n_old_i_faces,
-                  n_old_b_faces,
-                  n_select_cells,
-                  cell_selection,
-                  select_cell_cen);
-
-  /* Update global vertex information */
-
-  if (n_ranks == 1) {
-    mesh->n_g_vertices = mesh->n_vertices;
-    BFT_FREE(mesh->global_vtx_num);
-  }
-
-#if defined(HAVE_MPI)
-  if (n_ranks > 1) { /* Define a new compact global vertex numbering */
-
-    fvm_io_num_t  *vtx_io_num = fvm_io_num_create(NULL,
-                                                  mesh->global_vtx_num,
-                                                  mesh->n_vertices,
-                                                  0); /* Not shared */
-    const fvm_gnum_t  n_g_io_num = fvm_io_num_get_global_count(vtx_io_num);
-    const fvm_gnum_t  *io_gnum = fvm_io_num_get_global_num(vtx_io_num);
-
-    mesh->n_g_vertices = n_g_io_num;
-
-    for (i = 0; i < mesh->n_vertices; i++)
-      mesh->global_vtx_num[i] = io_gnum[i];
+  if (join_param.perio_num > 0)
+    cs_join_perio_split_update(join_param,
+                               n_old_i_faces,
+                               new_face_type,
+                               join_mesh,
+                               mesh);
 
-    fvm_io_num_destroy(vtx_io_num);
+  /* Delete unused vertices and define a compact global vertex numbering */
 
-  }
-#endif
+  _clean_vertices(join_param, mesh);
 
   /* Free memory */
 
@@ -3706,12 +4231,10 @@ cs_join_update_mesh_after_split(cs_join_param_t          join_param,
   BFT_FREE(cell_gnum);
   BFT_FREE(join2mesh_vtx_id);
 
-  cs_join_gset_destroy(&n2o_face_hist);
-
   /* Post if required */
 
-  cs_join_post_after_split(n_old_i_faces, n_new_i_faces,
-                           n_old_b_faces, n_new_b_faces,
+  cs_join_post_after_split(n_old_i_faces,
+                           n_old_b_faces,
                            n_g_new_b_faces,
                            join_select->n_faces,
                            mesh,
@@ -3759,7 +4282,6 @@ cs_join_update_mesh_after_split(cs_join_param_t          join_param,
 
 /*----------------------------------------------------------------------------
  * Clean a cs_mesh_t struct.
- *
  * Delete redundant and empty edge definitions.
  *
  * parameters:
@@ -3852,7 +4374,7 @@ cs_join_update_mesh_clean(cs_join_param_t   param,
     mesh->b_face_vtx_idx[i] = mesh->b_face_vtx_idx[i-1] + 1;
   mesh->b_face_vtx_idx[0] = 1;
 
-  BFT_REALLOC(mesh->b_face_vtx_lst, mesh->b_face_vtx_idx[mesh->n_b_faces],
+  BFT_REALLOC(mesh->b_face_vtx_lst, mesh->b_face_vtx_idx[mesh->n_b_faces]-1,
               cs_int_t);
 
   /* Interior face treatment */
@@ -3913,7 +4435,7 @@ cs_join_update_mesh_clean(cs_join_param_t   param,
     mesh->i_face_vtx_idx[i] = mesh->i_face_vtx_idx[i-1] + 1;
   mesh->i_face_vtx_idx[0] = 1;
 
-  BFT_REALLOC(mesh->i_face_vtx_lst, mesh->i_face_vtx_idx[mesh->n_i_faces],
+  BFT_REALLOC(mesh->i_face_vtx_lst, mesh->i_face_vtx_idx[mesh->n_i_faces]-1,
               cs_int_t);
 
   if (param.verbosity > 0) { /* Post-treat clean faces */
@@ -3924,7 +4446,7 @@ cs_join_update_mesh_clean(cs_join_param_t   param,
     buf[0] = n_i_clean_faces;
     buf[1] = n_b_clean_faces;
 
- #if defined(HAVE_MPI)
+#if defined(HAVE_MPI)
     if (cs_glob_n_ranks > 1) {
       MPI_Allreduce(buf, gbuf, 2, FVM_MPI_GNUM, MPI_SUM, cs_glob_mpi_comm);
 
@@ -3936,7 +4458,7 @@ cs_join_update_mesh_clean(cs_join_param_t   param,
     n_g_i_clean_faces = buf[0];
     n_g_b_clean_faces = buf[1];
 
-    if (param.verbosity > 1) { /* Post-treat clean faces */
+    if (param.verbosity > 1) { /* Post-process clean faces */
 
       if (n_g_i_clean_faces > 0 || n_g_b_clean_faces > 0) {
 
diff --git a/src/base/cs_join_util.c b/src/base/cs_join_util.c
index 76b0546..b109298 100644
--- a/src/base/cs_join_util.c
+++ b/src/base/cs_join_util.c
@@ -3,7 +3,7 @@
  *     This file is part of the Code_Saturne Kernel, element of the
  *     Code_Saturne CFD tool.
  *
- *     Copyright (C) 2008-2009 EDF S.A., France
+ *     Copyright (C) 2008-2010 EDF S.A., France
  *
  *     contact: saturne-support at edf.fr
  *
@@ -39,6 +39,7 @@
 
 #include <assert.h>
 #include <string.h>
+#include <math.h>
 
 /*----------------------------------------------------------------------------
  * BFT library headers
@@ -75,6 +76,14 @@
 BEGIN_C_DECLS
 
 /*============================================================================
+ * Static global variables
+ *===========================================================================*/
+
+int  cs_glob_join_count = 0;
+int  cs_glob_n_joinings = 0;
+cs_join_t  **cs_glob_join_array = NULL;
+
+/*============================================================================
  * Macro and type definitions
  *===========================================================================*/
 
@@ -83,6 +92,201 @@ BEGIN_C_DECLS
  *===========================================================================*/
 
 /*----------------------------------------------------------------------------
+ * Initialize a cs_join_param_t structure.
+ *
+ * parameters:
+ *   join_num      <-- number of the current joining operation
+ *   fraction      <-- value of the fraction parameter
+ *   plane         <-- value of the plane parameter
+ *   perio_num     <-- periodicity number (0 if not a periodic joining)
+ *   verbosity     <-- level of verbosity required
+ *
+ * returns:
+ *   a pointer to a cs_join_param_t structure
+ *---------------------------------------------------------------------------*/
+
+static cs_join_param_t
+_join_param_define(int      join_num,
+                   float    fraction,
+                   float    plane,
+                   int      perio_num,
+                   int      verbosity)
+{
+  double  cplane;
+  cs_join_param_t  param;
+
+  param.num = join_num;
+  param.perio_num = perio_num;
+
+  /* geometric parameters */
+
+  /* parameter used to compute the tolerance associated to each vertex.
+     Also used for finding equivalent vertices during edge intersections */
+
+  param.fraction = fraction;
+
+  /* parameter used to judge if two faces are in the same plane (during
+     the face splitting) */
+
+  param.plane = plane;
+  cplane = cos(param.plane *acos(-1.0)/180.);
+  param.plane_criteria = cplane * cplane;
+
+  /* Coef. used to modify the tolerance associated to each vertex BEFORE the
+     merge operation.
+     If coef = 0.0 => no vertex merge
+     If coef < 1.0 => reduce vertex merge
+     If coef = 1.0 => no change
+     If coef > 1.0 => increase vertex merge */
+
+  param.merge_tol_coef = 1.0;
+
+  /* Coef. used to compute a limit under which two vertices are merged
+     before the merge step.
+     Default value: 1e-3; Should be small. [1e-4, 1e-2] */
+
+   param.pre_merge_factor = 0.05;
+
+  /* Maximum number of equivalence breaks */
+
+   param.n_max_equiv_breaks = 500;
+
+   /* Tolerance computation mode: tcm
+      1: (default) tol = min. edge length related to a vertex * fraction
+      2: tolerance is computed like in mode 1 with in addition, the
+         multiplication by a coef. which is equal to the max sin(e1, e2)
+         where e1 and e2 are two edges sharing the same vertex V for which
+         we want to compute the tolerance
+     11: like 1 but only in taking into account only the selected faces
+     12: like 2 but only in taking into account only the selected faces
+   */
+
+   param.tcm = 1;
+
+   /* Intersection computation mode: icm
+      1: (default) Original algorithm. Try to clip intersection on extremity
+      2: New intersection algorithm. Avoid to clip intersection on extremity
+   */
+
+   param.icm = 1;
+
+   /* Maximum number of sub-faces for an initial selected face
+      Default value: 200 */
+
+   param.max_sub_faces = 200;
+
+   /* Deepest level reachable during tree building
+      Default value: 30  */
+
+   param.tree_max_level = 30;
+
+   /* Max. number of boxes which can be related to a leaf of the tree
+      if level != tree_max_level
+      Default value: 25  */
+
+   param.tree_n_max_boxes = 25;
+
+   /* Stop tree building if: n_linked_boxes > tree_max_box_ratio*n_init_boxes
+      Default value: 5.0 */
+
+   param.tree_max_box_ratio = 5.0;
+
+   /* Level of display */
+
+   param.verbosity = verbosity;
+
+   return param;
+}
+
+/*----------------------------------------------------------------------------
+ * Initialize a structure for the synchronization of single
+ * elements
+ *
+ * returns:
+ *   a pointer to a new structure used for synchronizing single elements
+ *----------------------------------------------------------------------------*/
+
+static cs_join_sync_t *
+_create_join_sync(void)
+{
+  cs_join_sync_t  *sync = NULL;
+
+  BFT_MALLOC(sync, 1, cs_join_sync_t);
+
+  sync->n_elts = 0;
+  sync->n_ranks = 0;
+  sync->ranks = NULL;
+  sync->index = NULL;
+  sync->array = NULL;
+
+  return sync;
+}
+
+/*----------------------------------------------------------------------------
+ * Destroy a structure for the synchronization of single elements.
+ *
+ * parameters:
+ *   sync   <->  pointer to a structure used for synchronizing single elements
+ *----------------------------------------------------------------------------*/
+
+static void
+_destroy_join_sync(cs_join_sync_t   **sync)
+{
+  cs_join_sync_t  *_sync = *sync;
+
+  if (_sync->n_elts > 0)
+    BFT_FREE(_sync->array);
+  if (_sync->n_ranks > 0)
+    BFT_FREE(_sync->ranks);
+  BFT_FREE(_sync->index);
+
+  BFT_FREE(_sync);
+
+  *sync = _sync;
+}
+
+/*----------------------------------------------------------------------------
+ * Destroy a cs_join_select_t structure.
+ *
+ * parameters:
+ *   param       <-- user-defined joining parameters
+ *   join_select <-- pointer to pointer to structure to destroy
+ *---------------------------------------------------------------------------*/
+
+static void
+_join_select_destroy(cs_join_param_t     param,
+                     cs_join_select_t  **join_select)
+{
+  if (*join_select != NULL) {
+
+    cs_join_select_t *_js = *join_select;
+
+    BFT_FREE(_js->faces);
+    BFT_FREE(_js->compact_face_gnum);
+    BFT_FREE(_js->cell_gnum);
+    BFT_FREE(_js->compact_rank_index);
+    BFT_FREE(_js->vertices);
+    BFT_FREE(_js->b_adj_faces);
+    BFT_FREE(_js->i_adj_faces);
+
+    BFT_FREE(_js->b_face_state);
+    BFT_FREE(_js->i_face_state);
+
+    if (param.perio_num > 0)
+      BFT_FREE(_js->per_v_couples);
+
+    _destroy_join_sync(&(_js->s_vertices));
+    _destroy_join_sync(&(_js->c_vertices));
+    _destroy_join_sync(&(_js->s_edges));
+    _destroy_join_sync(&(_js->c_edges));
+
+    BFT_FREE(*join_select);
+    *join_select = NULL;
+
+  }
+}
+
+/*----------------------------------------------------------------------------
  * Reduce numbering for the selected border faces.
  * After this function, we have a compact global face numbering for the
  * selected faces.
@@ -149,112 +353,6 @@ _compact_face_gnum_selection(cs_int_t     n_select_faces,
 }
 
 /*----------------------------------------------------------------------------
- * Eliminate redundancies found between two lists of elements.
- * Delete elements in elts[] and keep elements in the reference list.
- *
- * parameters:
- *  n_elts      <->  number of elements in the list to clean
- *  elts        <->  list of elements in the list to clean
- *  n_ref_elts  <--  number of elements in the reference list
- *  ref_elts    <--  list of reference elements
- *---------------------------------------------------------------------------*/
-
-static void
-_clean_selection(cs_int_t   *n_elts,
-                 cs_int_t   *elts[],
-                 cs_int_t    n_ref_elts,
-                 cs_int_t    ref_elts[])
-{
-  cs_int_t  i = 0, j = 0;
-  cs_int_t  _n_elts = 0;
-  cs_int_t  *_elts = *elts;
-
-  while (i < *n_elts && j < n_ref_elts) {
-
-    if (_elts[i] < ref_elts[j])
-      _elts[_n_elts++] = _elts[i++];
-    else if (_elts[i] > ref_elts[j])
-      j++;
-    else
-      i++, j++;
-
-  }
-
-  for (;i < *n_elts; i++, _n_elts++)
-    _elts[_n_elts] = _elts[i];
-
-  BFT_REALLOC(_elts, _n_elts, cs_int_t);
-
-  *n_elts = _n_elts;
-  *elts = _elts;
-}
-
-/*----------------------------------------------------------------------------
- * Extract vertices involved in the current joining operation
- *
- * parameters:
- *   n_select_faces    <-- number of selected faces
- *   select_faces      <-- list of faces selected
- *   f2v_idx           <-- "face -> vertex" connect. index
- *   f2v_lst           <-- "face -> vertex" connect. list
- *   n_vertices        <-- number of vertices
- *   n_select_vertices <-> pointer to the number of selected vertices
- *   select_vertices   <-> pointer to the list of selected vertices
- *---------------------------------------------------------------------------*/
-
-static void
-_extract_vertices(cs_int_t         n_select_faces,
-                  const cs_int_t  *select_faces,
-                  const cs_int_t  *f2v_idx,
-                  const cs_int_t  *f2v_lst,
-                  cs_int_t         n_vertices,
-                  cs_int_t        *n_select_vertices,
-                  cs_int_t        *select_vertices[])
-{
-  int  i, j, face_id;
-
-  cs_int_t  _n_select_vertices = 0;
-  cs_int_t  *counter = NULL, *_select_vertices = NULL;
-
-  if (n_select_faces > 0) {
-
-    BFT_MALLOC(counter, n_vertices, cs_int_t);
-
-    for (i = 0; i < n_vertices; i++)
-      counter[i] = 0;
-
-    for (i = 0; i < n_select_faces; i++) {
-
-      face_id = select_faces[i] - 1;
-
-      for (j = f2v_idx[face_id] - 1; j < f2v_idx[face_id+1] - 1; j++)
-        counter[f2v_lst[j]-1] = 1;
-
-    }
-
-    for (i = 0; i < n_vertices; i++)
-      _n_select_vertices += counter[i];
-
-    BFT_MALLOC(_select_vertices, _n_select_vertices, cs_int_t);
-
-    _n_select_vertices = 0;
-    for (i = 0; i < n_vertices; i++)
-      if (counter[i] == 1)
-        _select_vertices[_n_select_vertices++] = i + 1;
-
-    assert(_n_select_vertices > 0);
-
-    BFT_FREE(counter);
-
-  } /* End if n_select_faces > 0 */
-
-  /* Return pointers */
-
-  *n_select_vertices = _n_select_vertices;
-  *select_vertices = _select_vertices;
-}
-
-/*----------------------------------------------------------------------------
  * Extract faces implied in the current joining operation.
  * These are faces which share at least one vertex which is in the
  * select_vertices array.
@@ -386,53 +484,6 @@ _extract_contig_faces(cs_int_t          n_vertices,
   *contig_faces = _contig_faces;
 }
 
-/*----------------------------------------------------------------------------
- * Initialize a structure for the synchronization of single
- * elements
- *
- * returns:
- *   a pointer to a new structure used for synchronizing single elements
- *----------------------------------------------------------------------------*/
-
-static cs_join_sync_t *
-_create_join_sync(void)
-{
-  cs_join_sync_t  *sync = NULL;
-
-  BFT_MALLOC(sync, 1, cs_join_sync_t);
-
-  sync->n_elts = 0;
-  sync->n_ranks = 0;
-  sync->ranks = NULL;
-  sync->index = NULL;
-  sync->array = NULL;
-
-  return sync;
-}
-
-/*----------------------------------------------------------------------------
- * Destroy a structure for the synchronization of single elements.
- *
- * parameters:
- *   sync   <->  pointer to a structure used for synchronizing single elements
- *----------------------------------------------------------------------------*/
-
-static void
-_destroy_join_sync(cs_join_sync_t   **sync)
-{
-  cs_join_sync_t  *_sync = *sync;
-
-  if (_sync->n_elts > 0)
-    BFT_FREE(_sync->array);
-  if (_sync->n_ranks > 0)
-    BFT_FREE(_sync->ranks);
-  BFT_FREE(_sync->index);
-
-  BFT_FREE(_sync);
-
-  *sync = _sync;
-}
-
 #if defined(HAVE_MPI)
 /*----------------------------------------------------------------------------
  * Define a structure used for synchronizing "single" vertices.
@@ -573,11 +624,11 @@ _add_single_vertices(fvm_interface_set_t    *interfaces,
 
     for (ii = 0; ii < n_entities; ii++) {
 
-      int vtx_id = local_num[ii] - 1;
+      int  vtx_id = local_num[ii] - 1;
 
       assert(vtx_id < var_size);
 
-      if (count[vtx_id] == 0 && recv_buf[ii] > 0) {
+      if (count[vtx_id] == 0 && recv_buf[ii] > 0) { /* Find a single vertex */
 
         if (last_found_rank != distant_rank) {
           last_found_rank = distant_rank;
@@ -593,7 +644,7 @@ _add_single_vertices(fvm_interface_set_t    *interfaces,
 
   }
 
-  if (n_max_elts > 0) {
+  if (n_max_elts > 0) { /* We have found single vertices */
 
     BFT_MALLOC(single->ranks, n_max_ranks, int);
     BFT_MALLOC(single->index, n_max_ranks + 1, int);
@@ -810,7 +861,7 @@ _add_coupled_vertices(fvm_interface_set_t    *interfaces,
 
     for (ii = 0; ii < n_entities; ii++) {
 
-      if (recv_buf[ii] == local_rank) {
+      if (recv_buf[ii] == local_rank) { /* Coupled vertex found */
         coupled->n_elts++;
         if (last_found_rank != distant_rank) {
           last_found_rank = distant_rank;
@@ -912,7 +963,7 @@ _get_missing_vertices(cs_int_t              n_vertices,
                       cs_join_select_t     *selection)
 {
   cs_int_t  i;
-  fvm_gnum_t  n_g_elts;
+  fvm_gnum_t  n_l_elts, n_g_elts;
 
   cs_int_t  *vtx_tag = NULL, *related_ranks = NULL;
 
@@ -938,7 +989,9 @@ _get_missing_vertices(cs_int_t              n_vertices,
                        related_ranks,
                        selection->s_vertices);
 
-  MPI_Allreduce(&(selection->s_vertices->n_elts), &n_g_elts, 1, FVM_MPI_GNUM,
+  n_l_elts = selection->s_vertices->n_elts;
+
+  MPI_Allreduce(&n_l_elts, &n_g_elts, 1, FVM_MPI_GNUM,
                 MPI_SUM, cs_glob_mpi_comm);
 
   if (n_g_elts > 0) {
@@ -1312,7 +1365,7 @@ _add_single_edges(fvm_interface_set_t   *ifs,
 
       for (j = 0; j < tmp_size; j++) {
 
-        if (edge_tag[j] == 0) {
+        if (edge_tag[j] == 0) { /* Not already treated */
           if (cs_search_binary(n_entities, tmp_edges[2*j], local_num) > -1) {
             if (cs_search_binary(n_entities, tmp_edges[2*j+1], local_num) > -1) {
 
@@ -1323,7 +1376,7 @@ _add_single_edges(fvm_interface_set_t   *ifs,
                 last_found_rank = distant_rank;
               }
 
-              edge_tag[j] = 1;
+              edge_tag[j] = 1; /* Tag as done */
               s_edges->array[2*shift] = tmp_edges[2*j];
               s_edges->array[2*shift+1] = tmp_edges[2*j+1];
               shift++;
@@ -1812,7 +1865,7 @@ _get_missing_edges(cs_int_t              b_f2v_idx[],
                    cs_int_t              i_face_cells[],
                    cs_join_select_t     *selection)
 {
-  fvm_gnum_t  n_g_elts;
+  fvm_gnum_t  n_l_elts, n_g_elts;
 
   cs_int_t  *sel_v2v_idx = NULL, *sel_v2v_lst = NULL;
 
@@ -1837,13 +1890,15 @@ _get_missing_edges(cs_int_t              b_f2v_idx[],
                     i_face_cells,
                     selection->s_edges);
 
-  MPI_Allreduce(&(selection->s_edges->n_elts), &n_g_elts, 1, FVM_MPI_GNUM,
+  n_l_elts = selection->s_edges->n_elts;
+
+  MPI_Allreduce(&n_l_elts, &n_g_elts, 1, FVM_MPI_GNUM,
                 MPI_SUM, cs_glob_mpi_comm);
 
   if (n_g_elts > 0) {
 
-    bft_printf("  Global number of single edges found:    %6lu\n",
-               (unsigned long)n_g_elts);
+    bft_printf("  Global number of single edges found:    %6llu\n",
+               (unsigned long long)n_g_elts);
     bft_printf_flush();
     selection->do_single_sync = true;
 
@@ -1910,376 +1965,139 @@ _get_missing_edges(cs_int_t              b_f2v_idx[],
 }
 #endif /* defined(HAVE_MPI) */
 
+/*============================================================================
+ * Public function definitions
+ *===========================================================================*/
+
 /*----------------------------------------------------------------------------
- * Compute the cell center (= barycenter of the cell vertices) for the
- * selected cells.
- *
- * If selection = NULL, the whole mesh is selected.
- *
- * The caller is responsible for freeing the returned array.
+ * Create and initialize a cs_join_t structure.
  *
  * parameters:
- *   mesh           <-- pointer to a cs_mesh_t structure
- *   n_select_cells <-- number of cells in the selection
- *   selection      <-- list of selected cell number (size: n_cells)
- *                      cell "i" selected if selection[i] > 0
- *                      cell "i" not selected if selection[i] < 0
- *                      0 < selection[i] <= n_select_cells
+ *   join_number  <-- number related to the joining operation
+ *   sel_criteria <-- boundary face selection criteria
+ *   fraction     <-- value of the fraction parameter
+ *   plane        <-- value of the plane parameter
+ *   perio_num    <-- periodicity number (0 if not a periodic joining)
+ *   verbosity    <-- level of verbosity required
  *
  * returns:
- *   array of cell centers (size: n_select_cells*3, interlaced)
+ *   a pointer to a new allocated cs_join_t structure
  *---------------------------------------------------------------------------*/
 
-static cs_real_t *
-_cell_cen_vtx(const cs_mesh_t  *mesh,
-              cs_int_t          n_select_cells,
-              const cs_int_t    selection[])
+cs_join_t *
+cs_join_create(int          join_number,
+               const char  *sel_criteria,
+               float        fraction,
+               float        plane,
+               int          perio_num,
+               int          verbosity)
 {
-  cs_int_t  i, j, k, coord, cid, cid1, cid2, fid, vid, shift, vtx_counter;
-  cs_real_t  denum;
-
-  cs_int_t  *v_tag = NULL, *counter = NULL;
-  cs_int_t  *f2v_idx = NULL, *f2v_lst = NULL, *c2f_idx = NULL, *c2f_lst = NULL;
-
-  cs_real_t  *cell_cen = NULL;
-
-  if (selection == NULL)
-    n_select_cells = mesh->n_cells;
-
-  if (n_select_cells == 0)
-    return NULL;
-
-  BFT_MALLOC(cell_cen, 3*n_select_cells, cs_real_t);
-
-  /* Extract "cell -> faces" connectivity for the selected faces */
-  /* Build c2f_idx */
-
-  BFT_MALLOC(c2f_idx, n_select_cells + 1, cs_int_t);
-
-  for (i = 0; i < n_select_cells + 1; i++)
-    c2f_idx[i] = 0;
-
-  for (i = 0; i < mesh->n_b_faces; i++) {
-
-    cid = mesh->b_face_cells[i] - 1;
-
-    if (selection != NULL)
-      cid = selection[cid];
-
-    if (cid > -1) /* selected cell */
-      c2f_idx[cid+1] += 1;
-
-  } /* End of loop on border faces */
-
-  for (i = 0; i < mesh->n_i_faces; i++) {
-
-    cid1 = mesh->i_face_cells[2*i  ] - 1;
-    cid2 = mesh->i_face_cells[2*i+1] - 1;
-
-    if (selection != NULL) {
-
-      if (cid1 > -1 && cid1 < mesh->n_cells)
-        cid1 = selection[cid1];
-      else
-        cid1 = -1;
-
-      if (cid2 > -1 && cid2 < mesh->n_cells)
-        cid2 = selection[cid2];
-      else
-        cid2 = -1;
-
-    }
+  size_t  l;
 
-    if (cid1 > -1 && cid1 < mesh->n_cells) /* selected cell */
-      c2f_idx[cid1+1] += 1;
-    if (cid2 > -1 && cid2 < mesh->n_cells) /* selected cell */
-      c2f_idx[cid2+1] += 1;
+  cs_join_t  *join = NULL;
 
-  } /* End of loop on interior faces */
+  BFT_MALLOC(join, 1, cs_join_t);
 
-  c2f_idx[0] = 1;
-  for (i = 0; i < n_select_cells; i++)
-    c2f_idx[i+1] += c2f_idx[i];
+  join->selection = NULL;
 
-  /* Build c2f_lst */
-
-  BFT_MALLOC(c2f_lst, c2f_idx[n_select_cells]-1, cs_int_t);
-  BFT_MALLOC(counter, n_select_cells, cs_int_t);
-
-  for (i = 0; i < n_select_cells; i++)
-    counter[i] = 0;
-
-  for (i = 0; i < mesh->n_b_faces; i++) {
-
-    cid = mesh->b_face_cells[i] - 1;
-
-    if (selection != NULL)
-      cid = selection[cid];
-
-    if (cid > -1) { /* selected cell */
-      shift = c2f_idx[cid] - 1 + counter[cid];
-      c2f_lst[shift] = i+1;
-      counter[cid] += 1;
-    }
-
-  } /* End of loop on border faces */
-
-  for (i = 0; i < mesh->n_i_faces; i++) {
-
-    cid1 = mesh->i_face_cells[2*i  ] - 1;
-    cid2 = mesh->i_face_cells[2*i+1] - 1;
-
-    if (selection != NULL) {
-
-      if (cid1 > -1 && cid1 < mesh->n_cells)
-        cid1 = selection[cid1];
-      else
-        cid1 = -1;
-
-      if (cid2 > -1 && cid2 < mesh->n_cells)
-        cid2 = selection[cid2];
-      else
-        cid2 = -1;
-
-    }
-
-    if (cid1 > -1 && cid1 < mesh->n_cells) { /* selected cell */
-      shift = c2f_idx[cid1] - 1 + counter[cid1];
-      c2f_lst[shift] = i+1 + mesh->n_b_faces;
-      counter[cid1] += 1;
-    }
-
-    if (cid2 > -1 && cid2 < mesh->n_cells) { /* selected cell */
-      shift = c2f_idx[cid2] - 1 + counter[cid2];
-      c2f_lst[shift] = i+1 + mesh->n_b_faces;
-      counter[cid2] += 1;
-    }
-
-  } /* End of loop on interior faces */
-
-  /* Compute cell centers for the selected vertices */
-
-  for (i = 0; i < 3*n_select_cells; i++)
-    cell_cen[i] = 0.0;
-
-  BFT_MALLOC(v_tag, mesh->n_vertices, cs_int_t);
-
-  for (vid = 0; vid < mesh->n_vertices; vid++)
-    v_tag[vid] = -1;
-
-  /* Loop on selected cells */
-
-  for (i = 0; i < mesh->n_cells; i++) {
-
-    vtx_counter = 0;
-
-    if (selection != NULL)
-      cid = selection[i];
-    else
-      cid = i;
+  join->param = _join_param_define(join_number,
+                                   fraction,
+                                   plane,
+                                   perio_num,
+                                   verbosity);
 
-    if (cid > -1) { /* Loop on faces of the cell */
+  /* Copy the selection criteria for future use */
 
-      for (j = c2f_idx[cid] - 1; j < c2f_idx[cid + 1] - 1; j++) {
+  l = strlen(sel_criteria);
+  BFT_MALLOC(join->criteria, l + 1, char);
+  strcpy(join->criteria, sel_criteria);
 
-        cs_int_t  face_num = c2f_lst[j];
-
-        /* Interior or border face */
-
-        if (face_num > mesh->n_b_faces) {
-          fid = face_num - mesh->n_b_faces - 1;
-          f2v_idx = mesh->i_face_vtx_idx;
-          f2v_lst = mesh->i_face_vtx_lst;
-        }
-        else {
-          fid = face_num - 1;
-          f2v_idx = mesh->b_face_vtx_idx;
-          f2v_lst = mesh->b_face_vtx_lst;
-        }
-
-        /* Loop on vertices of the face */
-
-        for (k = f2v_idx[fid] - 1; k < f2v_idx[fid + 1] - 1; k++) {
-
-          vid = f2v_lst[k] - 1;
-
-          if (v_tag[vid] < cid) {
-            for (coord = 0; coord < 3; coord++)
-              cell_cen[3*cid + coord] += mesh->vtx_coord[3*vid + coord];
-            vtx_counter += 1;
-            v_tag[vid] = cid;
-          }
-
-        }
-
-      } /* End of loop on faces of the cell */
-
-      denum = 1/(double)vtx_counter;
-      for (coord = 0; coord < 3; coord++)
-        cell_cen[3*cid + coord] *= denum;
-
-    } /* End if cid >= 0 */
-
-  } /* End of loop on cells */
-
-  /* Free memory */
-
-  BFT_FREE(v_tag);
-  BFT_FREE(counter);
-  BFT_FREE(c2f_idx);
-  BFT_FREE(c2f_lst);
-
-  /* Return result */
-
-  return cell_cen;
+  return join;
 }
 
 /*----------------------------------------------------------------------------
- * Define the cell center for a selection of cells (those one which are
- * adjacent to the selected faces).
+ * Destroy a cs_join_t structure.
  *
  * parameters:
- *   n_select_faces  <-- number of border faces implied in the joining op.
- *   select_faces    <-- list of faces implied in the joining op.
- *   mesh            <-- pointer to cs_mesh_t structure
- *   cell_filter     --> selection array (size: mesh->n_cells)
- *   select_cell_cen --> cell center for the selected cells
+ *  join           <-> pointer to the cs_join_t structure to destroy
  *---------------------------------------------------------------------------*/
 
-static void
-_get_select_cell_cen(cs_int_t          n_select_faces,
-                     const cs_int_t    select_faces[],
-                     const cs_mesh_t  *mesh,
-                     cs_int_t         *cell_filter[],
-                     cs_real_t        *select_cell_cen[])
+void
+cs_join_destroy(cs_join_t  **join)
 {
-  cs_int_t  i, cid, fid, tag;
-
-  cs_int_t  n_select_cells = 0;
-  cs_int_t  *_cell_filter = NULL;
-  cs_real_t  *_select_cell_cen = NULL;
+  if (*join != NULL) {
 
-  BFT_MALLOC(_cell_filter, mesh->n_cells, cs_int_t);
+    cs_join_t  *_join = *join;
 
-  for (i = 0; i < mesh->n_cells; i++)
-    _cell_filter[i] = -1;
+    _join_select_destroy(_join->param, &_join->selection);
 
-  for (i = 0; i < n_select_faces; i++) {
-    fid = select_faces[i] - 1;
-    cid = mesh->b_face_cells[fid] - 1;
-    _cell_filter[cid] = i + 1;
-  }
-
-  /* Order cell selection */
-
-  for (i = 0, tag = 0; i < mesh->n_cells; i++)
-    if (_cell_filter[i] > 0)
-      _cell_filter[i] = tag++;
-
-  n_select_cells = n_select_faces; /* Border faces: 1 Face -> 1 Cell */
+    BFT_FREE(_join->criteria);
 
-  _select_cell_cen = _cell_cen_vtx(mesh, n_select_cells, _cell_filter);
+    BFT_FREE(_join);
+    *join = NULL;
 
-  /* Returns pointers */
-
-  *cell_filter = _cell_filter;
-  *select_cell_cen = _select_cell_cen;
+  }
 }
 
-/*============================================================================
- * Public function definitions
- *===========================================================================*/
-
 /*----------------------------------------------------------------------------
- * Define a set of parameters to control a contiguous distribution by block.
+ * Set advanced parameters to user-defined values.
  *
  * parameters:
- *   n_g_elts   <-- global number of elements to treat
- *   n_ranks    <-- number of ranks in the MPI communicator related to the
- *                  cs_join_block_info_t structure to create
- *   local_rank <-- rank in the MPI communicator related to the
- *                  cs_join_block_info_t structure to create
- *
- * returns:
- *   a new defined cs_join_block_info_t structure
+ *   join           <-> pointer a to cs_join_t struct. to update
+ *   mtf            <-- merge tolerance coefficient
+ *   pmf            <-- pre-merge factor
+ *   tcm            <-- tolerance computation mode
+ *   icm            <-- intersection computation mode
+ *   maxbrk         <-- max number of equivalences to break (merge step)
+ *   max_sub_faces  <-- max. possible number of sub-faces by splitting a face
+ *   tml            <-- tree max level
+ *   tmb            <-- tree max boxes
+ *   tmr            <-- tree max ratio
  *---------------------------------------------------------------------------*/
 
-cs_join_block_info_t
-cs_join_get_block_info(fvm_gnum_t  n_g_elts,
-                       int         n_ranks,
-                       int         local_rank)
+void
+cs_join_set_advanced_param(cs_join_t   *join,
+                           cs_real_t    mtf,
+                           cs_real_t    pmf,
+                           cs_int_t     tcm,
+                           cs_int_t     icm,
+                           cs_int_t     maxbrk,
+                           cs_int_t     max_sub_faces,
+                           cs_int_t     tml,
+                           cs_int_t     tmb,
+                           cs_real_t    tmr)
 {
-  size_t  block_size, n_treat_elts;
-  fvm_gnum_t  first_glob_num, last_glob_num;
+  /* Deepest level reachable during tree building */
 
-  cs_join_block_info_t  block_info;
+  if (tml < 1)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the tml parameter.\n"
+                "  It must be between > 0 and is here: %d\n"), tml);
 
-  /* Compute block_size */
+  join->param.tree_max_level = tml;
 
-  block_size = n_g_elts/n_ranks;
-  if (n_g_elts % n_ranks > 0)
-    block_size++;
+  /* Max. number of boxes which can be related to a leaf of the tree
+     if level != tree_max_level */
 
-  first_glob_num = local_rank * block_size + 1;
-  last_glob_num = first_glob_num + block_size;
+  if (tmb < 1)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the tmb parameter.\n"
+                "  It must be between > 0 and is here: %d\n"), tmb);
 
-  if (last_glob_num > n_g_elts) {
+  join->param.tree_n_max_boxes = tmb;
 
-    if (first_glob_num > n_g_elts) /* n_ranks > n_g_elts */
-      n_treat_elts = 0;
-    else
-      n_treat_elts = n_g_elts - first_glob_num + 1;
+  /* Stop tree building if:
+     n_linked_boxes > tree_max_box_ratio*n_init_boxes */
 
-  }
-  else
-    n_treat_elts = block_size;
-
-  block_info.n_g_elts = n_g_elts;
-  block_info.first_gnum = first_glob_num;
-
-  block_info.size = block_size;
-  block_info.local_size = n_treat_elts;
-
-  block_info.n_ranks = n_ranks;
-  block_info.local_rank = local_rank;
-
-  return  block_info;
-}
-
-/*----------------------------------------------------------------------------
- * Initialize a cs_join_param_t structure.
- *
- * parameters:
- *   join_num      <-- number of the current joining operation
- *   fraction      <-- value of the fraction parameter
- *   plane         <-- value of the plane parameter
- *   verbosity     <-- level of verbosity required
- *
- * returns:
- *   a pointer to a cs_join_param_t structure
- *---------------------------------------------------------------------------*/
-
-cs_join_param_t
-cs_join_param_define(int      join_num,
-                     float    fraction,
-                     float    plane,
-                     int      verbosity)
-{
-  cs_join_param_t  param;
-
-  param.num = join_num;
+  if (tmr <= 0.0 )
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the tmr parameter.\n"
+                "  It must be between > 0.0 and is here: %f\n"), tmr);
 
-  /* geometric parameters */
-
-  /* parameter used to compute the tolerance associated to each vertex.
-     Also used for finding equivalent vertices during edge intersections */
-
-  param.fraction = fraction;
-
-  /* parameter used to judge if two faces are in the same plane (during
-     the face splitting) */
-
-  param.plane = plane;
+  join->param.tree_max_box_ratio = tmr;
 
   /* Coef. used to modify the tolerance associated to each vertex BEFORE the
      merge operation.
@@ -2288,63 +2106,61 @@ cs_join_param_define(int      join_num,
      If coef = 1.0 => no change
      If coef > 1.0 => increase vertex merge */
 
-  param.merge_tol_coef = 1.0;
-
-  /* Coef. used to compute a limit under which two vertices are merged
-     before the merge step.
-     Default value: 1e-3; Should be small. [1e-4, 1e-2] */
-
-   param.pre_merge_factor = 0.05;
-
-  /* Maximum number of equivalence breaks */
-
-   param.n_max_equiv_breaks = 500;
-
-   /* Tolerance computation mode: tcm
-      1: (default) tol = min. edge length related to a vertex * fraction
-      2: tolerance is computed like in mode 1 with in addition, the
-         multiplication by a coef. which is equal to the max sin(e1, e2)
-         where e1 and e2 are two edges sharing the same vertex V for which
-         we want to compute the tolerance
-     11: like 1 but only in taking into account only the selected faces
-     12: like 2 but only in taking into account only the selected faces
-   */
+  if (mtf < 0.0)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the merge tolerance factor.\n"
+                "  It must be positive or nul and not: %f\n"), mtf);
 
-   param.tcm = 1;
+  join->param.merge_tol_coef = mtf;
 
-   /* Intersection computation mode: icm
-      1: (default) Original algorithm. Try to clip intersection on extremity
-      2: New intersection algorithm. Avoid to clip intersection on extremity
-   */
+   /* Maximum number of equivalence breaks */
 
-   param.icm = 1;
+  if (maxbrk < 0)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the max. number of tolerance breaks.\n"
+                "  It must be between >= 0 and not: %d\n"), maxbrk);
 
-   /* Maximum number of sub-faces for an initial selected face
-      Default value: 200 */
+  join->param.n_max_equiv_breaks = maxbrk;
 
-   param.max_sub_faces = 200;
+  /* Pre-merge factor. This parameter is used to define a limit
+     under which two vertices are merged before the merge step.
+     Tolerance limit for the pre-merge = pmf * fraction
+     Default value: 0.10 */
 
-   /* Deepest level reachable during tree building
-      Default value: 30  */
+  join->param.pre_merge_factor = pmf;
 
-   param.tree_max_level = 30;
+  /* Tolerance computation mode */
 
-   /* Max. number of boxes which can be related to a leaf of the tree
-      if level != tree_max_level
-      Default value: 25  */
+  if ( (tcm)%10 < 1 || (tcm)%10 > 2)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the tcm parameter.\n"
+                "  It must be between 1, 2 or 11, 12 and here is: %d\n"), tcm);
 
-   param.tree_n_max_boxes = 25;
+  join->param.tcm = tcm;
 
-   /* Stop tree building if: n_linked_boxes > tree_max_box_ratio*n_init_boxes
-      Default value: 5.0 */
+  /* Intersection computation mode */
 
-   param.tree_max_box_ratio = 5.0;
+  if (icm != 1 && icm != 2)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for icm parameter.\n"
+                "  It must be 1 or 2 and here is: %d\n"), icm);
 
-   /* Level of display */
+  join->param.icm = icm;
 
-   param.verbosity = verbosity;
+  /* Maximum number of sub-faces */
+
+  if (max_sub_faces < 1)
+    bft_error(__FILE__, __LINE__, 0,
+              _("Mesh joining:"
+                "  Forbidden value for the maxsf parameter.\n"
+                "  It must be between > 0 and here is: %d\n"), max_sub_faces);
+
+  join->param.max_sub_faces = max_sub_faces;
 
-   return param;
 }
 
 /*----------------------------------------------------------------------------
@@ -2378,6 +2194,10 @@ cs_join_select_create(const char  *selection_criteria,
 
   BFT_MALLOC(selection, 1, cs_join_select_t);
 
+  selection->n_init_b_faces = mesh->n_b_faces;
+  selection->n_init_i_faces = mesh->n_i_faces;
+  selection->n_init_vertices = mesh->n_vertices;
+
   selection->n_faces = 0;
   selection->n_g_faces = 0;
 
@@ -2385,8 +2205,6 @@ cs_join_select_create(const char  *selection_criteria,
   selection->compact_face_gnum = NULL;
   selection->compact_rank_index = NULL;
 
-  selection->cell_filter = NULL;
-  selection->cell_cen = NULL;
   selection->cell_gnum = NULL;
 
   selection->n_vertices = 0;
@@ -2398,6 +2216,12 @@ cs_join_select_create(const char  *selection_criteria,
   selection->n_i_adj_faces = 0;
   selection->i_adj_faces = NULL;
 
+  selection->b_face_state = NULL;
+  selection->i_face_state = NULL;
+
+  selection->n_couples = 0;
+  selection->per_v_couples = NULL;
+
   /*
      Single elements (Only possible in parallel. It appears
      when the domain splitting has a poor quality and elements
@@ -2449,7 +2273,9 @@ cs_join_select_create(const char  *selection_criteria,
 #if defined(HAVE_MPI)
   if (n_ranks > 1) { /* Parallel treatment */
 
-    MPI_Allreduce(&(selection->n_faces), &(selection->n_g_faces),
+    fvm_gnum_t n_l_faces = selection->n_faces;
+
+    MPI_Allreduce(&n_l_faces, &(selection->n_g_faces),
                   1, FVM_MPI_GNUM, MPI_SUM, cs_glob_mpi_comm);
 
     for (i = 0; i < selection->n_faces; i++) {
@@ -2461,19 +2287,8 @@ cs_join_select_create(const char  *selection_criteria,
   }
 #endif
 
-  /* Define the cell center for a selection of cells (those one which are
-     adjacent to the selected faces).
-     This will be used to check the orientation of faces at the end of the
-     joining operation */
-
-  _get_select_cell_cen(selection->n_faces,
-                       selection->faces,
-                       mesh,
-                       &(selection->cell_filter),
-                       &(selection->cell_cen));
-
   if (verbosity > 0)
-    bft_printf(_("  Number of boundary faces selected for joining: %10u\n"),
+    bft_printf(_("  Global number of boundary faces selected for joining: %10u\n"),
                selection->n_g_faces);
 
   /* Define a compact global numbering on selected border faces and
@@ -2485,31 +2300,15 @@ cs_join_select_create(const char  *selection_criteria,
 
   assert(selection->n_g_faces == selection->compact_rank_index[n_ranks]);
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-  bft_printf(_("\n  Selected faces for the joining operation:\n"));
-  for (i = 0; i < selection->n_faces; i++)
-    bft_printf(" %9d | %9d | %10u | %10u\n",
-               i, selection->faces[i], selection->compact_face_gnum[i],
-               selection->cell_gnum[i]);
-  bft_printf("\n");
-#endif
-
   /* Extract selected vertices from the selected border faces */
 
-  _extract_vertices(selection->n_faces,
-                    selection->faces,
-                    mesh->b_face_vtx_idx,
-                    mesh->b_face_vtx_lst,
-                    mesh->n_vertices,
-                    &(selection->n_vertices),
-                    &(selection->vertices));
-
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-  bft_printf(_("\n  Select vertices for the joining operation:\n"));
-  for (i = 0; i < selection->n_vertices; i++)
-    bft_printf(" %9d | %9d\n", i, selection->vertices[i]);
-  bft_printf("\n");
-#endif
+  cs_join_extract_vertices(selection->n_faces,
+                           selection->faces,
+                           mesh->b_face_vtx_idx,
+                           mesh->b_face_vtx_lst,
+                           mesh->n_vertices,
+                           &(selection->n_vertices),
+                           &(selection->vertices));
 
 #if defined(HAVE_MPI)
   if (n_ranks > 1) { /* Search for missing vertices */
@@ -2547,17 +2346,10 @@ cs_join_select_create(const char  *selection_criteria,
 
   /* Remove border faces already defined in selection->faces */
 
-  _clean_selection(&(selection->n_b_adj_faces),
-                   &(selection->b_adj_faces),
-                   selection->n_faces,
-                   selection->faces);
-
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-  bft_printf(_("\n  Contiguous border faces for the joining operation:\n"));
-  for (i = 0; i < selection->n_b_adj_faces; i++)
-    bft_printf(" %9d | %9d\n", i, selection->b_adj_faces[i]);
-  bft_printf("\n");
-#endif
+  cs_join_clean_selection(&(selection->n_b_adj_faces),
+                          &(selection->b_adj_faces),
+                          selection->n_faces,
+                          selection->faces);
 
   /* Extract list of interior faces contiguous to the selected vertices */
 
@@ -2569,13 +2361,6 @@ cs_join_select_create(const char  *selection_criteria,
                         &(selection->n_i_adj_faces),
                         &(selection->i_adj_faces));
 
-#if 0 && defined(DEBUG) && !defined(NDEBUG)
-  bft_printf(_("\n  Contiguous interior faces for the joining operation:\n"));
-  for (i = 0; i < selection->n_i_adj_faces; i++)
-    bft_printf(" %9d | %9d\n", i, selection->i_adj_faces[i]);
-  bft_printf("\n");
-#endif
-
    /* Check if there is no forgotten vertex in the selection.
       Otherwise define structures to enable future synchronization.
       Only possible in parallel. */
@@ -2599,10 +2384,40 @@ cs_join_select_create(const char  *selection_criteria,
   }
 #endif
 
+  /* Face state setting */
+
+  BFT_MALLOC(selection->b_face_state, mesh->n_b_faces, cs_join_state_t);
+  BFT_MALLOC(selection->i_face_state, mesh->n_i_faces, cs_join_state_t);
+
+  for (i = 0; i < mesh->n_b_faces; i++)
+    selection->b_face_state[i] = CS_JOIN_STATE_UNDEF;
+
+  for (i = 0; i < mesh->n_i_faces; i++)
+    selection->i_face_state[i] = CS_JOIN_STATE_UNDEF;
+
+  for (i = 0; i < selection->n_faces; i++)
+    selection->b_face_state[selection->faces[i]-1] = CS_JOIN_STATE_ORIGIN;
+
+  for (i = 0; i < selection->n_b_adj_faces; i++)
+    selection->b_face_state[selection->b_adj_faces[i]-1] = CS_JOIN_STATE_ORIGIN;
+
+  for (i = 0; i < selection->n_i_adj_faces; i++)
+    selection->i_face_state[selection->i_adj_faces[i]-1] = CS_JOIN_STATE_ORIGIN;
+
   /* Display information according to the level of verbosity */
 
   if (verbosity > 1) {
 
+    bft_printf(_("\n  Local information about selection structure:\n"));
+    bft_printf(_("    number of faces:               %8d\n"),
+               selection->n_faces);
+    bft_printf(_("    number of vertices:            %8d\n"),
+               selection->n_vertices);
+    bft_printf(_("    number of adj. border faces:   %8d\n"),
+               selection->n_b_adj_faces);
+    bft_printf(_("    number of adj. interior faces: %8d\n"),
+               selection->n_i_adj_faces);
+
     if (selection->do_single_sync == true) {
       bft_printf("\n Information on single/coupled elements:\n");
       bft_printf("   Number of single vertices : %6d with %3d related ranks\n",
@@ -2620,46 +2435,205 @@ cs_join_select_create(const char  *selection_criteria,
       for (i = 0; i < n_ranks + 1; i++)
         bft_printf(" %5d | %11u\n", i, selection->compact_rank_index[i]);
       bft_printf("\n");
-
-      bft_printf_flush();
     }
 
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf(_("\n  Selected faces for the joining operation:\n"));
+  for (i = 0; i < selection->n_faces; i++)
+    bft_printf(" %9d | %9d | %10u | %10u\n",
+               i, selection->faces[i], selection->compact_face_gnum[i],
+               selection->cell_gnum[i]);
+  bft_printf("\n");
+#endif
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf(_("\n  Select vertices for the joining operation:\n"));
+  for (i = 0; i < selection->n_vertices; i++)
+    bft_printf(" %9d | %9d\n", i, selection->vertices[i]);
+  bft_printf("\n");
+#endif
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf(_("\n  Contiguous border faces for the joining operation:\n"));
+  for (i = 0; i < selection->n_b_adj_faces; i++)
+    bft_printf(" %9d | %9d\n", i, selection->b_adj_faces[i]);
+  bft_printf("\n");
+#endif
+
+#if 0 && defined(DEBUG) && !defined(NDEBUG)
+  bft_printf(_("\n  Contiguous interior faces for the joining operation:\n"));
+  for (i = 0; i < selection->n_i_adj_faces; i++)
+    bft_printf(" %9d | %9d\n", i, selection->i_adj_faces[i]);
+  bft_printf("\n");
+#endif
+
   } /* End if verbosity > 1 */
 
+  bft_printf_flush();
+
   return  selection;
 }
 
 /*----------------------------------------------------------------------------
- * Destroy a cs_join_select_t structure.
+ * Define a set of parameters to control a contiguous distribution by block.
  *
  * parameters:
- *   join_select <-- pointer to pointer to structure to destroy
+ *   n_g_elts   <-- global number of elements to treat
+ *   n_ranks    <-- number of ranks in the MPI communicator related to the
+ *                  cs_join_block_info_t structure to create
+ *   local_rank <-- rank in the MPI communicator related to the
+ *                  cs_join_block_info_t structure to create
+ *
+ * returns:
+ *   a new defined cs_join_block_info_t structure
+ *---------------------------------------------------------------------------*/
+
+cs_join_block_info_t
+cs_join_get_block_info(fvm_gnum_t  n_g_elts,
+                       int         n_ranks,
+                       int         local_rank)
+{
+  size_t  block_size, n_treat_elts;
+  fvm_gnum_t  first_glob_num, last_glob_num;
+
+  cs_join_block_info_t  block_info;
+
+  /* Compute block_size */
+
+  block_size = n_g_elts/n_ranks;
+  if (n_g_elts % n_ranks > 0)
+    block_size++;
+
+  first_glob_num = local_rank * block_size + 1;
+  last_glob_num = first_glob_num + block_size;
+
+  if (last_glob_num > n_g_elts) {
+
+    if (first_glob_num > n_g_elts) /* n_ranks > n_g_elts */
+      n_treat_elts = 0;
+    else
+      n_treat_elts = n_g_elts - first_glob_num + 1;
+
+  }
+  else
+    n_treat_elts = block_size;
+
+  block_info.n_g_elts = n_g_elts;
+  block_info.first_gnum = first_glob_num;
+
+  block_info.size = block_size;
+  block_info.local_size = n_treat_elts;
+
+  block_info.n_ranks = n_ranks;
+  block_info.local_rank = local_rank;
+
+  return  block_info;
+}
+
+/*----------------------------------------------------------------------------
+ * Extract vertices from a selection of faces.
+ *
+ * parameters:
+ *   n_select_faces    <-- number of selected faces
+ *   select_faces      <-- list of faces selected
+ *   f2v_idx           <-- "face -> vertex" connect. index
+ *   f2v_lst           <-- "face -> vertex" connect. list
+ *   n_vertices        <-- number of vertices
+ *   n_select_vertices <-> pointer to the number of selected vertices
+ *   select_vertices   <-> pointer to the list of selected vertices
  *---------------------------------------------------------------------------*/
 
 void
-cs_join_select_destroy(cs_join_select_t  **join_select)
+cs_join_extract_vertices(cs_int_t         n_select_faces,
+                         const cs_int_t  *select_faces,
+                         const cs_int_t  *f2v_idx,
+                         const cs_int_t  *f2v_lst,
+                         cs_int_t         n_vertices,
+                         cs_int_t        *n_select_vertices,
+                         cs_int_t        *select_vertices[])
 {
-  if (*join_select != NULL) {
+  int  i, j, face_id;
 
-    cs_join_select_t *_js = *join_select;
+  cs_int_t  _n_select_vertices = 0;
+  cs_int_t  *counter = NULL, *_select_vertices = NULL;
 
-    BFT_FREE(_js->faces);
-    BFT_FREE(_js->compact_face_gnum);
-    BFT_FREE(_js->cell_filter);
-    BFT_FREE(_js->cell_cen);
-    BFT_FREE(_js->cell_gnum);
-    BFT_FREE(_js->compact_rank_index);
-    BFT_FREE(_js->vertices);
-    BFT_FREE(_js->b_adj_faces);
-    BFT_FREE(_js->i_adj_faces);
+  if (n_select_faces > 0) {
 
-    _destroy_join_sync(&(_js->s_vertices));
-    _destroy_join_sync(&(_js->c_vertices));
-    _destroy_join_sync(&(_js->s_edges));
-    _destroy_join_sync(&(_js->c_edges));
+    BFT_MALLOC(counter, n_vertices, cs_int_t);
+
+    for (i = 0; i < n_vertices; i++)
+      counter[i] = 0;
+
+    for (i = 0; i < n_select_faces; i++) {
+
+      face_id = select_faces[i] - 1;
+
+      for (j = f2v_idx[face_id] - 1; j < f2v_idx[face_id+1] - 1; j++)
+        counter[f2v_lst[j]-1] = 1;
+
+    }
+
+    for (i = 0; i < n_vertices; i++)
+      _n_select_vertices += counter[i];
+
+    BFT_MALLOC(_select_vertices, _n_select_vertices, cs_int_t);
+
+    _n_select_vertices = 0;
+    for (i = 0; i < n_vertices; i++)
+      if (counter[i] == 1)
+        _select_vertices[_n_select_vertices++] = i + 1;
+
+    assert(_n_select_vertices > 0);
+
+    BFT_FREE(counter);
+
+  } /* End if n_select_faces > 0 */
+
+  /* Return pointers */
+
+  *n_select_vertices = _n_select_vertices;
+  *select_vertices = _select_vertices;
+}
+
+/*----------------------------------------------------------------------------
+ * Eliminate redundancies found between two lists of elements.
+ * Delete elements in elts[] and keep elements in the reference list.
+ *
+ * parameters:
+ *  n_elts      <->  number of elements in the list to clean
+ *  elts        <->  list of elements in the list to clean
+ *  n_ref_elts  <--  number of elements in the reference list
+ *  ref_elts    <--  list of reference elements
+ *---------------------------------------------------------------------------*/
+
+void
+cs_join_clean_selection(cs_int_t   *n_elts,
+                        cs_int_t   *elts[],
+                        cs_int_t    n_ref_elts,
+                        cs_int_t    ref_elts[])
+{
+  cs_int_t  i = 0, j = 0;
+  cs_int_t  _n_elts = 0;
+  cs_int_t  *_elts = *elts;
+
+  while (i < *n_elts && j < n_ref_elts) {
+
+    if (_elts[i] < ref_elts[j])
+      _elts[_n_elts++] = _elts[i++];
+    else if (_elts[i] > ref_elts[j])
+      j++;
+    else
+      i++, j++;
 
-    BFT_FREE(*join_select);
   }
+
+  for (;i < *n_elts; i++, _n_elts++)
+    _elts[_n_elts] = _elts[i];
+
+  BFT_REALLOC(_elts, _n_elts, cs_int_t);
+
+  *n_elts = _n_elts;
+  *elts = _elts;
 }
 
 /*----------------------------------------------------------------------------
diff --git a/src/base/cs_matrix.c b/src/base/cs_matrix.c
index e8479e1..703f0c8 100644
--- a/src/base/cs_matrix.c
+++ b/src/base/cs_matrix.c
@@ -623,6 +623,8 @@ _create_coeff_native(void)
 
   /* Initialize */
 
+  mc->symmetric = false;
+
   mc->da = NULL;
   mc->xa = NULL;
 
diff --git a/src/base/cs_mesh.c b/src/base/cs_mesh.c
index ec5d844..5a7d6f8 100644
--- a/src/base/cs_mesh.c
+++ b/src/base/cs_mesh.c
@@ -415,23 +415,23 @@ _print_cell_neighbor_info(const cs_mesh_t  *mesh)
 #endif
 
     for (i = 0, j = 1; i < n_steps - 1; i++, j++)
-      bft_printf("    %3d : [ %10d ; %10d [ = %10lu\n",
+      bft_printf("    %3d : [ %10d ; %10d [ = %10llu\n",
                  i+1,
                  (int)(n_min_neighbors + i*step),
                  (int)(n_min_neighbors + j*step),
-                 (unsigned long)(count[i]));
+                 (unsigned long long)(count[i]));
 
-    bft_printf("    %3d : [ %10d ; %10d ] = %10lu\n",
+    bft_printf("    %3d : [ %10d ; %10d ] = %10llu\n",
                n_steps,
                (int)(n_min_neighbors + (n_steps - 1)*step),
                n_max_neighbors,
-               (unsigned long)(count[n_steps - 1]));
+               (unsigned long long)(count[n_steps - 1]));
   }
 
   else { /* if (n_min_neighbors == n_max_neighbors) */
-    bft_printf("    %3d : [ %10d ; %10d ] = %10lu\n",
+    bft_printf("    %3d : [ %10d ; %10d ] = %10llu\n",
                1, n_min_neighbors, n_max_neighbors,
-               (unsigned long)mesh->n_g_cells);
+               (unsigned long long)mesh->n_g_cells);
 
   }
 
@@ -805,6 +805,8 @@ cs_mesh_builder_create(void)
   mesh_builder->per_face_lst = NULL;
   mesh_builder->per_rank_lst = NULL;
 
+  mesh_builder->face_ifs = NULL;
+
   return mesh_builder;
 }
 
@@ -914,6 +916,8 @@ cs_mesh_builder_destroy(cs_mesh_builder_t  *mesh_builder)
   if (cs_glob_n_ranks > 1)
     BFT_FREE(mesh_builder->per_rank_lst);
 
+  mesh_builder->face_ifs = fvm_interface_set_destroy(mesh_builder->face_ifs);
+
   BFT_FREE(mesh_builder);
 
   return mesh_builder;
@@ -1483,15 +1487,15 @@ cs_mesh_print_info(const cs_mesh_t  *mesh,
                    const char       *name)
 {
   bft_printf(_(" %s\n"
-               "     Number of cells:          %lu\n"
-               "     Number of interior faces: %lu\n"
-               "     Number of boundary faces: %lu\n"
-               "     Number of vertices:       %lu\n"),
+               "     Number of cells:          %llu\n"
+               "     Number of interior faces: %llu\n"
+               "     Number of boundary faces: %llu\n"
+               "     Number of vertices:       %llu\n"),
              name,
-             (unsigned long)(mesh->n_g_cells),
-             (unsigned long)(mesh->n_g_i_faces),
-             (unsigned long)(mesh->n_g_b_faces),
-             (unsigned long)(mesh->n_g_vertices));
+             (unsigned long long)(mesh->n_g_cells),
+             (unsigned long long)(mesh->n_g_i_faces),
+             (unsigned long long)(mesh->n_g_b_faces),
+             (unsigned long long)(mesh->n_g_vertices));
 }
 
 /*----------------------------------------------------------------------------
diff --git a/src/base/cs_mesh_quantities.c b/src/base/cs_mesh_quantities.c
index effc30d..02f4c88 100644
--- a/src/base/cs_mesh_quantities.c
+++ b/src/base/cs_mesh_quantities.c
@@ -1229,10 +1229,11 @@ cs_mesh_quantities_check_vol(const cs_mesh_t             *mesh,
 
   if (error_count > 0)
     bft_error(__FILE__, __LINE__, 0,
-              _("  %lu cells have a Negative volume.\n"
+              _("  %llu cells have a Negative volume.\n"
                 " Run mesh quality check for post-processing output.\n"
                 " In case of mesh joining, this may be due to overly "
-                " agressive joining parameters."), (unsigned long)error_count);
+                " agressive joining parameters."),
+              (unsigned long long)error_count);
 }
 
 /*----------------------------------------------------------------------------
diff --git a/src/base/cs_mesh_warping.c b/src/base/cs_mesh_warping.c
index 8ed4a6f..30d02a4 100644
--- a/src/base/cs_mesh_warping.c
+++ b/src/base/cs_mesh_warping.c
@@ -663,6 +663,9 @@ _cut_warped_faces_perio(cs_mesh_t       *mesh,
 
         /* Update "face -> vertices" connectivity */
 
+        for (j = 0; j < 3; j++)
+          new_face_vtx_lst[connect_size + j] = new_face_connectivity[shift++];
+
         n_new_faces++;
         connect_size += 3;
         new_face_vtx_idx[n_new_faces]
diff --git a/src/base/cs_multigrid.c b/src/base/cs_multigrid.c
index 60d01bc..9ffef87 100644
--- a/src/base/cs_multigrid.c
+++ b/src/base/cs_multigrid.c
@@ -1720,9 +1720,9 @@ void CS_PROCF(clmlga, CLMLGA)
 
         bft_printf
           (_("                                  total       min        max\n"
-             "     number of cells:     %12lu %10d %10d\n"
+             "     number of cells:     %12llu %10d %10d\n"
              "     number of faces:                  %10d %10d\n"),
-           (unsigned long)n_g_cells, n_c_min, n_c_max, n_f_min, n_f_max);
+           (unsigned long long)n_g_cells, n_c_min, n_c_max, n_f_min, n_f_max);
       }
 
 #endif
@@ -1748,8 +1748,8 @@ void CS_PROCF(clmlga, CLMLGA)
   if (*iwarnp > 1)
     bft_printf
       (_("   number of coarse grids:           %d\n"
-         "   number of cells in coarsest grid: %lu\n\n"),
-       grid_lv, (unsigned long)n_g_cells);
+         "   number of cells in coarsest grid: %llu\n\n"),
+       grid_lv, (unsigned long long)n_g_cells);
 
   /* Prepare preprocessing info if necessary */
 
diff --git a/src/base/cs_opts.c b/src/base/cs_opts.c
index ac3dbe3..a812050 100644
--- a/src/base/cs_opts.c
+++ b/src/base/cs_opts.c
@@ -117,7 +117,6 @@ _arg_env_help(const char  *name)
   fprintf
     (e, _(" --solcom          stand-alone kernel with \"geomet\" mesh in\n"
           "                   SolCom format (obsolete)\n"));
-#if defined(HAVE_MPI)
   fprintf
     (e, _(" --mpi             use MPI for parallelism or coupling\n"
           "                   [appnum]: number of this application in\n"
@@ -128,7 +127,6 @@ _arg_env_help(const char  *name)
           "                     eo:  MPI-IO with explicit offsets\n"
           "                          (default if available)\n"
           "                     ip:  MPI-IO with individual file pointers\n"));
-#endif
   fprintf
     (e, _(" -q, --quality     mesh quality verification mode\n"));
   fprintf
@@ -149,16 +147,12 @@ _arg_env_help(const char  *name)
           "                     0: no redirection (if independant\n"
           "                        terminals, debugger type)\n"
           "                     1: output in \"listing_n<rang>\"\n"));
-#if defined(HAVE_LIBXML2)
   fprintf
     (e, _(" -p, --param       <file_name> parameter file\n"));
-#endif
 
-#if defined(HAVE_SOCKET)
   fprintf
     (e, _(" --syr-socket      enable sockets for SYRTHES 3 coupling\n"
           "                   <port_num> port number on rank 0\n"));
-#endif
 
   fprintf
     (e, _(" --version         print version number\n"));
@@ -397,7 +391,14 @@ cs_opts_mpi_init(int    *argc,
   int appnum = -1;
   int use_mpi = false;
 
-#if defined(MPICH_NAME)
+#if defined(__bg__) || defined(__CRAYXT_COMPUTE_LINUX_TARGET)
+
+  /* Notes: Blue Gene/L also defines the BGLMPI_SIZE environment variable.
+   *        Blue Gene/P defines BG_SIZE (plus BG_MAPPING, and BG_RELEASE). */
+
+  use_mpi = true;
+
+#elif defined(MPICH_NAME)
 
   /*
     Using standard MPICH1 1.2.x with the p4 (default) mechanism,
@@ -420,12 +421,6 @@ cs_opts_mpi_init(int    *argc,
   if (getenv("GMPI_ID") != NULL) /* In case we are using MPICH-GM */
     use_mpi = true;
 
-  /* Notes: Blue Gene/L also defines the BGLMPI_SIZE environment variable.
-   *        Blue Gene/P defines BG_SIZE (plus BG_MAPPING, and BG_RELEASE). */
-#elif   defined(__blrts__) || defined(__bgp__) \
-   || defined(__CRAYXT_COMPUTE_LINUX_TARGET)
-  use_mpi = true;
-
 #elif defined(LAM_MPI)
   if (getenv("LAMRANK") != NULL)
     use_mpi = true;
@@ -605,6 +600,15 @@ cs_opts_define(int         argc,
         argerr = 1;
     }
 
+#else /* !defined(HAVE_MPI) */
+
+    else if ((strcmp(s, "--mpi") == 0) || (strcmp(s, "--mpi-io") == 0)) {
+      fprintf(stderr, _("%s was built without MPI support,\n"
+                        "so option \"%s\" may not be used.\n"),
+              argv[0], s);
+      cs_exit(EXIT_FAILURE);
+    }
+
 #endif /* defined(HAVE_MPI) */
 
     else if (strcmp(s, "-q") == 0 || strcmp(s, "--quality") == 0)
@@ -644,12 +648,21 @@ cs_opts_define(int         argc,
       }
     }
 
-#if defined(HAVE_LIBXML2)
     else if (strcmp(s, "-p") == 0 || strcmp(s, "--param") == 0) {
-      s = argv[++arg_id];
-      argerr = cs_gui_file_loading(s);
+      if (arg_id + 1 < argc) {
+        s = argv[++arg_id];
+#if defined(HAVE_LIBXML2)
+        argerr = cs_gui_file_loading(s);
+#else
+        fprintf(stderr, _("%s was built without XML support,\n"
+                          "so parameter file \"%s\" may not be loaded.\n"),
+                argv[0], s);
+        cs_exit(EXIT_FAILURE);
+#endif /* defined(HAVE_LIBXML2) */
+      }
+      else
+        argerr = 1;
     }
-#endif
 
     else if (strcmp(s, "--cwf") == 0) {
       opts->cwf = true;
@@ -695,20 +708,34 @@ cs_opts_define(int         argc,
         argerr = 1;
     }
 
-#endif /* defined(HAVE_SOCKET) */
+#else /* !defined(HAVE_SOCKET) */
 
-#if defined(HAVE_DLOPEN)
+    else if (   strcmp(s, "--syr-socket") == 0
+             || (strncmp(s, socketoptbase, strlen(socketoptbase)) == 0)
+             || (strncmp(s, keyoptbase, strlen(keyoptbase)) == 0)) {
+      fprintf(stderr, _("%s was built without socket support,\n"
+                        "so option \"%s\" may not be used.\n"),
+              argv[0], s);
+      cs_exit(EXIT_FAILURE);
+    }
+
+#endif /* defined(HAVE_SOCKET) */
 
     /* Library loader options (do not appear in help as they
        are not destined to be used directly by a user) */
 
     else if (strncmp(s, moduleoptbase, strlen(moduleoptbase)) == 0) {
       const char *_s = s + strlen(moduleoptbase);
+#if defined(HAVE_DLOPEN)
       BFT_MALLOC(opts->yacs_module, strlen(_s) + 1, char);
       strcpy(opts->yacs_module, _s);
-    }
-
+#else
+      fprintf(stderr, _("%s was built without dynamic loader support,\n"
+                        "so module file \"%s\" may not be loaded.\n"),
+              argv[0], _s);
+      cs_exit(EXIT_FAILURE);
 #endif /* defined(HAVE_DLOPEN) */
+    }
 
     /* Version number */
 
diff --git a/src/base/cs_post.c b/src/base/cs_post.c
index 6dc54d5..baf2bee 100644
--- a/src/base/cs_post.c
+++ b/src/base/cs_post.c
@@ -755,7 +755,7 @@ _cs_post_write_domain(fvm_writer_t       *writer,
 
   if (sizeof(cs_int_t) == 4)
     datatype = FVM_INT32;
-  else if (sizeof(cs_real_t) == 8)
+  else if (sizeof(cs_int_t) == 8)
     datatype = FVM_INT64;
 
   var_ptr[0] = domain;
diff --git a/src/base/cs_preprocessor_data.c b/src/base/cs_preprocessor_data.c
index 55b70b9..6a95ac1 100644
--- a/src/base/cs_preprocessor_data.c
+++ b/src/base/cs_preprocessor_data.c
@@ -403,11 +403,11 @@ _read_cell_rank(cs_mesh_t       *mesh,
         if (n_g_cells != mesh->n_g_cells)
           bft_error(__FILE__, __LINE__, 0,
                     _("The number of cells reported by file\n"
-                      "\"%s\" (%lu)\n"
-                      "does not correspond the those of the mesh (%lu)."),
+                      "\"%s\" (%llu)\n"
+                      "does not correspond the those of the mesh (%llu)."),
                     cs_io_get_name(rank_pp_in),
-                    (unsigned long)(n_g_cells),
-                    (unsigned long)(mesh->n_g_cells));
+                    (unsigned long long)(n_g_cells),
+                    (unsigned long long)(mesh->n_g_cells));
       }
 
     }
@@ -435,7 +435,7 @@ _read_cell_rank(cs_mesh_t       *mesh,
                      CS_IO_NAME_LEN) == 0) {
 
       n_elts = mesh->n_g_cells;
-      if (header.n_vals != n_elts)
+      if (header.n_vals != (fvm_file_off_t)n_elts)
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name,
                   cs_io_get_name(rank_pp_in));
@@ -455,6 +455,11 @@ _read_cell_rank(cs_mesh_t       *mesh,
       cs_io_finalize(&rank_pp_in);
       rank_pp_in = NULL;
     }
+
+    else
+      bft_error(__FILE__, __LINE__, 0,
+                _("Message of type <%s> on <%s> is unexpected."),
+                header.sec_name, cs_io_get_name(rank_pp_in));
   }
 
   if (rank_pp_in != NULL)
@@ -882,6 +887,8 @@ _extract_face_gc_id(cs_mesh_t        *mesh,
 
   for (i = 0; i < n_faces; i++) {
 
+    assert(face_gc_id[i] > -1 && face_gc_id[i] <= mesh->n_families);
+
     if (face_type[i] == '\0')
       mesh->i_face_family[n_i_faces++] = face_gc_id[i];
 
@@ -2174,6 +2181,18 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
   *nfml = 0;
   *nprfml = 0;
 
+  if (mesh->n_init_perio > 0)
+    *iperio = 1;
+  if (mesh->have_rotation_perio > 0)
+    *iperot = 1;
+
+  /* Periodicities can be added before reading the preprocessor_output and
+     defined as a joining, but we don't want the n_init_perio to be set
+     before reading the preprocessor_output. It will be redefined later, either
+     while reading the preprocessor_output file or in the joining algorithm */
+
+  mesh->n_init_perio = 0;
+
   mr = _mesh_reader_create();
 
   _cs_glob_mesh_reader = mr;
@@ -2225,8 +2244,10 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
       if (dim_read != true || header.n_vals != 1)
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
-      else
+      else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         cs_io_read_global(&header, (void *) &(mesh->dim), pp_in);
+      }
 
     }
     else if (strncmp(header.sec_name, "n_cells",
@@ -2282,8 +2303,10 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
       if (dim_read != true || header.n_vals != 1)
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
-      else
+      else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         cs_io_read_global(&header, (void *) &(mesh->n_families), pp_in);
+      }
 
     }
     else if (strncmp(header.sec_name, "n_group_class_props_max",
@@ -2292,9 +2315,11 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
       if (dim_read != true || header.n_vals != 1)
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
-      else
+      else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         cs_io_read_global(&header,
                           (void *) &(mesh->n_max_family_items), pp_in);
+      }
 
     }
     else if (strncmp(header.sec_name, "n_groups",
@@ -2303,8 +2328,10 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
       if (dim_read != true || header.n_vals != 1)
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
-      else
+      else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         cs_io_read_global(&header, (void *) &(mesh->n_groups), pp_in);
+      }
 
     }
     else if (strncmp(header.sec_name, "group_name_index",
@@ -2314,6 +2341,7 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
       else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         BFT_MALLOC(mesh->group_idx, mesh->n_groups + 1, cs_int_t);
         cs_io_read_global(&header, (void *) mesh->group_idx, pp_in);
       }
@@ -2342,6 +2370,7 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
       else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         BFT_MALLOC(mesh->family_item, n_elts, cs_int_t);
         cs_io_read_global(&header, (void *) mesh->family_item, pp_in);
       }
@@ -2359,6 +2388,7 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
       else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         cs_io_read_global(&header, (void *) &(mesh->n_init_perio), pp_in);
 
         assert(mesh->n_init_perio > 0);
@@ -2389,6 +2419,7 @@ CS_PROCF(ledevi, LEDEVI)(cs_int_t   *ndim,
         bft_error(__FILE__, __LINE__, 0,
                   _(unexpected_msg), header.sec_name, cs_io_get_name(pp_in));
       else {
+        cs_io_set_fvm_lnum(&header, pp_in);
         cs_io_read_global(&header, (void *) iperot, pp_in);
         if (*iperot > 0)
           mesh->have_rotation_perio = 1;
diff --git a/src/base/cs_restart.c b/src/base/cs_restart.c
index 6ea7aaa..b084507 100644
--- a/src/base/cs_restart.c
+++ b/src/base/cs_restart.c
@@ -1370,11 +1370,11 @@ cs_restart_check_base_location(const cs_restart_t  *restart,
     else if (cs_glob_rank_id <= 0) {
       cs_base_warn(__FILE__, __LINE__);
       bft_printf(_("The size of location \"%s\" associated with\n"
-                   "the restart file \"%s\" is %lu and does not\n"
-                   "correspond to that of the current mesh (%lu).\n"),
+                   "the restart file \"%s\" is %llu and does not\n"
+                   "correspond to that of the current mesh (%llu).\n"),
                  loc->name, restart->name,
-                 (unsigned long)loc->n_glob_ents_f,
-                 (unsigned long)loc->n_glob_ents);
+                 (unsigned long long)loc->n_glob_ents_f,
+                 (unsigned long long)loc->n_glob_ents);
     }
 
   }
@@ -1491,8 +1491,9 @@ cs_restart_dump_index(const cs_restart_t  *restart)
   for (loc_id = 0; loc_id < restart->n_locations; loc_id++) {
     const _location_t *loc = &(restart->location[loc_id]);
     bft_printf(_("  Location: %s\n"
-                 "    (number: %03d, n_glob_ents: %lu)\n"),
-               loc->name, (int)(loc->id), (unsigned long)(loc->n_glob_ents));
+                 "    (number: %03d, n_glob_ents: %llu)\n"),
+               loc->name, (int)(loc->id),
+               (unsigned long long)(loc->n_glob_ents));
   }
   if (restart->n_locations > 0)
     bft_printf("\n");
@@ -1564,11 +1565,12 @@ cs_restart_read_section(cs_restart_t  *restart,
     }
     n_glob_ents = (restart->location[location_id-1]).n_glob_ents;
     if ((restart->location[location_id-1]).n_glob_ents_f != n_glob_ents) {
-      bft_printf(_("  %s: location id %d for \"%s\" has "
-                   "size %lu, but %lu is expected.\n"),
-                 restart->name, location_id, sec_name,
-                 (unsigned long)(restart->location[location_id-1]).n_glob_ents_f,
-                 (unsigned long)n_glob_ents);
+      bft_printf
+        (_("  %s: location id %d for \"%s\" has "
+           "size %llu, but %llu is expected.\n"),
+         restart->name, location_id, sec_name,
+         (unsigned long long)(restart->location[location_id-1]).n_glob_ents_f,
+         (unsigned long long)n_glob_ents);
       return CS_RESTART_ERR_LOCATION;
     }
     n_ents  = (restart->location[location_id-1]).n_ents;
diff --git a/src/base/cs_sat_coupling.c b/src/base/cs_sat_coupling.c
index 40cc965..6f81efc 100644
--- a/src/base/cs_sat_coupling.c
+++ b/src/base/cs_sat_coupling.c
@@ -995,13 +995,14 @@ void CS_PROCF (defloc, DEFLOC)
 )
 {
   cs_int_t  ind;
-  cs_int_t  nbr_fbr_cpl, nbr_cel_cpl;
+  cs_int_t  nbr_fbr_cpl = 0, nbr_cel_cpl = 0;
 
   int  indic_glob[2] = {0, 0};
   int  indic_loc[2] = {0, 0};
 
   char coupled_mesh_name[64];
-  fvm_lnum_t *elt_list = NULL;
+  fvm_lnum_t *c_elt_list = NULL;
+  fvm_lnum_t *f_elt_list = NULL;
   cs_sat_coupling_t  *coupl = NULL;
   fvm_nodal_t  *support_fbr = NULL;
   cs_mesh_quantities_t  *mesh_quantities = cs_glob_mesh_quantities;
@@ -1027,41 +1028,21 @@ void CS_PROCF (defloc, DEFLOC)
 
   if (coupl->cell_sup_sel != NULL) {
 
-    sprintf(coupled_mesh_name, _("coupled_cells_%d"), *numcpl);
-
-    BFT_MALLOC(elt_list, cs_glob_mesh->n_cells, fvm_lnum_t);
+    BFT_MALLOC(c_elt_list, cs_glob_mesh->n_cells, fvm_lnum_t);
 
     cs_selector_get_cell_list(coupl->cell_sup_sel,
                               &(coupl->nbr_cel_sup),
-                              elt_list);
-
-    coupl->cells_sup = cs_mesh_connect_cells_to_nodal(cs_glob_mesh,
-                                                      coupled_mesh_name,
-                                                      coupl->nbr_cel_sup,
-                                                      elt_list);
-
-    BFT_FREE(elt_list);
+                              c_elt_list);
 
   }
 
   if (coupl->face_sup_sel != NULL) {
 
-    sprintf(coupled_mesh_name, _("coupled_faces_%d"), *numcpl);
-
-    BFT_MALLOC(elt_list, cs_glob_mesh->n_b_faces, fvm_lnum_t);
+    BFT_MALLOC(f_elt_list, cs_glob_mesh->n_b_faces, fvm_lnum_t);
 
     cs_selector_get_b_face_list(coupl->face_sup_sel,
                                 &(coupl->nbr_fbr_sup),
-                                elt_list);
-
-    coupl->faces_sup = cs_mesh_connect_faces_to_nodal(cs_glob_mesh,
-                                                      coupled_mesh_name,
-                                                      0,
-                                                      coupl->nbr_fbr_sup,
-                                                      NULL,
-                                                      elt_list);
-
-    BFT_FREE(elt_list);
+                                f_elt_list);
 
   }
 
@@ -1077,6 +1058,33 @@ void CS_PROCF (defloc, DEFLOC)
                    cs_glob_mpi_comm);
 #endif
 
+  if (indic_glob[0] > 0) {
+
+    sprintf(coupled_mesh_name, _("coupled_cells_%d"), *numcpl);
+
+    coupl->cells_sup = cs_mesh_connect_cells_to_nodal(cs_glob_mesh,
+                                                      coupled_mesh_name,
+                                                      coupl->nbr_cel_sup,
+                                                      c_elt_list);
+
+  }
+
+  if (indic_glob[1] > 0) {
+
+    sprintf(coupled_mesh_name, _("coupled_faces_%d"), *numcpl);
+
+    coupl->faces_sup = cs_mesh_connect_faces_to_nodal(cs_glob_mesh,
+                                                      coupled_mesh_name,
+                                                      0,
+                                                      coupl->nbr_fbr_sup,
+                                                      NULL,
+                                                      f_elt_list);
+
+  }
+
+  if (coupl->cell_sup_sel != NULL) BFT_FREE(c_elt_list);
+  if (coupl->face_sup_sel != NULL) BFT_FREE(f_elt_list);
+
   /* Build and initialize associated locator */
 
 #if defined(FVM_HAVE_MPI)
@@ -1102,49 +1110,50 @@ void CS_PROCF (defloc, DEFLOC)
 
   if (coupl->cell_cpl_sel != NULL) {
 
-    BFT_MALLOC(elt_list, cs_glob_mesh->n_cells, fvm_lnum_t);
+    BFT_MALLOC(c_elt_list, cs_glob_mesh->n_cells, fvm_lnum_t);
 
     cs_selector_get_cell_list(coupl->cell_cpl_sel,
                               &nbr_cel_cpl,
-                              elt_list);
+                              c_elt_list);
 
-    fvm_locator_set_nodal(coupl->localis_cel,
-                          coupl->cells_sup,
-                          1,
-                          3,
-                          nbr_cel_cpl,
-                          elt_list,
-                          mesh_quantities->cell_cen);
+  }
 
-    BFT_FREE(elt_list);
+  fvm_locator_set_nodal(coupl->localis_cel,
+                        coupl->cells_sup,
+                        1,
+                        3,
+                        nbr_cel_cpl,
+                        c_elt_list,
+                        mesh_quantities->cell_cen);
 
-  }
+  if (coupl->cell_cpl_sel != NULL) BFT_FREE(c_elt_list);
 
 
   if (coupl->face_cpl_sel != NULL) {
 
-    if (indic_glob[1] > 0)
-      support_fbr = coupl->faces_sup;
-    else
-      support_fbr = coupl->cells_sup;
-
-    BFT_MALLOC(elt_list, cs_glob_mesh->n_b_faces, fvm_lnum_t);
+    BFT_MALLOC(f_elt_list, cs_glob_mesh->n_b_faces, fvm_lnum_t);
 
     cs_selector_get_b_face_list(coupl->face_cpl_sel,
                                 &nbr_fbr_cpl,
-                                elt_list);
+                                f_elt_list);
 
-    fvm_locator_set_nodal(coupl->localis_fbr,
-                          support_fbr,
-                          1,
-                          3,
-                          nbr_fbr_cpl,
-                          elt_list,
-                          mesh_quantities->b_face_cog);
+  }
 
-    BFT_FREE(elt_list);
+  if (indic_glob[1] > 0)
+    support_fbr = coupl->faces_sup;
+  else
+    support_fbr = coupl->cells_sup;
+
+  fvm_locator_set_nodal(coupl->localis_fbr,
+                        support_fbr,
+                        1,
+                        3,
+                        nbr_fbr_cpl,
+                        f_elt_list,
+                        mesh_quantities->b_face_cog);
+
+  if (coupl->face_cpl_sel != NULL) BFT_FREE(f_elt_list);
 
-  }
 
   /* Computed some quantities needed for a centred-like interpolation */
 
diff --git a/src/base/cs_syr4_coupling.c b/src/base/cs_syr4_coupling.c
index 80e3205..0d5438b 100644
--- a/src/base/cs_syr4_coupling.c
+++ b/src/base/cs_syr4_coupling.c
@@ -452,8 +452,8 @@ _create_coupled_ent(cs_syr4_coupling_t  *syr_coupling,
   if (syr_coupling->verbosity > 0) {
     fvm_gnum_t n_g_elts = coupling_ent->n_elts;
     fvm_parall_counter(&n_g_elts, 1);
-    bft_printf(_("\nExtracted mesh built of %lu elements.\n"),
-               (unsigned long)n_g_elts);
+    bft_printf(_("\nExtracted mesh built of %llu elements.\n"),
+               (unsigned long long)n_g_elts);
   }
 
   /* Build and initialize associated locator */
@@ -504,9 +504,9 @@ _create_coupled_ent(cs_syr4_coupling_t  *syr_coupling,
   if (n_exterior)
     bft_error(__FILE__, __LINE__, 0,
               _("Coupling with SYRTHES impossible:\n"
-                "%lu element centers from mesh \"%s\"\n"
+                "%llu element centers from mesh \"%s\"\n"
                 "not located on SYRTHES mesh."),
-              (unsigned long)n_exterior, coupled_mesh_name);
+              (unsigned long long)n_exterior, coupled_mesh_name);
 
   if (location_elts != coupling_ent->elts)
     fvm_nodal_destroy(location_elts);
diff --git a/src/base/csc2cl.f90 b/src/base/csc2cl.f90
index cfeb714..bf6fdb9 100644
--- a/src/base/csc2cl.f90
+++ b/src/base/csc2cl.f90
@@ -402,15 +402,15 @@ do ivar = 1, nvcp
 
 ! -- DECENTRE (SOLU ou UPWIND)
 
-        if(flumab.ge.0.d0) then
-          rcodcl(ifac,ivar,1) = xip
-        else
-          rcodcl(ifac,ivar,1) = xjp
-        endif
+!        if(flumab.ge.0.d0) then
+!          rcodcl(ifac,ivar,1) = xip
+!        else
+!          rcodcl(ifac,ivar,1) = xjp
+!        endif
 
 ! -- CENTRE
 
-!        rcodcl(ifac,ivar,1) = (1.d0-pondj)*xjp + pondj*xip
+        rcodcl(ifac,ivar,1) = (1.d0-pondj)*xjp + pondj*xip
 
       endif
 
diff --git a/src/base/csc2ts.f90 b/src/base/csc2ts.f90
index db035bd..a5b78f5 100644
--- a/src/base/csc2ts.f90
+++ b/src/base/csc2ts.f90
@@ -183,7 +183,7 @@ double precision rvcpce(ncecpl)
 ! Local variables
 
 integer          idebia , idebra , ifinia , ifinra
-integer          iel
+integer          iel    , ipcrom
 integer          ipt    , ielloc
 double precision xdis   , xloc   , xtau
 
@@ -192,6 +192,8 @@ double precision xdis   , xloc   , xtau
 idebia = idbia0
 idebra = idbra0
 
+ipcrom = ipproc(irom(iphas))
+
 xtau = 100.d0*dtref
 
 do ipt = 1, ncecpl
@@ -201,8 +203,8 @@ do ipt = 1, ncecpl
   xdis = rvcpce(ipt)
   xloc = rtpa(ielloc,ivar)
 
-  crvexp(ielloc) = crvexp(ielloc)                                 &
-                 + volume(ielloc)*(xdis-xloc)/xtau
+  crvexp(ielloc) = crvexp(ielloc) &
+                 + volume(ielloc)*propce(ielloc,ipcrom)*(xdis-xloc)/xtau
 
 enddo
 
diff --git a/src/base/cscini.f90 b/src/base/cscini.f90
index 6e37ef4..c122498 100644
--- a/src/base/cscini.f90
+++ b/src/base/cscini.f90
@@ -115,22 +115,27 @@ idebra = idbra0
 
 do numcpl = 1, nbrcpl
 
-!       L'interpolation face/face doit �tre d�finie pour tous les couplages
-!       de mani�re identique.
+  ! L'interpolation face/face doit �tre d�finie pour tous les couplages
+  ! de mani�re identique.
 
   call mxicpl(numcpl, ifaccp, ifcpmx)
   !==========
 
   ifaccp = ifcpmx
 
-!       Si l'un des maillages est mobiles,
-!       on doit mettre � jour la localisation.
+  ! On v�rifie si l'une des instances est en r�solution en rep�re relatif
+
+  call mxicpl(numcpl, icorio, icormx(numcpl))
+  !==========
+
+  ! Si l'un des maillages est mobiles,
+  ! on doit mettre � jour la localisation.
 
   call mxicpl(numcpl, imobil, imobmx)
   !==========
 
-!       De la m�me mani�re, si l'on a une approche ALE sur l'un des
-!       maillages, on doit mettre � jour la localisation.
+  ! De la m�me mani�re, si l'on a une approche ALE sur l'un des
+  ! maillages, on doit mettre � jour la localisation.
 
   call mxicpl(numcpl, iale  , ialemx)
   !==========
@@ -141,11 +146,11 @@ do numcpl = 1, nbrcpl
     imajcp(numcpl) = 0
   endif
 
-!       D�termination du nombre de variables coupl�es entre les deux
-!       instances du couplage NUMCPL. Toutes les variables d'une instance
-!       sont coupl�es, SAUF dans le cas de l'ALE o� la vitesse de maillage
-!       ne sera pas coupl�e.
-!       Il faudrait faire quelque en revanche pour les physiques particuli�res.
+  ! D�termination du nombre de variables coupl�es entre les deux
+  ! instances du couplage NUMCPL. Toutes les variables d'une instance
+  ! sont coupl�es, SAUF dans le cas de l'ALE o� la vitesse de maillage
+  ! ne sera pas coupl�e.
+  ! Il faudrait faire quelque en revanche pour les physiques particuli�res.
 
   if (iale.eq.0) then
     nvarcp(numcpl) = nvar
@@ -153,18 +158,18 @@ do numcpl = 1, nbrcpl
     nvarcp(numcpl) = nvar - 3
   endif
 
-!       Nombre total de variable envoy�es: max des variables de chaque
-!       ex�cutable
+  ! Nombre total de variable envoy�es: max des variables de chaque
+  ! ex�cutable
 
   call mxicpl(numcpl, nvarcp(numcpl), nvcpmx)
   !==========
 
   nvarto(numcpl) = nvcpmx
 
-!       Coh�rence des mod�les de turbulence entre chaque instance de CS ;
-!       pour l'instant, on ne traite que les cas de couplage entre
-!       modeles RANS et laminaires, sauf pour le modele v2f (dans ce cas
-!       il n'y a que du couplage mono-modele)
+  ! Coh�rence des mod�les de turbulence entre chaque instance de CS ;
+  ! pour l'instant, on ne traite que les cas de couplage entre
+  ! modeles RANS et laminaires, sauf pour le modele v2f (dans ce cas
+  ! il n'y a que du couplage mono-modele)
 
   do iphas = 1, nphas
 
diff --git a/src/base/cscpfb.f90 b/src/base/cscpfb.f90
index 5969a06..defa92f 100644
--- a/src/base/cscpfb.f90
+++ b/src/base/cscpfb.f90
@@ -141,7 +141,6 @@ integer          inc    , iccocg , iphydp , iclvar, nswrgp
 integer          iwarnp , imligp , idimte , itenso
 integer          ipos
 integer          itytu0
-integer          icormx
 
 double precision epsrgp , climgp , extrap
 double precision xjjp   , yjjp   , zjjp
@@ -178,23 +177,24 @@ d2s3 = 2.d0/3.d0
 iphas = 1
 ipcrom = ipproc(irom(iphas))
 
-! On v�rifie si l'une des instances est en r�solution en rep�re relatif
-call mxicpl(numcpl,icorio,icormx)
+if (icormx(numcpl).eq.1) then
 
-! On r�cup�re dans tous les cas le vecteur rotation de l'autre instance
-omegal(1) = omegax
-omegal(2) = omegay
-omegal(3) = omegaz
-call tbrcpl(numcpl,3,3,omegal,omegad)
+  ! On r�cup�re dans tous les cas le vecteur rotation de l'autre instance
+  omegal(1) = omegax
+  omegal(2) = omegay
+  omegal(3) = omegaz
+  call tbrcpl(numcpl,3,3,omegal,omegad)
 
-! Vecteur vitesse relatif d'une instance a l'autre
-omegar(1) = omegal(1) - omegad(1)
-omegar(2) = omegal(2) - omegad(2)
-omegar(3) = omegal(3) - omegad(3)
+  ! Vecteur vitesse relatif d'une instance a l'autre
+  omegar(1) = omegal(1) - omegad(1)
+  omegar(2) = omegal(2) - omegad(2)
+  omegar(3) = omegal(3) - omegad(3)
 
-omgnrl = sqrt(omegal(1)**2 + omegal(2)**2 + omegal(3)**2)
-omgnrd = sqrt(omegad(1)**2 + omegad(2)**2 + omegad(3)**2)
-omgnrr = sqrt(omegar(1)**2 + omegar(2)**2 + omegar(3)**2)
+  omgnrl = sqrt(omegal(1)**2 + omegal(2)**2 + omegal(3)**2)
+  omgnrd = sqrt(omegad(1)**2 + omegad(2)**2 + omegad(3)**2)
+  omgnrr = sqrt(omegar(1)**2 + omegar(2)**2 + omegar(3)**2)
+
+endif
 
 ! On part du principe que l'on envoie les bonnes variables �
 ! l'instance distante et uniquement celles-l�.
@@ -295,7 +295,7 @@ do iphas = 1, nphas
           + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
 
         ! On prend en compte le potentiel centrifuge en rep�re relatif
-        if (icormx.eq.1) then
+        if (icormx(numcpl).eq.1) then
 
           ! Calcul de la distance a l'axe de rotation
           ! On suppose que les axes sont confondus...
@@ -433,9 +433,9 @@ do iphas = 1, nphas
 
 ! -- UPWIND
 
-!        xjpf = coopts(1,ipt) - xyzcen(1,iel)- djppts(1,ipt)
-!        yjpf = coopts(2,ipt) - xyzcen(2,iel)- djppts(2,ipt)
-!        zjpf = coopts(3,ipt) - xyzcen(3,iel)- djppts(3,ipt)
+!        xjjp = djppts(1,ipt)
+!        yjjp = djppts(2,ipt)
+!        zjjp = djppts(3,ipt)
 
 !        rvdis(ipt,ipos) = rtp(iel,ivar)
 
@@ -458,17 +458,17 @@ do iphas = 1, nphas
           + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
 
         ! On prend en compte la vitesse d'entrainement en rep�re relatif
-        if (icormx.eq.1) then
+        if (icormx(numcpl).eq.1) then
 
           if (isou.eq.1) then
-            vitent =   (omegal(2)-omegad(2))*(xyzcen(3,iel)-zjjp) &
-                     - (omegal(3)-omegad(3))*(xyzcen(2,iel)-yjjp)
+            vitent =   omegar(2)*(xyzcen(3,iel)+zjjp) &
+                     - omegar(3)*(xyzcen(2,iel)+yjjp)
           elseif (isou.eq.2) then
-            vitent =   (omegal(3)-omegad(3))*(xyzcen(1,iel)-xjjp) &
-                     - (omegal(1)-omegad(1))*(xyzcen(3,iel)-zjjp)
+            vitent =   omegar(3)*(xyzcen(1,iel)+xjjp) &
+                     - omegar(1)*(xyzcen(3,iel)+zjjp)
           elseif (isou.eq.3) then
-            vitent =   (omegal(1)-omegad(1))*(xyzcen(2,iel)-yjjp) &
-                     - (omegal(2)-omegad(2))*(xyzcen(1,iel)-xjjp)
+            vitent =   omegar(1)*(xyzcen(2,iel)+yjjp) &
+                     - omegar(2)*(xyzcen(1,iel)+xjjp)
           endif
 
           rvdis(ipt,ipos) = rvdis(ipt,ipos) + vitent
@@ -669,7 +669,8 @@ do iphas = 1, nphas
         yjjp = djppts(2,ipt)
         zjjp = djppts(3,ipt)
 
-        ra(itrav2 + ipt-1) = rtp(iel,iepiph)
+        ra(itrav2 + ipt-1) = rtp(iel,iepiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
 
       enddo
 
@@ -965,18 +966,41 @@ do iphas = 1, nphas
       if (isou.eq.5) itrav = itrav5
       if (isou.eq.6) itrav = itrav6
 
-      do ipt = 1, nptdis
+      ! For a specific face to face coupling, geometric assumptions are made
 
-        iel = locpts(ipt)
+      if (ifaccp.eq.1) then
 
-        xjjp = djppts(1,ipt)
-        yjjp = djppts(2,ipt)
-        zjjp = djppts(3,ipt)
+        do ipt = 1, nptdis
 
-        ra(itrav + ipt-1) = rtp(iel,ivar)                         &
-          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+          iel = locpts(ipt)
 
-      enddo
+          xjjp = djppts(1,ipt)
+          yjjp = djppts(2,ipt)
+          zjjp = djppts(3,ipt)
+
+          ra(itrav + ipt-1) = rtp(iel,ivar)                         &
+            + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+        enddo
+
+      ! For a generic coupling, no assumption can be made
+
+      else
+
+        do ipt = 1, nptdis
+
+          iel = locpts(ipt)
+
+          xjjp = djppts(1,ipt)
+          yjjp = djppts(2,ipt)
+          zjjp = djppts(3,ipt)
+
+          ra(itrav + ipt-1) = rtp(iel,ivar)                         &
+            + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+        enddo
+
+      endif
 
     enddo
 
@@ -1032,18 +1056,41 @@ do iphas = 1, nphas
     rdevel , rtuser , ra     )
 
 
-    do ipt = 1, nptdis
+    ! For a specific face to face coupling, geometric assumptions are made
 
-      iel = locpts(ipt)
+    if (ifaccp.eq.1) then
 
-      xjjp = djppts(1,ipt)
-      yjjp = djppts(2,ipt)
-      zjjp = djppts(3,ipt)
+      do ipt = 1, nptdis
 
-      ra(itrav7 + ipt-1) = rtp(iel,iepiph)                        &
-        + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+        iel = locpts(ipt)
 
-    enddo
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav7 + ipt-1) = rtp(iel,iepiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    ! For a generic coupling, no assumption can be made
+
+    else
+
+      do ipt = 1, nptdis
+
+        iel = locpts(ipt)
+
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav7 + ipt-1) = rtp(iel,iepiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+   endif
 
 !=======================================================================
 !          3.2.2. Transfert de variable � "iso-mod�le"
@@ -1201,19 +1248,41 @@ do iphas = 1, nphas
     rdevel , rtuser , ra     )
 
 
-    do ipt = 1, nptdis
+    ! For a specific face to face coupling, geometric assumptions are made
 
-      iel = locpts(ipt)
+    if (ifaccp.eq.1) then
 
-      xjjp = djppts(1,ipt)
-      yjjp = djppts(2,ipt)
-      zjjp = djppts(3,ipt)
+      do ipt = 1, nptdis
 
-      ra(itrav1 + ipt-1) = rtp(iel,ikiph)                         &
-        + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+        iel = locpts(ipt)
+
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
 
+        ra(itrav1 + ipt-1) = rtp(iel,ikiph)                         &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
 
-    enddo
+      enddo
+
+    ! For a generic coupling, no assumption can be made
+
+    else
+
+      do ipt = 1, nptdis
+
+        iel = locpts(ipt)
+
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav1 + ipt-1) = rtp(iel,ikiph)                         &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+   endif
 
 !         Pr�paration des donn�es: interpolation de epsilon en J'
 
@@ -1267,18 +1336,41 @@ do iphas = 1, nphas
     rdevel , rtuser , ra     )
 
 
-    do ipt = 1, nptdis
+    ! For a specific face to face coupling, geometric assumptions are made
 
-      iel = locpts(ipt)
+    if (ifaccp.eq.1) then
 
-      xjjp = djppts(1,ipt)
-      yjjp = djppts(2,ipt)
-      zjjp = djppts(3,ipt)
+      do ipt = 1, nptdis
 
-      ra(itrav2 + ipt-1) = rtp(iel,iepiph)                        &
-        + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+        iel = locpts(ipt)
 
-    enddo
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav2 + ipt-1) = rtp(iel,iepiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    ! For a generic coupling, no assumption can be made
+
+    else
+
+      do ipt = 1, nptdis
+
+        iel = locpts(ipt)
+
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav2 + ipt-1) = rtp(iel,iepiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    endif
 
 !         Pr�paration des donn�es: interpolation de Phi en J'
 
@@ -1397,18 +1489,41 @@ do iphas = 1, nphas
     rdevel , rtuser , ra     )
 
 
-    do ipt = 1, nptdis
+    ! For a specific face to face coupling, geometric assumptions are made
 
-      iel = locpts(ipt)
+    if (ifaccp.eq.1) then
 
-      xjjp = djppts(1,ipt)
-      yjjp = djppts(2,ipt)
-      zjjp = djppts(3,ipt)
+      do ipt = 1, nptdis
 
-      ra(itrav4 + ipt-1) = rtp(iel,ifbiph)                        &
-        + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+        iel = locpts(ipt)
 
-    enddo
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav4 + ipt-1) = rtp(iel,ifbiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    ! For a generic coupling, no assumption can be made
+
+    else
+
+      do ipt = 1, nptdis
+
+        iel = locpts(ipt)
+
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav4 + ipt-1) = rtp(iel,ifbiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    endif
 
 !=======================================================================
 !          3.3.2. Transfert de variable � "iso-mod�le"
@@ -1522,18 +1637,41 @@ do iphas = 1, nphas
     rdevel , rtuser , ra     )
 
 
-    do ipt = 1, nptdis
+    ! For a specific face to face coupling, geometric assumptions are made
 
-      iel = locpts(ipt)
+    if (ifaccp.eq.1) then
 
-      xjjp = djppts(1,ipt)
-      yjjp = djppts(2,ipt)
-      zjjp = djppts(3,ipt)
+      do ipt = 1, nptdis
 
-      ra(itrav1 + ipt-1) = rtp(iel,ikiph)                         &
-        + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+        iel = locpts(ipt)
 
-    enddo
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav1 + ipt-1) = rtp(iel,ikiph)                         &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    ! For a generic coupling, no assumption can be made
+
+    else
+
+      do ipt = 1, nptdis
+
+        iel = locpts(ipt)
+
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav1 + ipt-1) = rtp(iel,ikiph)                         &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    endif
 
 !         Pr�paration des donn�es: interpolation de omega en J'
 
@@ -1586,18 +1724,41 @@ do iphas = 1, nphas
     w4     , w5     , w6     ,                                    &
     rdevel , rtuser , ra     )
 
-    do ipt = 1, nptdis
+    ! For a specific face to face coupling, geometric assumptions are made
 
-      iel = locpts(ipt)
+    if (ifaccp.eq.1) then
 
-      xjjp = djppts(1,ipt)
-      yjjp = djppts(2,ipt)
-      zjjp = djppts(3,ipt)
+      do ipt = 1, nptdis
 
-      ra(itrav2 + ipt-1) = rtp(iel,iomiph)                        &
-        + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+        iel = locpts(ipt)
 
-    enddo
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav2 + ipt-1) = rtp(iel,iomiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    ! For a generic coupling, no assumption can be made
+
+    else
+
+      do ipt = 1, nptdis
+
+        iel = locpts(ipt)
+
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
+
+        ra(itrav2 + ipt-1) = rtp(iel,iomiph)                        &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+
+      enddo
+
+    endif
 
 !=======================================================================
 !          3.4.2. Transfert de variable � "iso-mod�le"
@@ -1860,7 +2021,7 @@ if (nscal.gt.0) then
 
 ! -- UPWIND
 
-        rvdis(ipt,ipos) = rtp(iel,ivar)
+!        rvdis(ipt,ipos) = rtp(iel,ivar)
 
 ! -- SOLU
 
@@ -1873,12 +2034,12 @@ if (nscal.gt.0) then
 
 ! -- CENTRE
 
-!        xjjp = djppts(1,ipt)
-!        yjjp = djppts(2,ipt)
-!        zjjp = djppts(3,ipt)
+        xjjp = djppts(1,ipt)
+        yjjp = djppts(2,ipt)
+        zjjp = djppts(3,ipt)
 
-!        rvdis(ipt,ipos) = rtp(iel,ivar) &
-!          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
+        rvdis(ipt,ipos) = rtp(iel,ivar) &
+          + xjjp*w1(iel) + yjjp*w2(iel) + zjjp*w3(iel)
 
       enddo
 
diff --git a/src/base/iniini.f90 b/src/base/iniini.f90
index 61a14fa..c52678b 100644
--- a/src/base/iniini.f90
+++ b/src/base/iniini.f90
@@ -1361,7 +1361,7 @@ cv2fet = 110.d0
 
 !   pour le modele k-omega sst
 ckwsk1 = 1.d0/0.85d0
-ckwsk2 = 2.d0
+ckwsk2 = 1.d0
 ckwsw1 = 2.d0
 ckwsw2 = 1.d0/0.856d0
 ckwbt1 = 0.075d0
diff --git a/src/base/memdis.f90 b/src/base/memdis.f90
index f565d5a..99dd1e9 100644
--- a/src/base/memdis.f90
+++ b/src/base/memdis.f90
@@ -124,6 +124,8 @@ idebra = idbra0
 
 !---> PLACE MEMOIRE RESERVEE AVEC DEFINITION DE IFINIA IFINRA
 
+ifinia =       idebia
+
 iviscf =       idebra
 iviscb =       iviscf + nfac
 idam   =       iviscb + nfabor
diff --git a/src/base/memdyp.f90 b/src/base/memdyp.f90
index 07fabcc..20e86f4 100644
--- a/src/base/memdyp.f90
+++ b/src/base/memdyp.f90
@@ -136,6 +136,8 @@ idebra = idbra0
 
 !---> PLACE MEMOIRE RESERVEE AVEC DEFINITION DE IFINIA IFINRA
 
+ifinia =       idebia
+
 idam   =       idebra
 ixam   =       idam   + ncelet
 ismbr  =       ixam   + nfac*2
diff --git a/src/base/modini.f90 b/src/base/modini.f90
index d035ee2..4488093 100644
--- a/src/base/modini.f90
+++ b/src/base/modini.f90
@@ -1140,14 +1140,14 @@ else
     if ( ikecou(iphas).eq.0) then
       if (itytur(iphas).eq.2 .or. itytur(iphas).eq.5) then
         if (abs(relaxv(ik(iphas))+999.d0).lt.epzero)              &
-             relaxv(ik(iphas)) = 1.d0
+             relaxv(ik(iphas)) = 0.7d0
         if (abs(relaxv(iep(iphas))+999.d0).lt.epzero)             &
-             relaxv(iep(iphas)) = 1.d0
+             relaxv(iep(iphas)) = 0.7d0
       else if (itytur(iphas).eq.6) then
         if (abs(relaxv(ik(iphas))+999.d0).lt.epzero)              &
-             relaxv(ik(iphas)) = 1.d0
+             relaxv(ik(iphas)) = 0.7d0
         if (abs(relaxv(iomg(iphas))+999.d0).lt.epzero)            &
-             relaxv(iomg(iphas)) = 1.d0
+             relaxv(iomg(iphas)) = 0.7d0
       endif
     endif
     if (abs(relaxv(ipr(iphas))+999.d0).lt.epzero)                 &
diff --git a/src/base/navsto.f90 b/src/base/navsto.f90
index e9b1bd2..0c16822 100644
--- a/src/base/navsto.f90
+++ b/src/base/navsto.f90
@@ -582,44 +582,44 @@ if( iprco.le.0 ) then
     enddo
   endif
 
-  return
+  ! Ajout de la vitesse du solide dans le flux convectif,
+  ! si le maillage est mobile (solide rigide)
+  ! En turbomachine, on conna�t exactement la vitesse de maillage � ajouter
+  if (imobil.eq.1) then
 
-endif
+    do iphas = 1, nphas
 
-! Ajout de la vitesse du solide dans le flux convectif,
-! si le maillage est mobile (solide rigide)
-! En turbomachine, on conna�t exactement la vitesse de maillage � ajouter
-if (imobil.eq.1) then
+      iflmas = ipprof(ifluma(iu(iphas)))
+      iflmab = ipprob(ifluma(iu(iphas)))
+      ipcrom = ipproc(irom  (iphas))
+      ipbrom = ipprob(irom  (iphas))
 
-  do iphas = 1, nphas
+      do ifac = 1, nfac
+        iel1 = ifacel(1,ifac)
+        iel2 = ifacel(2,ifac)
+        dtfac  = 0.5d0*(dt(iel1) + dt(iel2))
+        rhofac = 0.5d0*(propce(iel1,ipcrom) + propce(iel2,ipcrom))
+        vitbox = omegay*cdgfac(3,ifac) - omegaz*cdgfac(2,ifac)
+        vitboy = omegaz*cdgfac(1,ifac) - omegax*cdgfac(3,ifac)
+        vitboz = omegax*cdgfac(2,ifac) - omegay*cdgfac(1,ifac)
+        propfa(ifac,iflmas) = propfa(ifac,iflmas) - rhofac*(        &
+      vitbox*surfac(1,ifac) + vitboy*surfac(2,ifac) + vitboz*surfac(3,ifac) )
+      enddo
+      do ifac = 1, nfabor
+        iel = ifabor(ifac)
+        dtfac  = dt(iel)
+        rhofac = propfb(ifac,ipbrom)
+        vitbox = omegay*cdgfbo(3,ifac) - omegaz*cdgfbo(2,ifac)
+        vitboy = omegaz*cdgfbo(1,ifac) - omegax*cdgfbo(3,ifac)
+        vitboz = omegax*cdgfbo(2,ifac) - omegay*cdgfbo(1,ifac)
+        propfb(ifac,iflmab) = propfb(ifac,iflmab) - rhofac*(        &
+      vitbox*surfbo(1,ifac) + vitboy*surfbo(2,ifac) + vitboz*surfbo(3,ifac) )
+      enddo
+    enddo
 
-    iflmas = ipprof(ifluma(iu(iphas)))
-    iflmab = ipprob(ifluma(iu(iphas)))
-    ipcrom = ipproc(irom  (iphas))
-    ipbrom = ipprob(irom  (iphas))
+  endif
 
-    do ifac = 1, nfac
-      iel1 = ifacel(1,ifac)
-      iel2 = ifacel(2,ifac)
-      dtfac  = 0.5d0*(dt(iel1) + dt(iel2))
-      rhofac = 0.5d0*(propce(iel1,ipcrom) + propce(iel2,ipcrom))
-      vitbox = omegay*cdgfac(3,ifac) - omegaz*cdgfac(2,ifac)
-      vitboy = omegaz*cdgfac(1,ifac) - omegax*cdgfac(3,ifac)
-      vitboz = omegax*cdgfac(2,ifac) - omegay*cdgfac(1,ifac)
-      propfa(ifac,iflmas) = propfa(ifac,iflmas) - rhofac*(        &
-        vitbox*surfac(1,ifac) + vitboy*surfac(2,ifac) + vitboz*surfac(3,ifac) )
-    enddo
-    do ifac = 1, nfabor
-      iel = ifabor(ifac)
-      dtfac  = dt(iel)
-      rhofac = propfb(ifac,ipbrom)
-      vitbox = omegay*cdgfbo(3,ifac) - omegaz*cdgfbo(2,ifac)
-      vitboy = omegaz*cdgfbo(1,ifac) - omegax*cdgfbo(3,ifac)
-      vitboz = omegax*cdgfbo(2,ifac) - omegay*cdgfbo(1,ifac)
-      propfb(ifac,iflmab) = propfb(ifac,iflmab) - rhofac*(        &
-        vitbox*surfbo(1,ifac) + vitboy*surfbo(2,ifac) + vitboz*surfbo(3,ifac) )
-    enddo
-  enddo
+  return
 
 endif
 
diff --git a/src/base/resolp.f90 b/src/base/resolp.f90
index 258c2b5..146d6f2 100644
--- a/src/base/resolp.f90
+++ b/src/base/resolp.f90
@@ -1094,7 +1094,7 @@ if (ncesmp.gt.0) then
   enddo
 endif
 
-! ---> Terme sources de masse
+! ---> Termes sources Lagrangien
 if (iilagr.eq.2 .and. ltsmas.eq.1 .and. iphas.eq.ilphas) then
   do iel = 1, ncel
     w7(iel) = w7(iel) -tslagr(iel,itsmas)
diff --git a/src/base/resv2f.f90 b/src/base/resv2f.f90
index 2920f99..1c1157c 100644
--- a/src/base/resv2f.f90
+++ b/src/base/resv2f.f90
@@ -894,6 +894,7 @@ nitmfp = nitmgf(ivar)
 iwarnp = iwarni(ivar)
 blencp = blencv(ivar)
 epsilp = epsilo(ivar)
+epsrsp = epsrsm(ivar)
 epsrgp = epsrgr(ivar)
 climgp = climgr(ivar)
 extrap = extrag(ivar)
diff --git a/src/base/strini.f90 b/src/base/strini.f90
index 21602a8..2320e60 100644
--- a/src/base/strini.f90
+++ b/src/base/strini.f90
@@ -3,7 +3,7 @@
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2009 EDF S.A., France
+!     Copyright (C) 1998-2010 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -355,7 +355,7 @@ if (nbaste.gt.0) then
     if (ia(itrav+inod-1).gt.0) nbnast = nbnast + 1
   enddo
 
-  ilstfa = ifinia
+  ilstfa = ifnia2
   iidflo = ilstfa + nbfast
   iidnlo = iidflo + nbfast
   ifnia2 = iidnlo + nbnast
diff --git a/src/base/testel.f90 b/src/base/testel.f90
index ae41426..b55dc96 100644
--- a/src/base/testel.f90
+++ b/src/base/testel.f90
@@ -3,7 +3,7 @@
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2009 EDF S.A., France
+!     Copyright (C) 1998-2010 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -189,6 +189,12 @@ ifinra = iw3    + ncelet
 CALL RASIZE('TESTEL',IFINRA)
 !==========
 
+! Symmetry type:
+! value 0 avoids extrapolating the gradient on boundary faces.
+do ifac = 1, nfabor
+   ia(iisymp-1+ifac) = 0
+enddo
+
 !===============================================================================
 ! 1. FONCTION ANALYTIQUE SIN(X+2Y+3Z)
 !===============================================================================
@@ -282,9 +288,11 @@ call grdcel                                                       &
 ! On sort le gradient
 
 NAMEVR = 'Grad_RC'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 ! Calcul de l'erreur absolue
 
@@ -300,9 +308,11 @@ enddo
 ! On sort l'erreur
 
 NAMEVR = 'Err_Grad_RC'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 
 !  2.2 APPEL A GRDCEL AVEC IMRGRA = 1
@@ -334,9 +344,11 @@ call grdcel                                                       &
 ! On sort le gradient
 
 NAMEVR = 'Grad_LSQ'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 ! Calcul de l'erreur absolue
 
@@ -352,9 +364,11 @@ enddo
 ! On sort l'erreur
 
 NAMEVR = 'Err_Grad_LSQ'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 
 !  2.3 APPEL A GRDCEL AVEC IMRGRA = 2
@@ -385,9 +399,11 @@ call grdcel                                                       &
 ! On sort le gradient
 
 NAMEVR = 'Grad_LSQ_Ext'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 ! Calcul de l'erreur absolue
 
@@ -403,9 +419,11 @@ enddo
 ! On sort l'erreur
 
 NAMEVR = 'Err_Grad_LSQ_Ext'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 
 !  2.4 APPEL A GRDCEL AVEC IMRGRA = 4
@@ -436,9 +454,11 @@ call grdcel                                                       &
 ! On sort le gradient
 
 NAMEVR = 'Grad_LSQ_RC'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 ! Calcul de l'erreur absolue
 
@@ -454,9 +474,11 @@ enddo
 ! On sort l'erreur
 
 NAMEVR = 'Err_Grad_LSQ_RC'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 
 !  2.5 APPEL A GRDCEL AVEC IMRGRA = 3
@@ -492,9 +514,11 @@ call grdcel                                                       &
 ! On sort le gradient
 
 NAMEVR = 'Grad_LSQ_ExtRed'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 ! Calcul de l'erreur absolue
 
@@ -510,10 +534,11 @@ enddo
 ! On sort l'erreur
 
 NAMEVR = 'Err_Grad_LSQ_ExtRed'
-call psteva(ipart , namevr, idimt, ientla, ivarpr,                &
-!==========
-            ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
-
+if (ichrvl.eq.1) then
+  call psteva(ipart , namevr, idimt, ientla, ivarpr,    &
+  !==========
+              ntcabs, ttcabs, rtp(1,iuiph), rbid, rbid)
+endif
 
 !----
 ! FIN
diff --git a/src/base/tremai.c b/src/base/tremai.c
index c18f04e..8f8f910 100644
--- a/src/base/tremai.c
+++ b/src/base/tremai.c
@@ -43,8 +43,10 @@
 #include <stdio.h>
 #include <errno.h>
 #include <string.h>
-#include <sys/time.h>
+
+#if defined(HAVE_SYS_RESOURCE_H)
 #include <sys/resource.h>
+#endif
 
 /*----------------------------------------------------------------------------
  *  Local headers
@@ -62,7 +64,8 @@ BEGIN_C_DECLS
  *============================================================================*/
 
 /*----------------------------------------------------------------------------
- * Compute remaining time allocated to this process
+ * Compute remaining time allocated to this process when available
+ * (usually, architectures other than IBM Blue Gene or Cray XT)
  *
  * Fortran interface:
  *
@@ -79,20 +82,22 @@ BEGIN_C_DECLS
 void CS_PROCF (tremai, TREMAI) (double  *tps,
                                 int     *ret)
 {
+#if defined(HAVE_SYS_RESOURCE_H)
+
   struct rlimit ressources;
   struct rusage buf_time;
   struct rusage buf_time1;
 
   *tps = 3600.0 * 24.0 * 7; /* "unlimited" values by default */
 
-/* Architectures other than IBM Blue Gene or Cray XT */
-#if   !defined(__blrts__) && !defined(__bgp__) \
-   && !defined(__CRAYXT_COMPUTE_LINUX_TARGET)
-
   if ((*ret = getrusage(RUSAGE_SELF, &buf_time)) < 0)
     fprintf(stderr, "getrusage(RUSAGE_SELF) error:\n%s\n", strerror(errno));
+
+#if !defined(__bg__)
   else if ((*ret = getrusage(RUSAGE_CHILDREN, &buf_time1)) < 0)
     fprintf(stderr, "getrusage(RUSAGE_CHILDREN) error:\n%s\n", strerror(errno));
+#endif
+
   else if ((*ret = getrlimit(RLIMIT_CPU, &ressources)) < 0)
     fprintf(stderr, "getrlimit(RLIMIT_CPU) error:\n%s\n", strerror(errno));
 
@@ -108,13 +113,12 @@ void CS_PROCF (tremai, TREMAI) (double  *tps,
     *ret = 1;
   }
 
-#else /* IBM Blue Gene or Cray XT */
+#else
 
   *ret = -1; /* getrusage(RUSAGE_SELF, ...) and getrlimit(RLIMIT_CPU, ...)
                 not available on this architecture */
 
 #endif
-
 }
 
 /*----------------------------------------------------------------------------*/
diff --git a/src/base/turbke.f90 b/src/base/turbke.f90
index b9fdaed..29f18b1 100644
--- a/src/base/turbke.f90
+++ b/src/base/turbke.f90
@@ -542,7 +542,7 @@ if (igrake(iphas).eq.1 .and. ippmod(iatmos).ge.1) then
 
     call atprke                                                   &
     !==========
- ( idbia0 , idbra0 ,                                              &
+ ( idebia , idebra ,                                              &
    ndim   , ncelet , ncel   , nfac   , nfabor , nfml   , nprfml , &
    nnod   , lndfac , lndfbr , ncelbr ,                            &
    nscal  , nphas  ,                                              &
diff --git a/src/cfbl/Makefile.in b/src/cfbl/Makefile.in
index 2385b2f..d8e497b 100644
--- a/src/cfbl/Makefile.in
+++ b/src/cfbl/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -93,17 +98,32 @@ am_libcscfbl_la_OBJECTS = cfbsc2.lo cfbsc3.lo cfcdts.lo cfdivs.lo \
 	cfvarp.lo cfxtcl.lo memcfe.lo memcfm.lo memcft.lo memcfv.lo \
 	uscfcl.lo uscfpv.lo uscfth.lo uscfx1.lo uscfx2.lo uscfxi.lo
 libcscfbl_la_OBJECTS = $(am_libcscfbl_la_OBJECTS)
-libcscfbl_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcscfbl_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcscfbl_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcscfbl_la_SOURCES)
 DIST_SOURCES = $(libcscfbl_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -136,6 +156,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -159,6 +180,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -210,6 +232,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -266,6 +289,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -303,7 +327,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -413,7 +436,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcscfbl.la: $(libcscfbl_la_OBJECTS) $(libcscfbl_la_DEPENDENCIES) 
-	$(libcscfbl_la_LINK)  $(libcscfbl_la_OBJECTS) $(libcscfbl_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcscfbl_la_LINK)  $(libcscfbl_la_OBJECTS) $(libcscfbl_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -422,31 +445,40 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 uscfcl.lo: $(top_srcdir)/users/cfbl/uscfcl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfcl.lo `test -f '$(top_srcdir)/users/cfbl/uscfcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfcl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfcl.lo `test -f '$(top_srcdir)/users/cfbl/uscfcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfcl.f90
 
 uscfpv.lo: $(top_srcdir)/users/cfbl/uscfpv.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfpv.lo `test -f '$(top_srcdir)/users/cfbl/uscfpv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfpv.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfpv.lo `test -f '$(top_srcdir)/users/cfbl/uscfpv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfpv.f90
 
 uscfth.lo: $(top_srcdir)/users/cfbl/uscfth.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfth.lo `test -f '$(top_srcdir)/users/cfbl/uscfth.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfth.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfth.lo `test -f '$(top_srcdir)/users/cfbl/uscfth.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfth.f90
 
 uscfx1.lo: $(top_srcdir)/users/cfbl/uscfx1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfx1.lo `test -f '$(top_srcdir)/users/cfbl/uscfx1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfx1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfx1.lo `test -f '$(top_srcdir)/users/cfbl/uscfx1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfx1.f90
 
 uscfx2.lo: $(top_srcdir)/users/cfbl/uscfx2.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfx2.lo `test -f '$(top_srcdir)/users/cfbl/uscfx2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfx2.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfx2.lo `test -f '$(top_srcdir)/users/cfbl/uscfx2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfx2.f90
 
 uscfxi.lo: $(top_srcdir)/users/cfbl/uscfxi.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfxi.lo `test -f '$(top_srcdir)/users/cfbl/uscfxi.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfxi.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscfxi.lo `test -f '$(top_srcdir)/users/cfbl/uscfxi.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cfbl/uscfxi.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/cfbl/cfvarp.f90 b/src/cfbl/cfvarp.f90
index 1718376..531f5a1 100644
--- a/src/cfbl/cfvarp.f90
+++ b/src/cfbl/cfvarp.f90
@@ -144,12 +144,12 @@ if ( ippmod(icompf).ge.0 ) then
    ii , ii , ii , ii ,                                            &
    iit , iit , iit , iit , iit ,                                  &
    iit , iit , iit , iit ,                                        &
-   iit , iit , iit , iit ,                                        &
+   iit , iit , iit ,                                              &
    dblpre , dblpre , dblpre , dblpre , dblpre , dblpre , dblpre , &
    dblpre , dblpre , dblpre , dblpre , dblpre , dblpre ,          &
    dblpre , dblpre ,                                              &
    dblpre , dblpre , dblpre , dblpre ,                            &
-   dblpre , dblpre , dblpre , dblpre )
+   dblpre , dblpre , dblpre )
 
 ! --> Utilisation d'un flux de masse specifique pour la vitesse
 
diff --git a/src/cogz/Makefile.in b/src/cogz/Makefile.in
index 1483f77..b16e2ee 100644
--- a/src/cogz/Makefile.in
+++ b/src/cogz/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -95,17 +100,32 @@ am_libcscogz_la_OBJECTS = coini1.lo colecd.lo coprop.lo cothht.lo \
 	usd3pi.lo usebu1.lo usebuc.lo usebui.lo uslwc1.lo uslwcc.lo \
 	uslwci.lo
 libcscogz_la_OBJECTS = $(am_libcscogz_la_OBJECTS)
-libcscogz_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcscogz_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcscogz_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcscogz_la_SOURCES)
 DIST_SOURCES = $(libcscogz_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -138,6 +158,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -161,6 +182,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -212,6 +234,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -268,6 +291,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -305,7 +329,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -423,7 +446,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcscogz.la: $(libcscogz_la_OBJECTS) $(libcscogz_la_DEPENDENCIES) 
-	$(libcscogz_la_LINK)  $(libcscogz_la_OBJECTS) $(libcscogz_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcscogz_la_LINK)  $(libcscogz_la_OBJECTS) $(libcscogz_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -432,40 +455,52 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 usd3p1.lo: $(top_srcdir)/users/cogz/usd3p1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usd3p1.lo `test -f '$(top_srcdir)/users/cogz/usd3p1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usd3p1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usd3p1.lo `test -f '$(top_srcdir)/users/cogz/usd3p1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usd3p1.f90
 
 usd3pc.lo: $(top_srcdir)/users/cogz/usd3pc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usd3pc.lo `test -f '$(top_srcdir)/users/cogz/usd3pc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usd3pc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usd3pc.lo `test -f '$(top_srcdir)/users/cogz/usd3pc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usd3pc.f90
 
 usd3pi.lo: $(top_srcdir)/users/cogz/usd3pi.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usd3pi.lo `test -f '$(top_srcdir)/users/cogz/usd3pi.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usd3pi.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usd3pi.lo `test -f '$(top_srcdir)/users/cogz/usd3pi.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usd3pi.f90
 
 usebu1.lo: $(top_srcdir)/users/cogz/usebu1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usebu1.lo `test -f '$(top_srcdir)/users/cogz/usebu1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usebu1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usebu1.lo `test -f '$(top_srcdir)/users/cogz/usebu1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usebu1.f90
 
 usebuc.lo: $(top_srcdir)/users/cogz/usebuc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usebuc.lo `test -f '$(top_srcdir)/users/cogz/usebuc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usebuc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usebuc.lo `test -f '$(top_srcdir)/users/cogz/usebuc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usebuc.f90
 
 usebui.lo: $(top_srcdir)/users/cogz/usebui.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usebui.lo `test -f '$(top_srcdir)/users/cogz/usebui.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usebui.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usebui.lo `test -f '$(top_srcdir)/users/cogz/usebui.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/usebui.f90
 
 uslwc1.lo: $(top_srcdir)/users/cogz/uslwc1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslwc1.lo `test -f '$(top_srcdir)/users/cogz/uslwc1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/uslwc1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslwc1.lo `test -f '$(top_srcdir)/users/cogz/uslwc1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/uslwc1.f90
 
 uslwcc.lo: $(top_srcdir)/users/cogz/uslwcc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslwcc.lo `test -f '$(top_srcdir)/users/cogz/uslwcc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/uslwcc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslwcc.lo `test -f '$(top_srcdir)/users/cogz/uslwcc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/uslwcc.f90
 
 uslwci.lo: $(top_srcdir)/users/cogz/uslwci.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslwci.lo `test -f '$(top_srcdir)/users/cogz/uslwci.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/uslwci.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslwci.lo `test -f '$(top_srcdir)/users/cogz/uslwci.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cogz/uslwci.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/cplv/Makefile.in b/src/cplv/Makefile.in
index 6357c23..d3f9750 100644
--- a/src/cplv/Makefile.in
+++ b/src/cplv/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -95,17 +100,32 @@ am_libcscplv_la_OBJECTS = cpcym2.lo cpflux.lo cpini1.lo cpiniv.lo \
 	cpthp2.lo cptssc.lo cptsvc.lo cptsvi.lo cpvarp.lo cpveri.lo \
 	memcp1.lo uscpcl.lo uscpi1.lo uscpiv.lo uscpl1.lo uscplc.lo
 libcscplv_la_OBJECTS = $(am_libcscplv_la_OBJECTS)
-libcscplv_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcscplv_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcscplv_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcscplv_la_SOURCES)
 DIST_SOURCES = $(libcscplv_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -138,6 +158,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -161,6 +182,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -212,6 +234,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -268,6 +291,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -305,7 +329,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -418,7 +441,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcscplv.la: $(libcscplv_la_OBJECTS) $(libcscplv_la_DEPENDENCIES) 
-	$(libcscplv_la_LINK)  $(libcscplv_la_OBJECTS) $(libcscplv_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcscplv_la_LINK)  $(libcscplv_la_OBJECTS) $(libcscplv_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -427,28 +450,36 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 uscpcl.lo: $(top_srcdir)/users/cplv/uscpcl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpcl.lo `test -f '$(top_srcdir)/users/cplv/uscpcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpcl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpcl.lo `test -f '$(top_srcdir)/users/cplv/uscpcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpcl.f90
 
 uscpi1.lo: $(top_srcdir)/users/cplv/uscpi1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpi1.lo `test -f '$(top_srcdir)/users/cplv/uscpi1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpi1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpi1.lo `test -f '$(top_srcdir)/users/cplv/uscpi1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpi1.f90
 
 uscpiv.lo: $(top_srcdir)/users/cplv/uscpiv.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpiv.lo `test -f '$(top_srcdir)/users/cplv/uscpiv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpiv.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpiv.lo `test -f '$(top_srcdir)/users/cplv/uscpiv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpiv.f90
 
 uscpl1.lo: $(top_srcdir)/users/cplv/uscpl1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpl1.lo `test -f '$(top_srcdir)/users/cplv/uscpl1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpl1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscpl1.lo `test -f '$(top_srcdir)/users/cplv/uscpl1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscpl1.f90
 
 uscplc.lo: $(top_srcdir)/users/cplv/uscplc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscplc.lo `test -f '$(top_srcdir)/users/cplv/uscplc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscplc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscplc.lo `test -f '$(top_srcdir)/users/cplv/uscplc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/cplv/uscplc.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/cplv/cpphy1.f90 b/src/cplv/cpphy1.f90
index e7204c8..e0c6e4c 100644
--- a/src/cplv/cpphy1.f90
+++ b/src/cplv/cpphy1.f90
@@ -372,7 +372,7 @@ call cpcym2                                                       &
 ! --> Clipping eventuel des fractions massiques
 
 do iel = 1, ncel
-  do ice = 1, ngaze
+  do ice = 1, (ngaze-2*ncharb)
     ipcyce = ipproc(iym1(ice))
     if ( abs(propce(iel,ipcyce)) .lt. epsicp )                    &
          propce(iel,ipcyce) = zero
diff --git a/src/cplv/cpphyv.f90 b/src/cplv/cpphyv.f90
index f9fb876..e0907ca 100644
--- a/src/cplv/cpphyv.f90
+++ b/src/cplv/cpphyv.f90
@@ -423,7 +423,7 @@ enddo
 ntbcpi = 1
 ntbcpr = 15
 ntbmci = 0
-ntbmcr = 2 + 2*ncharb + 4
+ntbmcr = 2*ncharb + 8
 !  Ce sont en fait X1M, X2M,
 !                  F1M(ICHA) et F2M(ICHA) pour chaque charbon
 !                  ACHX1F1, ACHX2F2, ACOF1, ACOF2
diff --git a/src/ctwr/Makefile.in b/src/ctwr/Makefile.in
index 4f722cf..06c9fc0 100644
--- a/src/ctwr/Makefile.in
+++ b/src/ctwr/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -92,7 +97,10 @@ am_libcsctwr_la_OBJECTS = cs_ctwr.lo cs_ctwr_air_props.lo \
 	ctiniv.lo ctphyv.lo cttssc.lo ctvarp.lo usctcl.lo usctdz.lo \
 	uscti1.lo usctiv.lo
 libcsctwr_la_OBJECTS = $(am_libcsctwr_la_OBJECTS)
-libcsctwr_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcsctwr_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcsctwr_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
@@ -101,20 +109,39 @@ am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_$(V))
+am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
+am__v_CC_0 = @echo "  CC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_$(V))
+am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_CCLD_0 = @echo "  CCLD  " $@;
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcsctwr_la_SOURCES)
 DIST_SOURCES = $(libcsctwr_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -147,6 +174,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -170,6 +198,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -221,6 +250,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -277,6 +307,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -314,7 +345,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -427,7 +457,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcsctwr.la: $(libcsctwr_la_OBJECTS) $(libcsctwr_la_DEPENDENCIES) 
-	$(libcsctwr_la_LINK)  $(libcsctwr_la_OBJECTS) $(libcsctwr_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcsctwr_la_LINK)  $(libcsctwr_la_OBJECTS) $(libcsctwr_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -441,46 +471,56 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_ctwr_mesh.Plo at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 usctcl.lo: $(top_srcdir)/users/ctwr/usctcl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usctcl.lo `test -f '$(top_srcdir)/users/ctwr/usctcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/usctcl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usctcl.lo `test -f '$(top_srcdir)/users/ctwr/usctcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/usctcl.f90
 
 usctdz.lo: $(top_srcdir)/users/ctwr/usctdz.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usctdz.lo `test -f '$(top_srcdir)/users/ctwr/usctdz.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/usctdz.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usctdz.lo `test -f '$(top_srcdir)/users/ctwr/usctdz.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/usctdz.f90
 
 uscti1.lo: $(top_srcdir)/users/ctwr/uscti1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscti1.lo `test -f '$(top_srcdir)/users/ctwr/uscti1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/uscti1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uscti1.lo `test -f '$(top_srcdir)/users/ctwr/uscti1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/uscti1.f90
 
 usctiv.lo: $(top_srcdir)/users/ctwr/usctiv.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usctiv.lo `test -f '$(top_srcdir)/users/ctwr/usctiv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/usctiv.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usctiv.lo `test -f '$(top_srcdir)/users/ctwr/usctiv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/ctwr/usctiv.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/elec/Makefile.in b/src/elec/Makefile.in
index c9d55af..5d63264 100644
--- a/src/elec/Makefile.in
+++ b/src/elec/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -92,17 +97,32 @@ am_libcselec_la_OBJECTS = elflux.lo elini1.lo eliniv.lo ellecd.lo \
 	uselcl.lo uselen.lo useli1.lo useliv.lo uselph.lo uselrc.lo \
 	usetcl.lo
 libcselec_la_OBJECTS = $(am_libcselec_la_OBJECTS)
-libcselec_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcselec_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcselec_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcselec_la_SOURCES)
 DIST_SOURCES = $(libcselec_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -135,6 +155,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -158,6 +179,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -209,6 +231,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -265,6 +288,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -302,7 +326,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -412,7 +435,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcselec.la: $(libcselec_la_OBJECTS) $(libcselec_la_DEPENDENCIES) 
-	$(libcselec_la_LINK)  $(libcselec_la_OBJECTS) $(libcselec_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcselec_la_LINK)  $(libcselec_la_OBJECTS) $(libcselec_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -421,34 +444,44 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 uselcl.lo: $(top_srcdir)/users/elec/uselcl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselcl.lo `test -f '$(top_srcdir)/users/elec/uselcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselcl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselcl.lo `test -f '$(top_srcdir)/users/elec/uselcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselcl.f90
 
 uselen.lo: $(top_srcdir)/users/elec/uselen.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselen.lo `test -f '$(top_srcdir)/users/elec/uselen.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselen.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselen.lo `test -f '$(top_srcdir)/users/elec/uselen.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselen.f90
 
 useli1.lo: $(top_srcdir)/users/elec/useli1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o useli1.lo `test -f '$(top_srcdir)/users/elec/useli1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/useli1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o useli1.lo `test -f '$(top_srcdir)/users/elec/useli1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/useli1.f90
 
 useliv.lo: $(top_srcdir)/users/elec/useliv.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o useliv.lo `test -f '$(top_srcdir)/users/elec/useliv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/useliv.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o useliv.lo `test -f '$(top_srcdir)/users/elec/useliv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/useliv.f90
 
 uselph.lo: $(top_srcdir)/users/elec/uselph.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselph.lo `test -f '$(top_srcdir)/users/elec/uselph.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselph.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselph.lo `test -f '$(top_srcdir)/users/elec/uselph.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselph.f90
 
 uselrc.lo: $(top_srcdir)/users/elec/uselrc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselrc.lo `test -f '$(top_srcdir)/users/elec/uselrc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselrc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uselrc.lo `test -f '$(top_srcdir)/users/elec/uselrc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/uselrc.f90
 
 usetcl.lo: $(top_srcdir)/users/elec/usetcl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usetcl.lo `test -f '$(top_srcdir)/users/elec/usetcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/usetcl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usetcl.lo `test -f '$(top_srcdir)/users/elec/usetcl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/elec/usetcl.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/fuel/Makefile.in b/src/fuel/Makefile.in
index 5f0bc3c..581bf5d 100644
--- a/src/fuel/Makefile.in
+++ b/src/fuel/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -93,17 +98,32 @@ am_libcsfuel_la_OBJECTS = fucym1.lo fucyno.lo fuflux.lo fuini1.lo \
 	futhp2.lo futssc.lo futsvc.lo futsvi.lo fuvarp.lo fuveri.lo \
 	memfu1.lo usfucl.lo usfui1.lo usfuiv.lo
 libcsfuel_la_OBJECTS = $(am_libcsfuel_la_OBJECTS)
-libcsfuel_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcsfuel_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcsfuel_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcsfuel_la_SOURCES)
 DIST_SOURCES = $(libcsfuel_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -136,6 +156,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -159,6 +180,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -210,6 +232,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -266,6 +289,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -303,7 +327,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -410,7 +433,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcsfuel.la: $(libcsfuel_la_OBJECTS) $(libcsfuel_la_DEPENDENCIES) 
-	$(libcsfuel_la_LINK)  $(libcsfuel_la_OBJECTS) $(libcsfuel_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcsfuel_la_LINK)  $(libcsfuel_la_OBJECTS) $(libcsfuel_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -419,22 +442,28 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 usfucl.lo: $(top_srcdir)/users/fuel/usfucl.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usfucl.lo `test -f '$(top_srcdir)/users/fuel/usfucl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/fuel/usfucl.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usfucl.lo `test -f '$(top_srcdir)/users/fuel/usfucl.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/fuel/usfucl.f90
 
 usfui1.lo: $(top_srcdir)/users/fuel/usfui1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usfui1.lo `test -f '$(top_srcdir)/users/fuel/usfui1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/fuel/usfui1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usfui1.lo `test -f '$(top_srcdir)/users/fuel/usfui1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/fuel/usfui1.f90
 
 usfuiv.lo: $(top_srcdir)/users/fuel/usfuiv.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usfuiv.lo `test -f '$(top_srcdir)/users/fuel/usfuiv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/fuel/usfuiv.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usfuiv.lo `test -f '$(top_srcdir)/users/fuel/usfuiv.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/fuel/usfuiv.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/fuel/fuiniv.f90 b/src/fuel/fuiniv.f90
index 2c42a82..ed81bc2 100644
--- a/src/fuel/fuiniv.f90
+++ b/src/fuel/fuiniv.f90
@@ -220,6 +220,8 @@ ipass = ipass + 1
 idebia = idbia0
 idebra = idbra0
 
+d2s3 = 2.d0/3.d0
+
 !===============================================================================
 ! 2. INITIALISATION DES INCONNUES :
 !      UNIQUEMENT SI ON NE FAIT PAS UNE SUITE
diff --git a/src/lagr/Makefile.in b/src/lagr/Makefile.in
index bc3d291..78f312e 100644
--- a/src/lagr/Makefile.in
+++ b/src/lagr/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -99,7 +104,10 @@ am_libcslagr_la_OBJECTS = cs_lagr.lo cs_lagr_perio.lo diverv.lo \
 	uslag2.lo uslain.lo uslapr.lo uslaru.lo uslast.lo uslatc.lo \
 	uslatp.lo
 libcslagr_la_OBJECTS = $(am_libcslagr_la_OBJECTS)
-libcslagr_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcslagr_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcslagr_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
@@ -108,20 +116,39 @@ am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_$(V))
+am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
+am__v_CC_0 = @echo "  CC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_$(V))
+am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_CCLD_0 = @echo "  CCLD  " $@;
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcslagr_la_SOURCES)
 DIST_SOURCES = $(libcslagr_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -154,6 +181,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -177,6 +205,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -228,6 +257,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -284,6 +314,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -321,7 +352,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -461,7 +491,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcslagr.la: $(libcslagr_la_OBJECTS) $(libcslagr_la_DEPENDENCIES) 
-	$(libcslagr_la_LINK)  $(libcslagr_la_OBJECTS) $(libcslagr_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcslagr_la_LINK)  $(libcslagr_la_OBJECTS) $(libcslagr_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -473,73 +503,92 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/cs_lagr_perio.Plo at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 uslabo.lo: $(top_srcdir)/users/lagr/uslabo.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslabo.lo `test -f '$(top_srcdir)/users/lagr/uslabo.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslabo.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslabo.lo `test -f '$(top_srcdir)/users/lagr/uslabo.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslabo.f90
 
 usladp.lo: $(top_srcdir)/users/lagr/usladp.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usladp.lo `test -f '$(top_srcdir)/users/lagr/usladp.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/usladp.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usladp.lo `test -f '$(top_srcdir)/users/lagr/usladp.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/usladp.f90
 
 uslaed.lo: $(top_srcdir)/users/lagr/uslaed.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslaed.lo `test -f '$(top_srcdir)/users/lagr/uslaed.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslaed.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslaed.lo `test -f '$(top_srcdir)/users/lagr/uslaed.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslaed.f90
 
 uslaen.lo: $(top_srcdir)/users/lagr/uslaen.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslaen.lo `test -f '$(top_srcdir)/users/lagr/uslaen.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslaen.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslaen.lo `test -f '$(top_srcdir)/users/lagr/uslaen.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslaen.f90
 
 uslafe.lo: $(top_srcdir)/users/lagr/uslafe.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslafe.lo `test -f '$(top_srcdir)/users/lagr/uslafe.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslafe.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslafe.lo `test -f '$(top_srcdir)/users/lagr/uslafe.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslafe.f90
 
 uslag1.lo: $(top_srcdir)/users/lagr/uslag1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslag1.lo `test -f '$(top_srcdir)/users/lagr/uslag1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslag1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslag1.lo `test -f '$(top_srcdir)/users/lagr/uslag1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslag1.f90
 
 uslag2.lo: $(top_srcdir)/users/lagr/uslag2.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslag2.lo `test -f '$(top_srcdir)/users/lagr/uslag2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslag2.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslag2.lo `test -f '$(top_srcdir)/users/lagr/uslag2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslag2.f90
 
 uslain.lo: $(top_srcdir)/users/lagr/uslain.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslain.lo `test -f '$(top_srcdir)/users/lagr/uslain.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslain.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslain.lo `test -f '$(top_srcdir)/users/lagr/uslain.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslain.f90
 
 uslapr.lo: $(top_srcdir)/users/lagr/uslapr.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslapr.lo `test -f '$(top_srcdir)/users/lagr/uslapr.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslapr.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslapr.lo `test -f '$(top_srcdir)/users/lagr/uslapr.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslapr.f90
 
 uslaru.lo: $(top_srcdir)/users/lagr/uslaru.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslaru.lo `test -f '$(top_srcdir)/users/lagr/uslaru.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslaru.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslaru.lo `test -f '$(top_srcdir)/users/lagr/uslaru.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslaru.f90
 
 uslast.lo: $(top_srcdir)/users/lagr/uslast.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslast.lo `test -f '$(top_srcdir)/users/lagr/uslast.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslast.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslast.lo `test -f '$(top_srcdir)/users/lagr/uslast.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslast.f90
 
 uslatc.lo: $(top_srcdir)/users/lagr/uslatc.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslatc.lo `test -f '$(top_srcdir)/users/lagr/uslatc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslatc.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslatc.lo `test -f '$(top_srcdir)/users/lagr/uslatc.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslatc.f90
 
 uslatp.lo: $(top_srcdir)/users/lagr/uslatp.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslatp.lo `test -f '$(top_srcdir)/users/lagr/uslatp.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslatp.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o uslatp.lo `test -f '$(top_srcdir)/users/lagr/uslatp.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/lagr/uslatp.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/lagr/enslag.f90 b/src/lagr/enslag.f90
index 3f1e3a7..701c1e4 100644
--- a/src/lagr/enslag.f90
+++ b/src/lagr/enslag.f90
@@ -680,7 +680,11 @@ if (nfin.eq.1) then
         write(impla1,1030) ra(iz+ii-1)
       enddo
       write(impla1,3006)
-      write(impla1,1010) ipt-1
+      if (ipt.eq.0) then
+        write(impla1,1010) 0
+      else
+        write(impla1,1010) ipt-1
+      endif
       do ii=1,ipt-1
         write(impla1,1020) ii,ii+1
       enddo
diff --git a/src/lagr/enswaf.f90 b/src/lagr/enswaf.f90
index 3dcadf4..29cb104 100644
--- a/src/lagr/enswaf.f90
+++ b/src/lagr/enswaf.f90
@@ -144,7 +144,9 @@ if ( (mod(ipwaf-1,nvisla).eq.0 .and. nfin.eq.0)   .or.            &
   npt = 0
   do nl = 1,nbvis
     np = liste(nl)
-    if (np.ge.1 .and. itepa(np,jisor).ne.0) npt = npt + 1
+    if (np.ge.1) then
+      if (itepa(np,jisor).ne.0) npt = npt + 1
+    endif
   enddo
 
 !-->Y a t-il encore des particules a visualiser ?
@@ -251,8 +253,6 @@ if (ivistp.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -288,8 +288,6 @@ if (iviste.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -325,8 +323,6 @@ if (ivisdm.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -362,8 +358,6 @@ if (ivismp.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -399,8 +393,6 @@ if (ivishp.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -436,8 +428,6 @@ if (ivisdk.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -473,8 +463,6 @@ if (ivisch.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -510,8 +498,6 @@ if (ivisck.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( REAL(TRAV(NP,1)), NP=1,NPT )
   close(impla1)
 
@@ -549,8 +535,6 @@ if (ivisv1.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( (REAL(TRAV(NP,NL)),NL=1,3),NP=1,NPT )
   close(impla1)
 
@@ -588,8 +572,6 @@ if (ivisv2.eq.1) then
 !-->Ecriture
 
   WRITE(IMPLA1,'(A)') FICH(II1:II2+LPOS)
-  WRITE(IMPLA1,'(A)') 'part   1'
-  WRITE(IMPLA1,'(A)') 'point'
   WRITE(IMPLA1,'(6E12.5)') ( (REAL(TRAV(NP,NL)),NL=1,3),NP=1,NPT )
   close(impla1)
 
@@ -601,7 +583,6 @@ endif
 
  100  continue
 
-if (nfin.eq.1) then
 
   FICH = ' '
   fich = entet
@@ -643,7 +624,7 @@ if (nfin.eq.1) then
 !       WRITE(IMPLA1,'(A)') NAME(II1:II2)
 
   if (ivistp.eq.1) then
-    NAME = 'scalar per node :      1    temps_de_sejour  '
+    NAME = 'scalar per node:      1    temps_de_sejour  '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 2
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -655,7 +636,7 @@ if (nfin.eq.1) then
   endif
 
   if (iviste.eq.1) then
-    NAME = 'scalar per node :      1    temperature      '
+    NAME = 'scalar per node:      1    temperature      '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 6
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -667,7 +648,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivisdm.eq.1) then
-    NAME = 'scalar per node :      1    diametre         '
+    NAME = 'scalar per node:      1    diametre         '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 9
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -679,7 +660,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivismp.eq.1) then
-    NAME = 'scalar per node :      1    masse            '
+    NAME = 'scalar per node:      1    masse            '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 12
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -691,7 +672,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivishp.eq.1) then
-    NAME = 'scalar per node :      1    tempch           '
+    NAME = 'scalar per node:      1    tempch           '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 11
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -703,7 +684,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivisdk.eq.1) then
-    NAME = 'scalar per node :      1    dck              '
+    NAME = 'scalar per node:      1    dck              '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 14
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -715,7 +696,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivisch.eq.1) then
-    NAME = 'scalar per node :      1    mch              '
+    NAME = 'scalar per node:      1    mch              '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 14
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -727,7 +708,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivisck.eq.1) then
-    NAME = 'scalar per node :      1    mck              '
+    NAME = 'scalar per node:      1    mck              '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 14
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -739,7 +720,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivisv1.eq.1) then
-    NAME = 'vector per node :      1    vitesse_fluide   '
+    NAME = 'vector per node:      1    vitesse_fluide   '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 3
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -751,7 +732,7 @@ if (nfin.eq.1) then
   endif
 
   if (ivisv2.eq.1) then
-    NAME = 'vector per node :      1    vitesse_partic   '
+    NAME = 'vector per node:      1    vitesse_partic   '
     call verlon (name,ii1,ii2,lpos)
     ii2 = ii2 + 3
     name(ii2+1:ii2+n2)=fich(n1:n2)
@@ -763,7 +744,7 @@ if (nfin.eq.1) then
   endif
 
   WRITE(IMPLA1,'(A)') 'TIME'
-  WRITE(IMPLA1,'(A)') 'time set:'
+  WRITE(IMPLA1,'(A)') 'time set:               1'
   FICH = ' '
   FICH = 'number of steps:'
   WRITE(NAME,'(I4)') ITLAG
@@ -774,11 +755,12 @@ if (nfin.eq.1) then
   WRITE(IMPLA1,'(A)') 'filename start number:  1'
   WRITE(IMPLA1,'(A)') 'filename increment:     1'
   WRITE(IMPLA1,'(A)') 'time values:'
-  WRITE(IMPLA1,'(6E12.5)') (TIMLAG(NL),NL=1,ITLAG)
+  do nl = 1, itlag
+    WRITE(IMPLA1,'(E12.5)') TIMLAG(NL)
+  enddo
 
   close(impla1)
 
-endif
 
 return
 
diff --git a/src/lagr/lageli.f90 b/src/lagr/lageli.f90
index aa0e113..08742ab 100644
--- a/src/lagr/lageli.f90
+++ b/src/lagr/lageli.f90
@@ -146,7 +146,7 @@ do npt = nbpart,1,-1
 !        ---> c'est la derniere particule, on la supprime seulement
 
       nbp  = nbp - 1
-      dnbp = dnbp - tepa(nbp,jrpoi)
+      dnbp = dnbp - tepa(npt,jrpoi)
 
       do i = 1,nliste
         if ( liste(i).eq.npt ) then
@@ -159,9 +159,11 @@ do npt = nbpart,1,-1
 !        ---> la particule NPT est supprime et on met a la place la
 !             particule NBP
 
+      dnbp = dnbp - tepa(npt,jrpoi)
+
       do ivar = 1,nvp
         ettp(npt,ivar) = ettp(nbp,ivar)
-        enddo
+      enddo
 
       do ivar = 1,nvp
         ettpa(npt,ivar) = ettpa(nbp,ivar)
@@ -188,7 +190,6 @@ do npt = nbpart,1,-1
       enddo
 
       nbp  = nbp - 1
-      dnbp = dnbp - tepa(nbp,jrpoi)
 
     endif
 
diff --git a/src/lagr/lagopt.f90 b/src/lagr/lagopt.f90
index d2b45fb..f8053bc 100644
--- a/src/lagr/lagopt.f90
+++ b/src/lagr/lagopt.f90
@@ -394,6 +394,10 @@ if (iihmpr.eq.1) then
     call cfname(3, nombrd(ii), len(nombrd(ii)), ii)
   enddo
 
+  do ii = 1, nbvis
+    liste(ii) = ii
+  enddo
+
 endif
 
 call uslag1
diff --git a/src/mati/Makefile.in b/src/mati/Makefile.in
index c4a6727..98c28c1 100644
--- a/src/mati/Makefile.in
+++ b/src/mati/Makefile.in
@@ -75,9 +75,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -89,17 +94,32 @@ libcsmati_la_LIBADD =
 am_libcsmati_la_OBJECTS = memmat.lo mtimpi.lo mtini1.lo mtkpdc.lo \
 	mtphyv.lo mtproj.lo mttsns.lo mttssc.lo mttycl.lo
 libcsmati_la_OBJECTS = $(am_libcsmati_la_OBJECTS)
-libcsmati_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcsmati_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcsmati_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcsmati_la_SOURCES)
 DIST_SOURCES = $(libcsmati_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -130,6 +150,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -153,6 +174,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -204,6 +226,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -260,6 +283,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -297,7 +321,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -398,7 +421,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcsmati.la: $(libcsmati_la_OBJECTS) $(libcsmati_la_DEPENDENCIES) 
-	$(libcsmati_la_LINK)  $(libcsmati_la_OBJECTS) $(libcsmati_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcsmati_la_LINK)  $(libcsmati_la_OBJECTS) $(libcsmati_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -407,12 +430,15 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
diff --git a/src/pprt/Makefile.in b/src/pprt/Makefile.in
index 2d12872..a7824c1 100644
--- a/src/pprt/Makefile.in
+++ b/src/pprt/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -92,17 +97,32 @@ am_libcspprt_la_OBJECTS = memppt.lo ppcabs.lo ppclim.lo ppcsca.lo \
 	ppphyv.lo ppprcl.lo ppprop.lo ppray4.lo pptbht.lo pptssc.lo \
 	pptycl.lo ppvarp.lo usppmo.lo
 libcspprt_la_OBJECTS = $(am_libcspprt_la_OBJECTS)
-libcspprt_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcspprt_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcspprt_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcspprt_la_SOURCES)
 DIST_SOURCES = $(libcspprt_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -135,6 +155,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -158,6 +179,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -209,6 +231,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -265,6 +288,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -302,7 +326,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -412,7 +435,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcspprt.la: $(libcspprt_la_OBJECTS) $(libcspprt_la_DEPENDENCIES) 
-	$(libcspprt_la_LINK)  $(libcspprt_la_OBJECTS) $(libcspprt_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcspprt_la_LINK)  $(libcspprt_la_OBJECTS) $(libcspprt_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -421,16 +444,20 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 usppmo.lo: $(top_srcdir)/users/pprt/usppmo.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usppmo.lo `test -f '$(top_srcdir)/users/pprt/usppmo.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/pprt/usppmo.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usppmo.lo `test -f '$(top_srcdir)/users/pprt/usppmo.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/pprt/usppmo.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/rayt/Makefile.in b/src/rayt/Makefile.in
index 5631cda..79789bc 100644
--- a/src/rayt/Makefile.in
+++ b/src/rayt/Makefile.in
@@ -76,9 +76,14 @@ am__aclocal_m4_deps = $(top_srcdir)/config/cs_bft.m4 \
 	$(top_srcdir)/config/gettext.m4 $(top_srcdir)/config/iconv.m4 \
 	$(top_srcdir)/config/lib-ld.m4 \
 	$(top_srcdir)/config/lib-link.m4 \
-	$(top_srcdir)/config/lib-prefix.m4 $(top_srcdir)/config/nls.m4 \
-	$(top_srcdir)/config/po.m4 $(top_srcdir)/config/progtest.m4 \
-	$(top_srcdir)/configure.ac
+	$(top_srcdir)/config/lib-prefix.m4 \
+	$(top_srcdir)/config/libtool.m4 \
+	$(top_srcdir)/config/ltoptions.m4 \
+	$(top_srcdir)/config/ltsugar.m4 \
+	$(top_srcdir)/config/ltversion.m4 \
+	$(top_srcdir)/config/lt~obsolete.m4 \
+	$(top_srcdir)/config/nls.m4 $(top_srcdir)/config/po.m4 \
+	$(top_srcdir)/config/progtest.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -92,17 +97,32 @@ am_libcsrayt_la_OBJECTS = memra1.lo memra2.lo memra3.lo raycli.lo \
 	raypar.lo raypun.lo raysca.lo raysol.lo rmodak.lo usray1.lo \
 	usray2.lo usray3.lo usray4.lo usray5.lo
 libcsrayt_la_OBJECTS = $(am_libcsrayt_la_OBJECTS)
-libcsrayt_la_LINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) \
+AM_V_lt = $(am__v_lt_$(V))
+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
+am__v_lt_0 = --silent
+libcsrayt_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
 	$(libcsrayt_la_LDFLAGS) $(LDFLAGS) -o $@
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
 FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS)
-LTFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS)
+AM_V_FC = $(am__v_FC_$(V))
+am__v_FC_ = $(am__v_FC_$(AM_DEFAULT_VERBOSITY))
+am__v_FC_0 = @echo "  FC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 FCLD = $(FC)
-FCLINK = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_FCLD = $(am__v_FCLD_$(V))
+am__v_FCLD_ = $(am__v_FCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_FCLD_0 = @echo "  FCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libcsrayt_la_SOURCES)
 DIST_SOURCES = $(libcsrayt_la_SOURCES)
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -135,6 +155,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -158,6 +179,7 @@ CPPFLAGS = @CPPFLAGS@
 CYGPATH_W = @CYGPATH_W@
 DEFS = @DEFS@
 DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
 DSYMUTIL = @DSYMUTIL@
 DUMPBIN = @DUMPBIN@
 ECHO_C = @ECHO_C@
@@ -209,6 +231,7 @@ LTLIBINTL = @LTLIBINTL@
 LTLIBOBJS = @LTLIBOBJS@
 MAINT = @MAINT@
 MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
 MEI_CPPFLAGS = @MEI_CPPFLAGS@
 MEI_LDFLAGS = @MEI_LDFLAGS@
 MEI_LIBS = @MEI_LIBS@
@@ -265,6 +288,7 @@ abs_srcdir = @abs_srcdir@
 abs_top_builddir = @abs_top_builddir@
 abs_top_srcdir = @abs_top_srcdir@
 ac_aux_dir = @ac_aux_dir@
+ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 ac_ct_F77 = @ac_ct_F77@
@@ -302,7 +326,6 @@ libdir = @libdir@
 libexecdir = @libexecdir@
 localedir = @localedir@
 localstatedir = @localstatedir@
-lt_ECHO = @lt_ECHO@
 mandir = @mandir@
 mei_prefix = @mei_prefix@
 mkdir_p = @mkdir_p@
@@ -411,7 +434,7 @@ clean-noinstLTLIBRARIES:
 	  rm -f "$${dir}/so_locations"; \
 	done
 libcsrayt.la: $(libcsrayt_la_OBJECTS) $(libcsrayt_la_DEPENDENCIES) 
-	$(libcsrayt_la_LINK)  $(libcsrayt_la_OBJECTS) $(libcsrayt_la_LIBADD) $(LIBS)
+	$(AM_V_FCLD)$(libcsrayt_la_LINK)  $(libcsrayt_la_OBJECTS) $(libcsrayt_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -420,28 +443,36 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f90.o:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ $<
 
 .f90.obj:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(FCCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f90.lo:
+	$(AM_V_FC) @AM_BACKSLASH@
 	$(LTFCCOMPILE) -c -o $@ $<
 
 usray1.lo: $(top_srcdir)/users/rayt/usray1.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray1.lo `test -f '$(top_srcdir)/users/rayt/usray1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray1.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray1.lo `test -f '$(top_srcdir)/users/rayt/usray1.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray1.f90
 
 usray2.lo: $(top_srcdir)/users/rayt/usray2.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray2.lo `test -f '$(top_srcdir)/users/rayt/usray2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray2.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray2.lo `test -f '$(top_srcdir)/users/rayt/usray2.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray2.f90
 
 usray3.lo: $(top_srcdir)/users/rayt/usray3.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray3.lo `test -f '$(top_srcdir)/users/rayt/usray3.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray3.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray3.lo `test -f '$(top_srcdir)/users/rayt/usray3.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray3.f90
 
 usray4.lo: $(top_srcdir)/users/rayt/usray4.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray4.lo `test -f '$(top_srcdir)/users/rayt/usray4.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray4.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray4.lo `test -f '$(top_srcdir)/users/rayt/usray4.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray4.f90
 
 usray5.lo: $(top_srcdir)/users/rayt/usray5.f90
-	$(LIBTOOL)  --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray5.lo `test -f '$(top_srcdir)/users/rayt/usray5.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray5.f90
+	$(AM_V_FC) @AM_BACKSLASH@
+	$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o usray5.lo `test -f '$(top_srcdir)/users/rayt/usray5.f90' || echo '$(srcdir)/'`$(top_srcdir)/users/rayt/usray5.f90
 
 mostlyclean-libtool:
 	-rm -f *.lo
diff --git a/src/rayt/raycli.f90 b/src/rayt/raycli.f90
index a543955..6b18845 100644
--- a/src/rayt/raycli.f90
+++ b/src/rayt/raycli.f90
@@ -722,7 +722,6 @@ endif
    dt     , rtp    , rtpa   , propce , propfa , propfb ,          &
    coefa  , coefb  ,                                              &
    w1     , w2     , w3     , w4     , w5     , w6     ,          &
-   rdevel , rtuser ,                                              &
    propfb(1,ipprob(itparo)) , tbord  , tempk  ,                   &
 !                                   Resultat : T en K
    rdevel , rtuser ,                                              &
diff --git a/src/rayt/rayopt.f90 b/src/rayt/rayopt.f90
index 3bedc3b..8872a3f 100644
--- a/src/rayt/rayopt.f90
+++ b/src/rayt/rayopt.f90
@@ -417,9 +417,11 @@ if (iirayo.gt.0) then
 
 ! --> NDIREC
 !     Choix entre 32 et 128 directions (cf raysol)
-  if (ndirec.ne.32 .and. ndirec.ne.128 ) then
-    write(nfecra,4020) ndirec
-    iok = iok + 1
+  if (iirayo.eq.1) then
+    if (ndirec.ne.32 .and. ndirec.ne.128 ) then
+      write(nfecra,4020) ndirec
+      iok = iok + 1
+    endif
   endif
 
 ! --> IDIVER
diff --git a/users/atmo/usatcl.f90 b/users/atmo/usatcl.f90
index e704dc8..a8576f9 100644
--- a/users/atmo/usatcl.f90
+++ b/users/atmo/usatcl.f90
@@ -47,12 +47,14 @@ subroutine usatcl &
    rdevel , rtuser , ra     )
 
 !===============================================================================
-! FONCTION :
-! --------
+! Purpose:
+! -------
 
-!    ROUTINE UTILISATEUR POUR LA VERSION PART. ATMOSPHERIQUE
-!    REMPLISSAGE DU TABLEAU DE CONDITIONS AUX LIMITES
-!    (ICODCL,RCODCL) POUR LES VARIABLES INCONNUES
+!    User subroutine for the atmospheric module.
+
+!    Fill boundary conditions arrays (icodcl, rcodcl) for unknown variables.
+
+!    (similar to usclim.f90)
 
 
 ! Introduction
@@ -121,8 +123,7 @@ subroutine usatcl &
 !  (nfabor, nphas) !    !     !                                                !
 ! itypfb           ! ia ! --> ! boundary face types                            !
 !  (nfabor, nphas) !    !     !                                                !
-! izfppp           ! te ! --> ! numero de zone de la face de bord              !
-! (nfabor)         !    !     !  pour le module phys. part.                    !
+! izfppp(nfabor)   ! te ! --> ! boundary face zone number                      !
 ! idevel(nideve)   ! ia ! <-> ! integer work array for temporary development   !
 ! ituser(nituse)   ! ia ! <-> ! user-reserved integer work array               !
 ! ia(*)            ! ia ! --- ! main integer work array                        !
@@ -235,7 +236,7 @@ double precision uref2, d2s3
 double precision rhomoy, dh, ustar2
 double precision xintur
 double precision zref,xuref
-double precision ustar,rugd
+double precision ustar,rugd, rugt
 double precision zent,xuent,xvent
 double precision xkent, xeent
 double precision tpent
@@ -245,9 +246,10 @@ double precision tpent
 
 ! TEST_TO_REMOVE_FOR_USE_OF_SUBROUTINE_START
 !===============================================================================
-! 0.  CE TEST PERMET A L'UTILISATEUR D'ETRE CERTAIN QUE C'EST
-!       SA VERSION DU SOUS PROGRAMME QUI EST UTILISEE
-!       ET NON CELLE DE LA BIBLIOTHEQUE
+! 0.  This test allows the user to ensure that the version of this subroutine
+!       used is that from his case definition, and not that from the library.
+!     If a file from the GUI is used, this subroutine may not be mandatory,
+!       thus the default (library reference) version returns immediately.
 !===============================================================================
 
 if(iihmpr.eq.1) then
@@ -257,27 +259,27 @@ else
   call csexit (1)
 endif
 
- 9000 format(                                                           &
-'@                                                            ',/,&
+ 9000 format(                                                     &
+'@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
-'@                                                            ',/,&
-'@ @@ ATTENTION : ARRET LORS DE L''ENTREE DES COND. LIM.      ',/,&
-'@    =========                                               ',/,&
-'@     MODULE ECOULEMENTS ATMOSPHERIQUES                      ',/,&
-'@     LE SOUS-PROGRAMME UTILISATEUR usatcl DOIT ETRE COMPLETE',/,&
-'@                                                            ',/,&
-'@  Le calcul ne sera pas execute.                            ',/,&
+'@',/,                                                            &
+'@ @@ WARNING:    stop in definition of boundary conditions',/,   &
+'@    =======',/,                                                 &
+'@      for the atmospheric module                          ',/,  &
+'@     The user subroutine ''usatcl'' must be completed.',/,      &
+'@',/,                                                            &
+'@  The calculation will not be run.',/,                          &
 '@                                                            ',/,&
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
-'@                                                            ',/)
+'@',/)
+
 
 ! TEST_TO_REMOVE_FOR_USE_OF_SUBROUTINE_END
 
 
 
 !===============================================================================
-! 1.  INITIALISATIONS
-
+! 1.  Initialization
 !===============================================================================
 
 idebia = idbia0
@@ -289,91 +291,92 @@ d2s3 = 2.d0/3.d0
 zref=10.d0
 xuref=10.d0
 rugd=0.1d0
+rugt=0.1d0
 
 !===============================================================================
-! 2.  REMPLISSAGE DU TABLEAU DES CONDITIONS LIMITES
-!       ON BOUCLE SUR LES FACES DE BORD
-!         ON DETERMINE LA FAMILLE ET SES PROPRIETES
-!           ON IMPOSE LA CONDITION LIMITE
-
-!          IMPOSER ICI LES CONDITIONS LIMITES SUR LES FACES DE BORD
+! 2.  Assign boundary conditions to boundary faces here
 
+!     One may use selection criteria to filter boundary case subsets
+!       Loop on faces from a subset
+!         Set the boundary condition for each face
 !===============================================================================
 
+! --- For boundary faces of color 11,
+!       assign an inlet boundary condition for all phases prescribed from the meteo profile
+!       with automatic choice between inlet/ outlet according to the meteo profile
 
-! --- On impose en couleur 11 une condition basee sur le profil meteo
-!       avec choix automatique entre entree et sortie a partir du profil
-
-CALL GETFBR('11',NLELT,LSTELT)
-
-!   - Numero de zone (on numerote de 1 a n)
+call getfbr('11',nlelt,lstelt)
+!==========
+!   - Zone number (from 1 to n)
 izone = 1
 
 do ilelt = 1, nlelt
 
   ifac = lstelt(ilelt)
 
-!     - Reperage de la zone a laquelle appartient la face
+!     - Zone to which the face belongs
   izfppp(ifac) = izone
 
-!     - On indique que les conditions a la limite seront tirees
-!         du profil meteo
+!     - Boundary conditions are prescribed from the meteo profile
   iprofm(izone) = 1
 
 enddo
 
-! --- On impose en couleur 21 une condition d'entree avec des valeurs
-!       tirees du profil meteo
 
-CALL GETFBR('21',NLELT,LSTELT)
+! ---For boundary faces of color 21,
+!     assign an inlet boundary condition for all phases prescribed from the meteo profile
 
-!   - Numero de zone (on numerote de 1 a n)
+call getfbr('21',nlelt,lstelt)
+!==========
+!   -  Zone number (from 1 to n)
 izone = 2
 
 do ilelt = 1, nlelt
 
   ifac = lstelt(ilelt)
 
-!     - Reperage de la zone a laquelle appartient la face
+!     - Zone to which the face belongs
   izfppp(ifac) = izone
 
-!     - On indique que les conditions a la limite seront tirees
-!         du profil meteo
+!     - Boundary conditions are prescribed from the meteo profile
   iprofm(izone) = 1
 
-!     - On force les faces a etre des faces d'entree
+!     - Assign inlet boundary conditions
   do iphas = 1, nphas
     itypfb(ifac,iphas) = ientre
   enddo
 
 enddo
 
-! --- On impose en couleur 31 une condition d'entree avec des valeurs
-!       tirees du profil meteo, sauf pour les variables dynamiques sur
-!       lesquelles on impose un profil analytique rugueux
+! --- For boundary faces of color 31,
+!       assign an inlet boundary condition for all phases prescribed from the meteo profile
+!       except for dynamical variables which are prescribed with a rough log law.
 
-CALL GETFBR('31',NLELT,LSTELT)
+call getfbr('31',nlelt,lstelt)
+!==========
 
-!   - Numero de zone (on numerote de 1 a n)
+!   - Zone number (from 1 to n)
 izone = 3
 
 do ilelt = 1, nlelt
 
   ifac = lstelt(ilelt)
 
-!     - Reperage de la zone a laquelle appartient la face
+!     - Zone to which the face belongs
   izfppp(ifac) = izone
 
-!     - On indique que les conditions a la limite seront tirees
-!         du profil meteo
+!     - Boundary conditions are prescribed from the meteo profile
   iprofm(izone) = 1
 
+!     - Dynamical variables are prescribed with a rough log law
+  zent=cdgfbo(3,ifac)
+
   ustar=xkappa*xuref/log((zref+rugd)/rugd)
   xuent=ustar/xkappa*log((zent+rugd)/rugd)
+  xvent = 0.d0
   xkent=ustar**2/sqrt(cmu)
   xeent=ustar**3/xkappa/(zent+rugd)
 
-
   do iphas = 1, nphas
 
     itypfb(ifac,iphas) = ientre
@@ -382,7 +385,7 @@ do ilelt = 1, nlelt
     rcodcl(ifac,iv(iphas),1) = xvent
     rcodcl(ifac,iw(iphas),1) = 0.d0
 
-!     ITYTUR est un indicateur qui vaut ITURB/10
+    ! itytur is a flag equal to iturb/10
     if    (itytur(iphas).eq.2) then
 
       rcodcl(ifac,ik(iphas),1)  = xkent
@@ -416,88 +419,87 @@ do ilelt = 1, nlelt
 
 enddo
 
-! --- On impose en couleur 12 une sortie pour toutes les phases
-CALL GETFBR('12',NLELT,LSTELT)
+! --- Prescribe at boundary faces of color '12' an outlet for all phases
+call getfbr('12', nlelt, lstelt)
 !==========
 
-!   - Numero de zone (on numerote de 1 a n)
+!   - Zone number (from 1 to n)
 izone = 4
 
 do ilelt = 1, nlelt
 
   ifac = lstelt(ilelt)
 
-!     - Reperage de la zone a laquelle appartient la face
+!     - Zone to which the zone belongs
   izfppp(ifac) = izone
 
-!          SORTIE : FLUX NUL VITESSE ET TEMPERATURE, PRESSION IMPOSEE
-!            Noter que la pression sera recalee a P0
-!                sur la premiere face de sortie libre (ISOLIB)
+  ! Outlet: zero flux for velocity and temperature, prescribed pressure
+  !         Note that the pressure will be set to P0 at the first
+  !         free outlet face (isolib)
 
   do iphas = 1, nphas
     itypfb(ifac,iphas)   = isolib
-
   enddo
 
 enddo
 
-! --- On impose en couleur 15 une paroi rugueuse pour toutes les phases
-CALL GETFBR('15',NLELT,LSTELT)
+! --- Prescribe at boundary faces of color 15 a rough wall for all phases
+call getfbr('15', nlelt, lstelt)
 !==========
 
-!   - Numero de zone (on numerote de 1 a n)
+!   - Zone number (from 1 to n)
 izone = 5
 
 do ilelt = 1, nlelt
 
   ifac = lstelt(ilelt)
 
-!          PAROI : DEBIT NUL (FLUX NUL POUR LA PRESSION)
-!                  FROTTEMENT RUGUEUX POUR LES VITESSES (+GRANDEURS TURB)
-!                  FLUX NUL SUR LES SCALAIRES
+  ! Wall: zero flow (zero flux for pressure)
+  !       rough friction for velocities (+ turbulent variables)
+  !       zero flux for scalars
 
-!     - Reperage de la zone a laquelle appartient la face
+!     - Zone to which the zone belongs
   izfppp(ifac) = izone
 
   do iphas = 1, nphas
     itypfb(ifac,iphas)   = iparug
 
-    ! Rugosite pour la vitesse
+!     Roughness for velocity: rugd
     rcodcl(ifac,iu(iphas),3) = rugd
-    ! Rugosite pour les scalaires
-    !rcodcl(ifac,iv(iphas),3) = rugt
-  enddo
 
-  if(nscal.gt.0) then
+!     Roughness for scalars (if required):
+!   rcodcl(ifac,iv(iphas),3) = rugd
+
 
-! SI TEMPERATURE IMPOSEE A 20 AVEC LOI DE PAROI RUGUEUSE (SCALAIRE II=1)
-!    AVEC RUGOSITE DE 1cm
-!            II = 1
-!            ICODCL(IFAC,ISCA(II))   = 6
-!            RCODCL(IFAC,ISCA(II),1) = 20.D0
-!            RCODCL(IFAC,IV(II),3) = 0.001D0
+    if(iscalt(iphas).ne.-1) then
 
-! SI FLUX IMPOSE A 4.D0 (SCALAIRE II=2)
-!            II = 2
-!            ICODCL(IFAC,ISCA(II))   = 3
-!            RCODCL(IFAC,ISCA(II),3) = 4.D0
+    ! If temperature prescribed to 20 with a rough wall law (scalar ii=1)
+    ! (with thermal roughness specified in rcodcl(ifac,iv(iphas),3)) :
+    ! ii = 1
+    ! icodcl(ifac, isca(ii))    = 6
+    ! rcodcl(ifac, isca(ii),1)  = 293.15d0
 
-  endif
+    ! If flux prescribed to 4.d0 (scalar ii=2):
+    ! ii = 2
+    ! icodcl(ifac, isca(ii))    = 3
+    ! rcodcl(ifac, isca(ii), 3) = 4.D0
 
+    endif
+  enddo
 enddo
 
-! --- On impose en couleur 4 une symetrie pour toutes les phases
-CALL GETFBR('4',NLELT,LSTELT)
+! --- Prescribe at boundary faces of color 4 a symmetry for all phases
+call getfbr('4', nlelt, lstelt)
 !==========
 
-!   - Numero de zone (on numerote de 1 a n)
+!   - Zone number (from 1 to n)
 izone = 6
 
 do ilelt = 1, nlelt
 
   ifac = lstelt(ilelt)
 
-!     - Reperage de la zone a laquelle appartient la face
+!     - Zone to which the zone belongs
   izfppp(ifac) = izone
 
   do iphas = 1, nphas
@@ -508,11 +510,11 @@ do ilelt = 1, nlelt
 enddo
 
 !----
-! FORMATS
+! Formats
 !----
 
 !----
-! FIN
+! End
 !----
 
 return
diff --git a/users/atmo/usati1.f90 b/users/atmo/usati1.f90
index f096fec..afbbe46 100644
--- a/users/atmo/usati1.f90
+++ b/users/atmo/usati1.f90
@@ -89,18 +89,19 @@ if(1.eq.1) return
 ! 1. EXEMPLE D'OPTIONS DE CALCUL A MODIFIER
 !===============================================================================
 
-!     Pour chaque phase
+! Reading the meteo file
 
-do iphas = 1, nphas
+imeteo = 1
 
-! --> Masse volumique et viscosite
+! Option for variable density and viscosity
+
+!   For each phase
+
+do iphas = 1, nphas
 
 irovar(iphas) = 0
 ivivar(iphas) = 0
 
-! ---> lecture du fichier meteo
-imeteo = 1
-
 enddo
 
 !----
diff --git a/users/base/usini1.f90 b/users/base/usini1.f90
index 7da4e42..b61bcfa 100644
--- a/users/base/usini1.f90
+++ b/users/base/usini1.f90
@@ -1312,7 +1312,7 @@ cp0(iphas)    = 1219.d0
 iphas = 1
 
 t0(iphas) = 1000.d0 + 273.15d0
-p0(iphas) = 1.013d5
+p0(iphas) = 1.01325d5
 ! We only specify XYZ0 if we explicitely fix Dirichlet conditions
 ! for the pressure.
 ! xyzp0(1,iphas) = 0.d0
diff --git a/users/base/usjoin.f90 b/users/base/usjoin.f90
index c9132cb..f9ab84a 100644
--- a/users/base/usjoin.f90
+++ b/users/base/usjoin.f90
@@ -6,7 +6,7 @@
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2009 EDF S.A., France
+!     Copyright (C) 1998-2010 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -34,10 +34,12 @@ subroutine usjoin &
  ( )
 
 !===============================================================================
-! FONCTION :
-! ----------
+! Purpose:
+! -------
 
-!     DEFINITION DE RECOLLEMENT DE MAILLAGES
+!    User subroutine.
+
+! Define (conforming or non-conforming) mesh joinings.
 
 !-------------------------------------------------------------------------------
 !ARGU                             ARGUMENTS
@@ -65,7 +67,7 @@ include "parall.h"
 
 ! Arguments
 
-! Variables locales
+! Local variables
 
 integer          iutile, ii, nbjoin
 integer          iwarnj
@@ -150,8 +152,8 @@ pmf = 0.10d0
 !      multiplication by a coef. which is equal to the max sin(e1, e2)
 !      where e1 and e2 are two edges sharing the same vertex V for which
 !      we want to compute the tolerance
-!  11: like 1 but only in taking into account only the selected faces
-!  12: like 2 but only in taking into account only the selected faces
+!  11: as 1 but taking into account only the selected faces
+!  12: as 2 but taking into account only the selected faces
 
 tcm = 1
 
@@ -184,12 +186,11 @@ tml = 30
 tmb = 25
 
 ! Tree Max. Ratio: stop to build the tree structure when
-! number of BB linked in the tree > tmr * initial number of BB
+! number of bounding boxes > tmr * number of faces to locate
 ! Efficient parameter to reduce memory consumption.
 
 tmr = 5.0
 
-
 ! Advanced parameters setup
 
 ! Each ii'th call to the advanced parameters setup routine stands
diff --git a/users/base/usjoin.f90 b/users/base/usperi.f90
similarity index 69%
copy from users/base/usjoin.f90
copy to users/base/usperi.f90
index c9132cb..c3b8641 100644
--- a/users/base/usjoin.f90
+++ b/users/base/usperi.f90
@@ -6,7 +6,7 @@
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2009 EDF S.A., France
+!     Copyright (C) 1998-2010 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -28,16 +28,18 @@
 
 !-------------------------------------------------------------------------------
 
-subroutine usjoin &
+subroutine usperi &
 !================
 
  ( )
 
 !===============================================================================
-! FONCTION :
-! ----------
+! Purpose:
+! -------
 
-!     DEFINITION DE RECOLLEMENT DE MAILLAGES
+!    User subroutine.
+
+! Define (conforming or non-conforming) periodicity.
 
 !-------------------------------------------------------------------------------
 !ARGU                             ARGUMENTS
@@ -65,10 +67,9 @@ include "parall.h"
 
 ! Arguments
 
-! Variables locales
+! Local variables
 
-integer          iutile, ii, nbjoin
-integer          iwarnj
+integer          nbperio, ii, iwarnp, iutile
 integer          tml, tmb, tcm, icm, maxsf, maxbrk
 double precision fract, plane, mtf, pmf, tmr
 
@@ -82,11 +83,7 @@ if(1.eq.1) return
 !===============================================================================
 ! TEST_TO_REMOVE_FOR_USE_OF_SUBROUTINE_END
 
-! Get the number of joining operations already defined
-! (equal to zero at the moment)
-
-call numjoi(nbjoin)
-! ==========
+! Periodicity relies on joining operation
 
 ! ---------------
 ! Main parameters
@@ -102,19 +99,77 @@ fract = 0.10d0
 ! coplanar and may be joined if angle between their
 ! unit normals (in degree) does not exceed this parameter.
 
-plane = 25.0
+plane = 25.0d0
 
 ! associated verbosity level (debug level if >= 3)
 
-iwarnj = 1
-
+iwarnp = 1
 
-! Joining definition
+! -----------------------------------
+! Periodic transformation definitions
+! -----------------------------------
 
-nbjoin = nbjoin + 1
-call defjoi(nbjoin, '98 or 99', fract, plane, iwarnj)
+call numper(nbperio) ! Number of periodicities already defined
 !==========
 
+do ii = nbperio, nbperio + 3
+
+   ! Definition of a periodicity of translation
+   ! ------------------------------------------
+
+  if (ii .eq. nbperio + 1) then
+
+    call defptr(ii, '99', fract, plane, iwarnp, &  ! Main joining parameters
+    !==========
+                1.0d0, 0.0d0, 0.0d0)               ! Translation vector
+
+  endif
+
+  ! Definition of a periodicity of rotation
+  ! ---------------------------------------
+
+  if (ii .eq. nbperio + 2) then
+
+     ! Modify default value
+     fract = 0.20d0
+     iwarnp = 2
+
+     call defpro(ii, '3', fract, plane, iwarnp,  &  ! Main joining parameters
+     !==========
+                 1.0d0, 0.0d0, 0.0d0,            &  ! Axis of the rotation
+                 20d0,                           &  ! Rotation angle in degree
+                 0.0d0, 0.0d0, 0.0d0)               ! Invariant point
+
+     ! restore default value
+     fract = 0.10d0
+     iwarnp = 1
+
+  endif
+
+  ! Definition of a general transformation using a homogeneous matrix
+  ! -----------------------------------------------------------------
+
+  ! 4x4 matrix
+  !    _               _
+  !   | r11 r12 r13 tx  |  t(x,y,z) : translation vector
+  !   | r21 r22 r23 ty  |  r(i,j)   : rotation matrix
+  !   | r31 r32 r33 tz  |
+  !   |_  0   0   0  1 _|
+  !
+  ! Can be used for helecoidal transformation for instance
+
+  if (ii .eq. nbperio + 3) then
+
+    call defpge(ii, 'all[]', fract, plane, iwarnp,  &  ! Main joining parameters
+    !==========
+                1.0d0, 0.0d0, 0.0d0, 0.0d0,         &  ! 1st row: r11 r12 r13 tx
+                0.0d0, 1.0d0, 0.0d0, 0.0d0,         &  ! 2nd row: r21 r22 r23 ty
+                0.0d0, 0.0d0, 1.0d0, 0.0d0)            ! 3rd row: r31 r32 r33 tz
+
+  endif
+
+enddo
+
 
 ! -------------------
 ! Advanced parameters
@@ -150,8 +205,8 @@ pmf = 0.10d0
 !      multiplication by a coef. which is equal to the max sin(e1, e2)
 !      where e1 and e2 are two edges sharing the same vertex V for which
 !      we want to compute the tolerance
-!  11: like 1 but only in taking into account only the selected faces
-!  12: like 2 but only in taking into account only the selected faces
+!  11: as 1 but taking into account only the selected faces
+!  12: as 2 but taking into account only the selected faces
 
 tcm = 1
 
@@ -184,12 +239,11 @@ tml = 30
 tmb = 25
 
 ! Tree Max. Ratio: stop to build the tree structure when
-! number of BB linked in the tree > tmr * initial number of BB
+! number of bounding boxes > tmr * number of faces to locate
 ! Efficient parameter to reduce memory consumption.
 
 tmr = 5.0
 
-
 ! Advanced parameters setup
 
 ! Each ii'th call to the advanced parameters setup routine stands
@@ -197,8 +251,8 @@ tmr = 5.0
 
 iutile = 0
 if (iutile.eq.1) then
-  ii = 1
-  call setajp(ii, mtf, pmf, tcm, icm, maxbrk, maxsf, tml, tmb, tmr)
+  ii = nbperio + 1
+  call setapp(ii, mtf, pmf, tcm, icm, maxbrk, maxsf, tml, tmb, tmr)
   !==========
 endif
 
diff --git a/users/base/usphyv.f90 b/users/base/usphyv.f90
index 5be6aae..cb9bfa5 100644
--- a/users/base/usphyv.f90
+++ b/users/base/usphyv.f90
@@ -6,7 +6,7 @@
 !     This file is part of the Code_Saturne Kernel, element of the
 !     Code_Saturne CFD tool.
 
-!     Copyright (C) 1998-2009 EDF S.A., France
+!     Copyright (C) 1998-2010 EDF S.A., France
 
 !     contact: saturne-support at edf.fr
 
@@ -48,65 +48,62 @@ subroutine usphyv &
    rdevel , rtuser , ra     )
 
 !===============================================================================
-! FONCTION :
-! --------
+! Purpose:
+! -------
 
-! ROUTINE UTILISATEUR : REMPLISSAGE DES VARIABLES PHYSIQUES
+!    User subroutine.
 
+!    Definition of physical variable laws.
 
+! Warning:
+! -------
 
-! ATTENTION :
-! =========
+! It is forbidden to modify turbulent viscosity "visct" here
+!       =========
+!    (a specifi subroutine is dedicated to that: usvist)
 
 
-! Il est INTERDIT de modifier la viscosite turbulente VISCT ici
-!        ========
-!  (une routine specifique est dediee a cela : usvist)
+! icp(iphas) = 1 must have been specified
+!                ========================
+!    in usini1 if we wish to define a varible specific heat
+!    cp for phase iphas (otherwise: memory overwrite).
 
 
-!  Il FAUT AVOIR PRECISE ICP(IPHAS) = 1
-!     ==================
-!    dans usini1 si on souhaite imposer une chaleur specifique
-!    CP variable pour la phase IPHAS (sinon: ecrasement memoire).
+! ivisls(iphas) = 1 must have been specified
+!                   ========================
+!    in usini1 if we wish to define a variable viscosity
+!    viscls for phase iphas (otherwise: memory overwrite).
 
 
-!  Il FAUT AVOIR PRECISE IVISLS(Numero de scalaire) = 1
-!     ==================
-!     dans usini1 si on souhaite une diffusivite VISCLS variable
-!     pour le scalaire considere (sinon: ecrasement memoire).
+! Notes:
+! -----
 
+! This routine is called at the beginning of each time step
 
+!    Thus, AT THE FIRST TIME STEP (non-restart case), the only
+!    values initialized before this call are those defined
+!      - in usini1 :
+!             . density    (initialized at ro0(iphas))
+!             . viscosity  (initialized at viscl0(iphas))
+!      - in usiniv :
+!             . calculation variables (initialized at 0 by defaut
+!             or to the value given in the GUI or in usiniv)
 
+! We may define here variation laws for cell properties, for:
+!     - density                                    rom    kg/m3
+!         (possibly also at boundary faces         romb   kg/m3)
+!     - molecular viscosity                        viscl  kg/(m s)
+!     - specific heat                              cp     J/(kg degrees)
+!     - "diffusivities" associated with sclalars   viscls kg/(m s)
 
-! Remarques :
-! ---------
 
-! Cette routine est appelee au debut de chaque pas de temps
+! The types of boundary faces at the previous time step are available
+!   (except at the first time step, where arrays itypfb and itrifb have
+!   not been initialized yet)
 
-!    Ainsi, AU PREMIER PAS DE TEMPS (calcul non suite), les seules
-!    grandeurs initialisees avant appel sont celles donnees
-!      - dans usini1 :
-!             . la masse volumique (initialisee a RO0(IPHAS))
-!             . la viscosite       (initialisee a VISCL0(IPHAS))
-!      - dans usiniv :
-!             . les variables de calcul  (initialisees a 0 par defaut
-!             ou a la valeur donnee dans usiniv)
 
-! On peut donner ici les lois de variation aux cellules
-!     - de la masse volumique                      ROM    kg/m3
-!         (et eventuellememt aux faces de bord     ROMB   kg/m3)
-!     - de la viscosite moleculaire                VISCL  kg/(m s)
-!     - de la chaleur specifique associee          CP     J/(kg degres)
-!     - des "diffusivites" associees aux scalaires VISCLS kg/(m s)
-
-
-! On dispose des types de faces de bord au pas de temps
-!   precedent (sauf au premier pas de temps, ou les tableaux
-!   ITYPFB et ITRIFB n'ont pas ete renseignes)
-
-
-! Il est conseille de ne garder dans ce sous programme que
-!    le strict necessaire.
+! It is recommended to keep only the minimum necessary in this file
+!   (i.e. remove all unused example code)
 
 
 ! Cells identification
@@ -139,7 +136,7 @@ subroutine usphyv &
 ! nphas            ! i  ! <-- ! number of phases                               !
 ! nideve, nrdeve   ! i  ! <-- ! sizes of idevel and rdevel arrays              !
 ! nituse, nrtuse   ! i  ! <-- ! sizes of ituser and rtuser arrays              !
-! nphmx            ! e  ! <-- ! nphsmx                                         !
+! nphmx            ! i  ! <-- ! nphsmx                                         !
 ! ifacel(2, nfac)  ! ia ! <-- ! interior faces -> cells connectivity           !
 ! ifabor(nfabor)   ! ia ! <-- ! boundary faces -> cells connectivity           !
 ! ifmfbr(nfabor)   ! ia ! <-- ! boundary face family numbers                   !
@@ -176,7 +173,7 @@ subroutine usphyv &
 ! propfb(nfabor, *)! ra ! <-- ! physical properties at boundary face centers   !
 ! coefa, coefb     ! ra ! <-- ! boundary conditions                            !
 !  (nfabor, *)     !    !     !                                                !
-! w1...8(ncelet    ! tr ! --- ! tableau de travail                             !
+! w1...8(ncelet    ! ra ! --- ! work array                                     !
 ! rdevel(nrdeve)   ! ra ! <-> ! real work array for temporary development      !
 ! rtuser(nrtuse)   ! ra ! <-> ! user-reserved real work array                  !
 ! ra(*)            ! ra ! --- ! main real work array                           !
@@ -256,76 +253,58 @@ if(1.eq.1) return
 
 
 !===============================================================================
-! 0. INITIALISATIONS A CONSERVER
+! 0. Initializations to keep
 !===============================================================================
 
-! --- Initialisation memoire
+! --- Memory initialization
 
 idebia = idbia0
 idebra = idbra0
 
 
-
-
-
 !===============================================================================
 
+!   The following examples should be adapted by the user
+!   ====================================================
 
-!   LES EXEMPLES FANTAISISTES SUIVANTS SONT A ADAPTER PAR L'UTILISATEUR
-!   ====================================================================
-
-!   Chaque exemple est encadre par un test sur IUTILE, par securite.
-!   Mettre IUTILE a 1 pour activer l'exemple.
+!  Each example is bounded by a test on "iutile", as a precaution.
+!  Set iutile to 1 to activate the example.
 
-!   Il est conseille de ne garder dans ce sous programme que
-!     le strict necessaire.
+!  It is recommended to keep only the minimum necessary in this file
+!  (i.e. remove all unused example code)
 
 
-
-!  EXEMPLE 1 : MASSE VOLUMIQUE VARIABLE EN FONCTION DE LA TEMPERATURE
-!  EXEMPLE 2 : VISCOSITE       VARIABLE EN FONCTION DE LA TEMPERATURE
-!  EXEMPLE 3 : CHALEUR SPECIFIQUE VARIABLE EN FONCTION DE LA TEMPERATURE
-!  EXEMPLE 4 : Lambda/CP  VARIABLE EN FONCTION DE LA TEMPERATURE
-!                  POUR LA TEMPERATURE OU L'ENTHALPIE
-!  EXEMPLE 5 : DIFFUSIVITE VARIABLE EN FONCTION DE LA TEMPERATURE
-!                  POUR LES SCALAIRES
+!  example 1: variable density as a function of temperature
+!  example 2: variable viscosity as a function of tempeprature
+!  example 3: variable specific heat as a function of tempeprature
+!  example 4: variable Lambda/CP as a function of temperature
+!             for temperature or enthalpy
+!  example 5: variable sclalars diffusivity as a function of temperature
 !===============================================================================
 
 
-
-
-
-
-
-
-
-
 !===============================================================================
-!  EXEMPLE 1 : MASSE VOLUMIQUE VARIABLE EN FONCTION DE LA TEMPERATURE
-! ===========
-!    Ci dessous on donne pour toutes les phases la meme loi pour
-!       la masse volumique
-!    Les valeurs de cette propriete doivent etre fournies au centre des
-!       cellules (et, de facon optionnelle, aux faces de bord).
+!  Example 1: variable density as a function of temperature
+!  =========
+!    Below, we define the same density law for all phases
+!    Values of this property must be defined at cell centers
+!      (and optionally, at boundary faces).
 !  ===================================================================
 
-!     Le test sur IUTILE permet de desactiver les instructions (qui
-!       ne sont fournies qu'a titre d'exemple a adapter)
+!    The test on 'iutile' allows deactivating instructions (which are defined
+!       only as a starting example)
 
 iutile = 0
 if(iutile.eq.1) then
 
-! --- Boucle sur les phases : debut
-  do iphas = 1, nphas
+  do iphas = 1, nphas ! Loop on phases
 
+    ! Position of variables, coefficients
+    ! -----------------------------------
 
-!   Positions des variables, coefficients
-!   -------------------------------------
-
-! --- Numero de variable thermique pour la phase courante iphas
-!       (et de ses conditions limites)
-!       (Pour utiliser le scalaire utilisateur 2 a la place, ecrire
-!          IVART = ISCA(2)
+    ! --- Number of the thermal variable for the current phase 'iphas'
+    !       (and of its boundary conditions)
+    !       To use user scalar 2 instead, write 'ivart = isca(2)'
 
     if (iscalt(iphas).gt.0) then
       ivart = isca(iscalt(iphas))
@@ -334,30 +313,28 @@ if(iutile.eq.1) then
       call csexit (1)
     endif
 
-! --- Position des conditions limites de la variable IVART
+    ! --- Position of boundary conditions for variable 'ivart'
 
     iclvar = iclrtp(ivart,icoef)
 
-! --- Rang de la masse volumique de la phase courante IPHAS
-!     dans PROPCE, prop. physiques au centre des elements       : IPCROM
-!     dans PROPFB, prop. physiques au centre des faces de bord  : IPBROM
+    ! --- Rank of density for current phase 'iphas'
+    !     in 'propce', physical properties at element centers:       'ipcrom'
+    !     in 'propfb', physical properties at boundary face centers: 'ipbrom'
 
     ipcrom = ipproc(irom(iphas))
     ipbrom = ipprob(irom(iphas))
 
-! --- Coefficients des lois choisis et imposes par l'utilisateur
-!       Les valeurs donnees ici sont fictives
+    ! --- Coefficients of laws chosen by the user
+    !       Values given here are fictitious
 
     vara  = -4.0668d-3
     varb  = -5.0754d-2
     varc  =  1000.9d0
 
-
-
-!   Masse volumique au centre des cellules
-!   ---------------------------------------
-!       loi              RHO       =   T  * (  A *  T +  B ) +   C
-!       soit    PROPCE(IEL,IPCROM) = XRTP * (VARA*XRTP+VARB) + VARC
+    ! Density at cell centers
+    !------------------------
+    ! law                    rho  = t  * ( a *  t +  b) +   c
+    ! so      propce(iel, ipcrom) = xrtp * (vara*xrtp+varb) + varc
 
     do iel = 1, ncel
       xrtp = rtp(iel,ivart)
@@ -365,115 +342,95 @@ if(iutile.eq.1) then
     enddo
 
 
+    ! Density at boundary faces
+    !---------------------------
 
-!   Masse volumique aux faces de bord
-!   ----------------------------------
-
-!       Par defaut, la valeur de rho au bord est la valeur prise
-!         au centre des elements voisins. C'est l'approche conseillee.
-!       Pour etre dans ce cas il suffit de ne rien faire :
-!         ne pas prescrire de valeur pour PROPFB(IFAC,IPBROM) et
-!         ne pas modifier IBROM(IPHAS)
-!         ---------------
-
-!       Pour les utilisateurs qui ne souhaiteraient pas suivre ce
-!         conseil, on precise que la temperature au bord peut etre
-!         fictive, simplement destinee a conserver un flux (c'est
-!         en particulier le cas en paroi). La valeur de rho calculee
-!         au bord avec en introduisant cette temperature fictive
-!         dans une loi physique peut donc etre totalement fausse
-!         (negative par exemple).
-
-!       Si malgre tout on souhaite imposer la loi :
-!                        RHO       =   T  * (  A *  T +  B ) +   C
-!       soit   PROPFB(IFAC,IPBROM) = XRTP * (VARA*XRTP+VARB) + VARC
-!       T etant la temperature prise au centre des faces de bord,
-
-!         on peut utiliser les lignes de code suivantes (volontairement
-!         desactivees, car a manier avec precaution) :
+    ! By default, the value of rho at the boundary is the value taken
+    !   at the center of adjacent cells. This is the recommended approach.
+    ! To be in this case, nothing needs to be done:
+    !   do not prescribe a value for propfb(ifac, ipbrom) and
+    !   do not modify ibrom(iphas)
 
-!         Noter bien que dans le cas ou l'on impose la masse volumique
-!         au bord, il faut le faire sur TOUTES les faces de bord.
-!                                       ======
+    ! For users who do not wish to follow this recommendation, we
+    !   note that the boundary temperature may be fictitious, simply
+    !   defined so as to conserve a flux (this is especially the case
+    !   at walls). The value of rho which is computed at the boundary
+    !   when introducing this fictitious temperature in a physical law
+    !   may thus be completely false (negative for example).
 
-!          IBROM(IPHAS) = 1
-!          DO IFAC = 1, NFABOR
-!            IEL = IFABOR(IFAC)
-!            XRTP = COEFA(IFAC,ICLVAR)+RTP(IEL,IVART)*COEFB(IFAC,ICLVAR)
-!            PROPFB(IFAC,IPBROM) = XRTP * (VARA*XRTP+VARB) + VARC
-!          ENDDO
+    ! If we wish to specify a law anyways:
+    !                        rho  = t  * ( a *  t +  b) +   c
+    ! so      propfb(iel, ipbrom) = xrtp * (vara*xrtp+varb) + varc
 
-!         IFABOR(IFAC) est l'element en regard de la face de bord
+    ! 't' being the temperature at boundary face centers, we may use the
+    ! following lines of code (voluntarily deactived, as the must be used
+    ! with caution):
 
-!         Attention IBROM(IPHAS) = 1 est indispensable pour que la loi
-!           soit  prise en compte.       -------------
-
-
-
-  enddo
-! --- Boucle sur les phases : fin
-endif
-! --- Test sur IUTILE : fin
+    ! Note that when we prscribe the density at the boundary, it must be done
+    ! at ALL boundary faces.
+    !    ===
 
+    ! ibrom(iphas) = 1
+    ! do ifac = 1, nfabor
+    !   iel = ifabor(ifac)
+    !   xrtp = coefa(ifac, iclvar)+rtp(iel, ivart)*coefb(ifac, iclvar)
+    !   propfb(ifac, ipbrom) = xrtp * (vara*xrtp+varb) + varc
+    ! enddo
 
+    ! ifabor(ifac) is the cell adjacent to the boundary face
 
+    ! Caution: ibrom(iphas) = 1 is necessary for the law to be taken
+    !                           into account.
 
+  enddo ! --- Loop on phases
+endif ! --- Test on 'iutile'
 
 
 !===============================================================================
-!  EXEMPLE 2 : VISCOSITE       VARIABLE EN FONCTION DE LA TEMPERATURE
-! ===========
-!    Ci dessous on donne pour toutes les phases la meme loi pour
-!       la viscosite
-!    Les valeurs de cette propriete doivent etre fournies au centre des
-!       cellules.
+!  Example 2: variable viscosity as a function of temperature
+!  =========
+!    Below, we define the same viscosity law for all phases
+!    Values of this property must be defined at cell centers
 !  ===================================================================
 
-!     Le test sur IUTILE permet de desactiver les instructions (qui
-!       ne sont fournies qu'a titre d'exemple a adapter)
+!    The test on 'iutile' allows deactivating instructions (which are defined
+!       only as a starting example)
 
 iutile = 0
 if(iutile.eq.1) then
 
-! --- Boucle sur les phases : debut
-  do iphas = 1, nphas
+  do iphas = 1, nphas ! Loop on phases
 
+    ! Position of variables, coefficients
+    ! -----------------------------------
 
-!   Positions des variables, coefficients
-!   -------------------------------------
-
-! --- Numero de variable thermique pour la phase courante iphas
-!       (Pour utiliser le scalaire utilisateur 2 a la place, ecrire
-!          IVART = ISCA(2)
+    ! --- Number of the thermal variable for the current phase 'iphas'
+    !       To use user scalar 2 instead, write 'ivart = isca(2)'
 
     if (iscalt(iphas).gt.0) then
       ivart = isca(iscalt(iphas))
     else
       write(nfecra,9010) iscalt(iphas)
-      call csexit (1)
+      call csexit(1)
     endif
 
-! --- Rang de la viscosite dynamique moleculaire de la phase IPHAS
-!     dans PROPCE, prop. physiques au centre des elements       : IPCVIS
+    ! --- Rank of molecular dynamic viscosity for current phase 'iphas'
+    !     in 'propce', physical properties at element centers: 'ipcvis'
 
     ipcvis = ipproc(iviscl(iphas))
 
-! --- Coefficients des lois choisis et imposes par l'utilisateur
-!       Les valeurs donnees ici sont fictives
+    ! --- Coefficients of laws chosen by the user
+    !       Values given here are fictitious
 
     varam = -3.4016d-9
     varbm =  6.2332d-7
     varcm = -4.5577d-5
     vardm =  1.6935d-3
 
-
-
-!   Viscosite moleculaire dynamique en kg/(m s) au centre des cellules
-!   ------------------------------------------------------------------
-!       loi              MU        =
-!                              T  *( T  *( AM  * T +  BM  )+ CM  )+ DM
-!       soit    PROPCE(IEL,IPCVIS) =
-!     &                       XRTP*(XRTP*(VARAM*XRTP+VARBM)+VARCM)+VARDM
+    ! Molecular dynamic viscosity in kg/(m.s) at cell centers
+    !--------------------------------------------------------
+    ! law                    mu   = t * (t * (am * t + bm) + cm) + dm
+    ! so      propce(iel, ipcvis) = xrtp*(xrtp*(varam*xrtp+varbm)+varcm)+vardm
 
     do iel = 1, ncel
       xrtp = rtp(iel,ivart)
@@ -481,42 +438,30 @@ if(iutile.eq.1) then
            xrtp*(xrtp*(varam*xrtp+varbm)+varcm)+vardm
     enddo
 
-
-  enddo
-! --- Boucle sur les phases : fin
-endif
-! --- Test sur IUTILE : fin
-
-
-
+  enddo ! --- Loop on phases
+endif ! --- Test on 'iutile'
 
 
 !===============================================================================
-!  EXEMPLE 3 : CHALEUR SPECIFIQUE VARIABLE EN FONCTION DE LA TEMPERATURE
-! ===========
-
-!    Ci dessous on donne pour toutes les phases la meme loi pour
-!       la chaleur specifique
-!    Les valeurs de cette propriete doivent etre fournies au centre des
-!       cellules.
+!  Example 3: specific heat as a function of temperature
+!  =========
+!    Below, we define the same viscosity law for all phases
+!    Values of this property must be defined at cell centers
 !  ===================================================================
 
-!     Le test sur IUTILE permet de desactiver les instructions (qui
-!       ne sont fournies qu'a titre d'exemple a adapter)
+!    The test on 'iutile' allows deactivating instructions (which are defined
+!       only as a starting example)
 
 iutile = 0
 if(iutile.eq.1) then
 
-! --- Boucle sur les phases : debut
-  do iphas = 1, nphas
+  do iphas = 1, nphas ! Loop on phases
 
+    ! Position of variables, coefficients
+    ! -----------------------------------
 
-!   Positions des variables, coefficients
-!   -------------------------------------
-
-! --- Numero de variable thermique pour la phase courante iphas
-!       (Pour utiliser le scalaire utilisateur 2 a la place, ecrire
-!          IVART = ISCA(2)
+    ! --- Number of the thermal variable for the current phase 'iphas'
+    !       To use user scalar 2 instead, write 'ivart = isca(2)'
 
     if (iscalt(iphas).gt.0) then
       ivart = isca(iscalt(iphas))
@@ -525,8 +470,8 @@ if(iutile.eq.1) then
       call csexit (1)
     endif
 
-! --- Rang de la chaleur specifique de la phase courante IPHAS
-!     dans PROPCE, prop. physiques au centre des elements       : IPCCP
+    ! --- Rank of the specific heat for current phase 'iphas'
+    !     in 'propce', physical properties at element centers: 'ipccp'
 
     if(icp(iphas).gt.0) then
       ipccp  = ipproc(icp   (iphas))
@@ -534,69 +479,53 @@ if(iutile.eq.1) then
       ipccp  = 0
     endif
 
-! --- Stop si CP n'est pas variable
+    ! --- Stop if Cp is not variable
 
     if(ipccp.le.0) then
       write(nfecra,1000) iphas, iphas, icp(iphas)
       call csexit (1)
     endif
 
-
-! --- Coefficients des lois choisis et imposes par l'utilisateur
-!       Les valeurs donnees ici sont fictives
+    ! --- Coefficients of laws chosen by the user
+    !       Values given here are fictitious
 
     varac = 0.00001d0
     varbc = 1000.0d0
 
-
-
-!   Chaleur specifique J/(kg degres) au centre des cellules
-!   --------------------------------------------------------
-!       loi              CP        =  AC  * T   +  BM
-!       soit    PROPCE(IEL,IPCCP ) = VARAC*XRTP + VARBC
+    ! Specific heat in J/(kg.degrees) at cell centers
+    !------------------------------------------------
+    ! law                    cp  = ac * t + bm
+    ! so      propce(iel, ipccp) = varac*xrtp + varbc
 
     do iel = 1, ncel
       xrtp = rtp(iel,ivart)
       propce(iel,ipccp ) = varac*xrtp + varbc
     enddo
 
-
-  enddo
-! --- Boucle sur les phases : fin
-endif
-! --- Test sur IUTILE : fin
-
-
-
-
+  enddo ! --- Loop on phases
+endif ! --- Test on 'iutile'
 
 
 !===============================================================================
-!  EXEMPLE 4 : Lambda/CP  VARIABLE EN FONCTION DE LA TEMPERATURE
-! ===========      POUR LA TEMPERATURE OU L'ENTHALPIE
-
-!    Ci dessous on donne pour toutes les phases la meme loi pour
-!       le rapport lambda/Cp
-!    Les valeurs de cette propriete doivent etre fournies au centre des
-!       cellules.
+!  Example 4: Lambda/Cp a function of temperature for temperature or enthalpy
+!  =========
+!    Below, we define the same lambda/Cp ratio law for all phases
+!    Values of this property must be defined at cell centers
 !  ===================================================================
 
-!     Le test sur IUTILE permet de desactiver les instructions (qui
-!       ne sont fournies qu'a titre d'exemple a adapter)
+!    The test on 'iutile' allows deactivating instructions (which are defined
+!       only as a starting example)
 
 iutile = 0
 if(iutile.eq.1) then
 
-! --- Boucle sur les phases : debut
-  do iphas = 1, nphas
+  do iphas = 1, nphas ! Loop on phases
 
+    ! Position of variables, coefficients
+    ! -----------------------------------
 
-!   Positions des variables, coefficients
-!   -------------------------------------
-
-! --- Numero de variable thermique pour la phase courante iphas
-!       (Pour utiliser le scalaire utilisateur 2 a la place, ecrire
-!          IVART = ISCA(2)
+    ! --- Number of the thermal variable for the current phase 'iphas'
+    !       To use user scalar 2 instead, write 'ivart = isca(2)'
 
     if (iscalt(iphas).gt.0) then
       ivart = isca(iscalt(iphas))
@@ -605,8 +534,8 @@ if(iutile.eq.1) then
       call csexit (1)
     endif
 
-! --- Rang de Lambda/CP de la variable thermique de phase courante IPHAS
-!     dans PROPCE, prop. physiques au centre des elements       : IPCVSL
+    ! --- Rank of Lambda/Cp of the thermal variable for current phase 'iphas'
+    !     in 'propce', physical properties at element centers: 'ipcvsl'
 
     if(ivisls(iscalt(iphas)).gt.0) then
       ipcvsl = ipproc(ivisls(iscalt(iphas)))
@@ -614,7 +543,7 @@ if(iutile.eq.1) then
       ipcvsl = 0
     endif
 
-! --- Stop si Lambda/CP n'est pas variable
+    ! --- Stop if Lambda/CP is not variable
 
     if(ipcvsl.le.0) then
       write(nfecra,1010)                                          &
@@ -622,8 +551,8 @@ if(iutile.eq.1) then
       call csexit (1)
     endif
 
-! --- Rang de la chaleur specifique de la phase courante IPHAS
-!     dans PROPCE, prop. physiques au centre des elements       : IPCCP
+    ! --- Rank of the specific heat for current phase 'iphas'
+    !     in 'propce', physical properties at element centers: 'ipccp'
 
     if(icp(iphas).gt.0) then
       ipccp  = ipproc(icp   (iphas))
@@ -631,28 +560,25 @@ if(iutile.eq.1) then
       ipccp  = 0
     endif
 
-! --- Coefficients des lois choisis et imposes par l'utilisateur
-!       Les valeurs donnees ici sont fictives
+    ! --- Coefficients of laws chosen by the user
+    !       Values given here are fictitious
 
     varal = -3.3283d-7
     varbl =  3.6021d-5
     varcl =  1.2527d-4
     vardl =  0.58923d0
 
+    ! Lambda/Cp in kg/(m.s) at cell centers
+    !--------------------------------------
+    ! law    Lambda/Cp = {t * (t * (al * t +  bl) + cl) + dl} / Cp
+    ! so     propce(iel,ipcvsl) &
+    !             = (xrtp*(xrtp*(varal*xrtp+varbl)+varcl)+vardl)/cp0(iphas)
 
-
-!   Lambda/Cp en kg/(m s) au centre des cellules
-!   ------------------------------------------
-!       loi       Lambda/CP        =
-!               {  T  *( T  *( AL  * T +  BL  )+ CL  )+ DL } / Cp
-!       soit    PROPCE(IEL,IPCVSL) =
-!     &         (XRTP*(XRTP*(VARAL*XRTP+VARBL)+VARCL)+VARDL)/CP0(IPHAS)
-
-!       On suppose Cp renseigne au prealable.
+    ! We assume Cp has been defined previously.
 
     if(ipccp.le.0) then
 
-! --- Si CP est uniforme, on utilise CP0(IPHAS)
+      ! --- If Cp is uniform, we use cp0(iphas)
       do iel = 1, ncel
         xrtp = rtp(iel,ivart)
         propce(iel,ipcvsl) =                                      &
@@ -662,7 +588,7 @@ if(iutile.eq.1) then
 
     else
 
-! --- Si CP est non uniforme, on utilise PROPCE ci dessus
+      ! --- If Cp is not uniform, we use propce above
       do iel = 1, ncel
         xrtp = rtp(iel,ivart)
         propce(iel,ipcvsl) =                                      &
@@ -672,66 +598,52 @@ if(iutile.eq.1) then
 
     endif
 
-
-  enddo
-! --- Boucle sur les phases : fin
-endif
-! --- Test sur IUTILE : fin
-
-
-
+  enddo ! --- Loop on phases
+endif ! --- Test on 'iutile'
 
 
 !===============================================================================
-!  EXEMPLE 5 : DIFFUSIVITE VARIABLE EN FONCTION DE LA TEMPERATURE
-! ===========      POUR LES SCALAIRES UTILISATEURS
-!     A l'exclusion de
-!        temperature, enthalpie (traites plus haut)
-!        variances de fluctuations (propriete egale a celle du
-!                                                      scalaire associe)
-
-!    Ci dessous on donne pour tous les scalaires (aux exclusions
-!      ci-dessus pres) la meme loi pour la diffusivite
-!    Les valeurs de cette propriete doivent etre fournies au centre des
-!       cellules.
+!  Example 5: Diffusivity as a function of temperature for user scalars
+!  =========
+!    Excluding:
+!      - temperature, enthalpy (handled above)
+!      - fluctuation variances (property equal to that of the associated scalar)
+!
+!    Below, we define the same diffusivity law for all scalars (except the
+!      ones excluded above).
+!    Values of this property must be defined at cell centers
 !  ===================================================================
 
-!     Le test sur IUTILE permet de desactiver les instructions (qui
-!       ne sont fournies qu'a titre d'exemple a adapter)
+!    The test on 'iutile' allows deactivating instructions (which are defined
+!       only as a starting example)
 
 iutile = 0
 if(iutile.eq.1) then
 
-! --- Boucle sur les scalaires : debut
-  do ii = 1, nscaus
+  do ii = 1, nscaus ! Loop on scalars
 
-! --- Numero du scalaire utilisateur II dans la liste de tous les scalaires
+    ! --- Number of user scalar 'ii' in the lsit of scalars
     iscal = ii
 
-
-! --- S'il s'agit d'une variable thermique,
-!                                   son cas a deja ete traite plus haut
+    ! --- If it is a thermal variable, it has already been handled above
     ith = 0
     do iphas = 1, nphas
       if (iscal.eq.iscalt(iphas)) ith = 1
     enddo
 
-! --- Si la variable est une fluctuation, sa diffusivite est
-!       la meme que celle du scalaire auquel elle est rattachee :
-!       il n'y a donc rien a faire ici : on passe directement
-!       a la variable suivante sans renseigner PROPCE(IEL,IPCVSL).
+    ! --- If the variable is a fluctuation, its diffusivity is the same
+    !       as that of the scalar to which it is attached:
+    !       there is nothing to do here, we move on to the next variable
+    !       without settign propce(iel,ipcvsl).
 
+    ! We only handle here non-thermal variables which are not fluctuations
     if (ith.eq.0.and.iscavr(iscal).le.0) then
-! --- On ne traite ici que les variables non thermiques
-!                                   et qui ne sont pas des fluctuations
-
 
-!   Positions des variables, coefficients
-!   -------------------------------------
+      ! Position of variables, coefficients
+      ! -----------------------------------
 
-! --- Numero de variable thermique pour la phase courante iphas
-!       (Pour utiliser le scalaire utilisateur 2 a la place, ecrire
-!          IVART = ISCA(2)
+      ! --- Number of the thermal variable for the current phase 'iphas'
+      !       To use user scalar 2 instead, write 'ivart = isca(2)'
 
       iphas = iphsca(iscal)
       if (iscalt(iphas).gt.0) then
@@ -741,8 +653,8 @@ if(iutile.eq.1) then
         call csexit (1)
       endif
 
-! --- Rang de Lambda du scalaire
-!     dans PROPCE, prop. physiques au centre des elements       : IPCVSL
+      ! --- Rank of scalar's Lambda
+      !     in 'propce', physical properties at element centers: 'ipcvsl'
 
       if(ivisls(iscal).gt.0) then
         ipcvsl = ipproc(ivisls(iscal))
@@ -750,29 +662,26 @@ if(iutile.eq.1) then
         ipcvsl = 0
       endif
 
-! --- Stop si Lambda n'est pas variable
+      ! --- Stop if Lambda is not variable
 
       if(ipcvsl.le.0) then
         write(nfecra,1010) iscal, iscal, ivisls(iscal)
         call csexit (1)
       endif
 
-! --- Coefficients des lois choisis et imposes par l'utilisateur
-!       Les valeurs donnees ici sont fictives
+      ! --- Coefficients of laws chosen by the user
+      !       Values given here are fictitious
 
       varal = -3.3283d-7
       varbl =  3.6021d-5
       varcl =  1.2527d-4
       vardl =  0.58923d0
 
-
-!   Lambda en kg/(m s) au centre des cellules
-!   ------------------------------------------
-!       loi       Lambda           =
-!                  T  *( T  *( AL  * T +  BL  )+ CL  )+ DL
-!       soit    PROPCE(IEL,IPCVSL) =
-!     &          XRTP*(XRTP*(VARAL*XRTP+VARBL)+VARCL)+VARDL
-
+      ! Lambda in kg/(m.s) at cell centers
+      !--------------------------------------
+      ! law    Lambda = {t * (t * (al * t +  bl) + cl) + dl}
+      ! so     propce(iel,ipcvsl) &
+      !             = (xrtp*(xrtp*(varal*xrtp+varbl)+varcl)+vardl)
 
       do iel = 1, ncel
         xrtp = rtp(iel,ivart)
@@ -780,26 +689,20 @@ if(iutile.eq.1) then
              (xrtp*(xrtp*(varal*xrtp+varbl)+varcl)+vardl)
       enddo
 
+    endif ! --- Tests on 'ith' and 'iscavr'
 
-    endif
-! --- Tests sur ITH et ISCAVR : fin
-
-  enddo
-! --- Boucle sur les scalaires : fin
-endif
-! --- Test sur IUTILE : fin
-
-
-
-
+  enddo ! --- Loop on phases
+endif ! --- Test on 'iutile'
 
 
 !===============================================================================
 
 !===============================================================================
-! FORMATS
+! Formats
 !----
 
+#if defined(_CS_LANG_FR)
+
  1000 format(                                                           &
 '@                                                            ',/,&
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
@@ -861,8 +764,73 @@ endif
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@                                                            ',/)
 
+#else
+
+ 1000 format(                                                     &
+'@',/,                                                            &
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@',/,                                                            &
+'@ @@ WARNING:  stop when computing physical quantities',/,       &
+'@    =======',/,                                                 &
+'@    Inconsistent calculation data',/,                           &
+'@',/,                                                            &
+'@    For phase', i10,/,                                          &
+'@      usini1 specifies that the specific heat is uniform',/,    &
+'@        icp(',i10   ,') = ',i10   ,' while',/,                  &
+'@      usphyv prescribes a variable specific heat.',/,           &
+'@',/,                                                            &
+'@    The calculation will not be run.',/,                        &
+'@',/,                                                            &
+'@    Modify usini1 or usphyv.',/,                                &
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@',/)
+ 1010 format(                                                     &
+'@',/,                                                            &
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@',/,                                                            &
+'@ @@ WARNING:  stop when computing physical quantities',/,       &
+'@    =======',/,                                                 &
+'@    Inconsistent calculation data',/,                           &
+'@',/,                                                            &
+'@    For scalar', i10,/,                                         &
+'@      usini1 specifies that the diffusivity is uniform',/,      &
+'@        ivislc(',i10   ,') = ',i10   ,' while',/,               &
+'@      usphyv prescribes a variable diffusivity.',/,             &
+'@',/,                                                            &
+'@    The calculation will not be run.',/,                        &
+'@',/,                                                            &
+'@    Modify usini1 or usphyv.',/,                                &
+'@                                                            ',/,&
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@',/)
+ 9010 format(                                                     &
+'@',/,                                                            &
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@',/,                                                            &
+'@ @@ WARNING:  stop when computing physical quantities',/,       &
+'@    =======',/,                                                 &
+'@',/,                                                            &
+'@    The variable on which physical properties depend does',/,   &
+'@      seem to be a calculation variable.',/,                    &
+'@    Indeed, we are trying to use the temperature while',/,      &
+'@      iscalt(iphas) = ',i10                                  ,/,&
+'@',/,                                                            &
+'@    The calculation will not be run.',/,                        &
+'@',/,                                                            &
+'@    Check the programming in usphyv (and the test when',/,      &
+'@      defining ivart).',/,                                      &
+'@    Check the definition of calculation variables in',/,        &
+'@      usini1. If a scalar should represent the,',/,             &
+'@      temperature, check that iscalt has been defined',/,       &
+'@',/,                                                            &
+'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
+'@',/)
+
+#endif
+
 !----
-! FIN
+! End
 !----
 
 return
diff --git a/users/base/ussatc.f90 b/users/base/ussatc.f90
index 70d7b29..bfcbdbb 100644
--- a/users/base/ussatc.f90
+++ b/users/base/ussatc.f90
@@ -112,25 +112,25 @@ nbcsat = 2
 
 do ii = 1, nbcsat
 
-  ! Example: coupling  with instance named 'SATURNE_01'
+  ! Example: coupling  with instance number 1
   !    - coupled faces of color 3 or 4
   !    - all cells available as localization support for instance 'SATURNE_01'
 
   if (ii .eq. 1) then
 
-    namsat = 'SATURNE_01'
+    numsat = 1
 
     call defsat(numsat, namsat, 'all[]', ' ', ' ', '3 or 4', iwarns)
     !==========
 
-  ! Example: coupling  with instance named 'SATURNE_02'
+  ! Example: coupling  with instance number 3
   !    - coupled faces of group 'coupled_faces'
   !    - coupled cells (every cell overlapping the distant mesh)
   !    - all cells available as localization support for instance 'SATURNE_02'
 
-  else if (ii .eq. 1) then
+  else if (ii .eq. 2) then
 
-    namsat = 'SATURNE_02'
+    numsat = 3
 
     call defsat(numsat, namsat, 'all[]', ' ', 'all[]', 'coupled_faces', iwarns)
     !==========
diff --git a/users/cfbl/uscfpv.f90 b/users/cfbl/uscfpv.f90
index 9ac4b4d..0599ea0 100644
--- a/users/cfbl/uscfpv.f90
+++ b/users/cfbl/uscfpv.f90
@@ -51,56 +51,56 @@ subroutine uscfpv &
 
 !    User subroutine.
 
-!    Set (variable) physical properties for the compressible flow scheme. 
+!    Set (variable) physical properties for the compressible flow scheme.
 
 
 ! Description
 ! ===========
 
-! This subroutine replaces the user subroutine 'usphyv' for the 
-! compressible flow scheme. 
+! This subroutine replaces the user subroutine 'usphyv' for the
+! compressible flow scheme.
 
-! This subroutine is called at the beginning of each time step. 
+! This subroutine is called at the beginning of each time step.
 
-! At the very first time step (not at restart), the only variables that 
-! have been initialized are those provided: 
+! At the very first time step (not at restart), the only variables that
+! have been initialized are those provided:
 !   - in the GUI and in the user subroutines 'usini1' and 'uscfx2'; ex.:
 !     . the density             (set to ro0(iphas))
-!     . the molecular viscosity (set to viscl0(iphas)) 
-!     . the volumetric molecular viscosity (set to viscv0(iphas)) 
-!     . the molecular thermal conductivity (set to visls0(itempk(iphas))) 
+!     . the molecular viscosity (set to viscl0(iphas))
+!     . the volumetric molecular viscosity (set to viscv0(iphas))
+!     . the molecular thermal conductivity (set to visls0(itempk(iphas)))
 !   - in the user subroutines 'usiniv' and 'uscfxi'; ex.:
-!     . the unknown variables (null by default)  
+!     . the unknown variables (null by default)
 
-! This subroutine allows the user to set the cell values for: 
+! This subroutine allows the user to set the cell values for:
 !   - the molecular viscosity                            viscl  kg/(m s)
-!   - the isobaric specific heat (cp=dh/dT|P)            cp     J/(kg degree) 
+!   - the isobaric specific heat (cp=dh/dT|P)            cp     J/(kg degree)
 !   - the molecular thermal conductivity                 lambda W/(m degree)
 !   - the molecular diffusivity for user-defined scalars viscls kg/(m s)
 
 
 ! Warnings
-! ======== 
+! ========
 
-! The density ** must not ** be set here: for the compressible scheme, 
+! The density ** must not ** be set here: for the compressible scheme,
 ! it is one of the unknowns, and it can be initialized as such in the user
 ! subroutine 'uscfxi' (rtp array).
 
-! The turbulent viscosity ** must not ** be modified here (to modify this 
+! The turbulent viscosity ** must not ** be modified here (to modify this
 ! variable, use the user subroutine 'usvist')
 
-! To set a variable isobaric specific heat, the integer icp(iphas) must 
-! have been set to 1: the value for icp is set automatically in the  
-! subroutine 'uscfth', depending on the thermodynamics laws selected   
-! by the user.  
+! To set a variable isobaric specific heat, the integer icp(iphas) must
+! have been set to 1: the value for icp is set automatically in the
+! subroutine 'uscfth', depending on the thermodynamics laws selected
+! by the user.
 
-! To set a variable diffusivity for a given user-defined scalar, the 
-! variable ivisls(scalar_number) must have been set to 1 in the user 
-! subroutine 'usini1' or in the GUI (otherwise, a memory problem is 
-! expected). 
+! To set a variable diffusivity for a given user-defined scalar, the
+! variable ivisls(scalar_number) must have been set to 1 in the user
+! subroutine 'usini1' or in the GUI (otherwise, a memory problem is
+! expected).
 
-! Examples are provided in the present subroutine (but they do not have 
-! any physical signification). 
+! Examples are provided in the present subroutine (but they do not have
+! any physical signification).
 
 
 ! Cells identification
@@ -111,7 +111,7 @@ subroutine uscfpv &
 ! but a more thorough description can be found in the user guide.
 
 ! The type of the boundary faces at the previous time step is available
-! (except at the first time step, since the arrays itypfb and itrifb have 
+! (except at the first time step, since the arrays itypfb and itrifb have
 ! not yet been set);
 
 
@@ -264,7 +264,7 @@ endif
 ! TEST_TO_REMOVE_FOR_USE_OF_SUBROUTINE_END
 
 !===============================================================================
-! 1. Mandatory initializations 
+! 1. Mandatory initializations
 !===============================================================================
 
 ! --- Memory initialization
@@ -276,11 +276,11 @@ idebra = idbra0
 
 ! Warning: the examples provided below are physically meaningless.
 ! =======
- 
-! These examples must be adapted by the user. Hence, the default 
-! (library reference) version stops immediately after each example 
-! (the 'call csexit(1)' directive must be discarded to use the 
-! portion of code).   
+
+! These examples must be adapted by the user. Hence, the default
+! (library reference) version stops immediately after each example
+! (the 'call csexit(1)' directive must be discarded to use the
+! portion of code).
 
 ! It is adviced to discard all the examples that are not necessary, so
 ! as to minimize the risk of error.
@@ -292,7 +292,7 @@ idebra = idbra0
 ! Ex. 2: molecular volumetric viscosity varying with temperature
 ! Ex. 3: isobaric specific heat varying with temperature
 ! Ex. 4: molecular thermal conductivity varying with temperature
-! Ex. 5: molecular diffusivity of user-defined scalars varying with temperature 
+! Ex. 5: molecular diffusivity of user-defined scalars varying with temperature
 
 !===============================================================================
 
@@ -300,17 +300,17 @@ idebra = idbra0
 !===============================================================================
 ! Ex. 1: molecular viscosity varying with temperature
 ! =====
-!    The values of the molecular viscosity are provided as a function of  
-!    the temperature. All variables are evaluated at the cell centres. 
-!    The same treatment is applied for all values of iphas. 
+!    The values of the molecular viscosity are provided as a function of
+!    the temperature. All variables are evaluated at the cell centres.
+!    The same treatment is applied for all values of iphas.
 !===============================================================================
 
 ! --- Loop on iphas
 do iphas = 1, nphas
-  
+
 ! --- Rank of the temperature of the current phase iphas in the array 'rtp'
-!     To refer to the user-defined scalar number 2 instead, for example, use 
-!     ivart = isca(2) 
+!     To refer to the user-defined scalar number 2 instead, for example, use
+!     ivart = isca(2)
 
   ivart = isca(itempk(iphas))
 
@@ -319,8 +319,8 @@ do iphas = 1, nphas
 
   ipcvis = ipproc(iviscl(iphas))
 
-! --- User-defined coefficients for the selected law. 
-!     The values hereafter are provided as a mere example. They 
+! --- User-defined coefficients for the selected law.
+!     The values hereafter are provided as a mere example. They
 !     are physically meaningless.
 
   varam = -3.4016d-9
@@ -329,9 +329,9 @@ do iphas = 1, nphas
   vardm =  1.6935d-3
 
 ! --- Molecular dynamic viscosity mu at the cell centres, kg/(m s)
-!     In this example, mu is provided as a function of the temperature T: 
+!     In this example, mu is provided as a function of the temperature T:
 !       mu(T)              =    T  *( T  *( am  * T +  bm  )+ cm  )+ dm
-!     that is: 
+!     that is:
 !       propce(iel,ipcvis) =   xrtp*(xrtp*(varam*xrtp+varbm)+varcm)+vardm
 
   do iel = 1, ncel
@@ -342,7 +342,7 @@ do iphas = 1, nphas
 
 
 enddo
-! --- End of the loop on iphas 
+! --- End of the loop on iphas
 
 
 ! --- Discard the following test so that the code do not stop
@@ -355,17 +355,17 @@ endif
 !===============================================================================
 ! Ex. 2: molecular volumetric viscosity varying with temperature
 ! =====
-!    The values of the molecular volumetric viscosity are provided as a function 
-!    of the temperature. All variables are evaluated at the cell centres. 
-!    The same treatment is applied for all values of iphas. 
+!    The values of the molecular volumetric viscosity are provided as a function
+!    of the temperature. All variables are evaluated at the cell centres.
+!    The same treatment is applied for all values of iphas.
 !===============================================================================
 
 ! --- Loop on iphas
 do iphas = 1, nphas
 
-! --- Rank of the temperature for the current phase iphas in the array 'rtp'  
-!     To refer to the user-defined scalar number 2 instead, for example, use 
-!     ivart = isca(2) 
+! --- Rank of the temperature for the current phase iphas in the array 'rtp'
+!     To refer to the user-defined scalar number 2 instead, for example, use
+!     ivart = isca(2)
 
   ivart = isca(itempk(iphas))
 
@@ -385,8 +385,8 @@ do iphas = 1, nphas
     call csexit (1)
   endif
 
-! --- User-defined coefficients for the selected law. 
-!     The values provided hereafter are provided as a mere example. They 
+! --- User-defined coefficients for the selected law.
+!     The values provided hereafter are provided as a mere example. They
 !     are physically meaningless.
 
   varam = -3.4016d-9
@@ -395,9 +395,9 @@ do iphas = 1, nphas
   vardm =  1.6935d-3
 
 ! --- Molecular dynamic volumetric viscosity kappa at the cell centres, kg/(m s)
-!     In this example, kappa is provided as a function of the temperature T: 
+!     In this example, kappa is provided as a function of the temperature T:
 !       kappa(T)           =    T  *( T  *( am  * T +  bm  )+ cm  )+ dm
-!     that is: 
+!     that is:
 !       propce(iel,ipcvsv) =   xrtp*(xrtp*(varam*xrtp+varbm)+varcm)+vardm
 
   do iel = 1, ncel
@@ -407,7 +407,7 @@ do iphas = 1, nphas
   enddo
 
 enddo
-! --- End of the loop on iphas 
+! --- End of the loop on iphas
 
 
 ! --- Discard the following test so that the code do not stop
@@ -421,29 +421,29 @@ endif
 ! Ex. 3: isobaric specific heat varying with temperature
 ! =====
 !    The values of the isobaric specific heat values are provided as a function
-!    of the temperature. All variables are evaluated at the cell centres. 
-!    The same treatment is applied for all values of iphas. 
+!    of the temperature. All variables are evaluated at the cell centres.
+!    The same treatment is applied for all values of iphas.
 !===============================================================================
 
 ! Warning:
 ! =======
-! do not discard the call to the subroutine 'usthht' at the end of this 
-! example: its purpose is to calculate the isochoric specific heat. 
-! Indeed, this variable needs to be computed from the isobaric specific heat 
-! using the thermodynamics laws. 
+! do not discard the call to the subroutine 'usthht' at the end of this
+! example: its purpose is to calculate the isochoric specific heat.
+! Indeed, this variable needs to be computed from the isobaric specific heat
+! using the thermodynamics laws.
 
 ! --- Loop on iphas
 do iphas = 1, nphas
 
-! --- Rank of the temperature for the current phase iphas in the array 'rtp'  
-!     To refer to the user-defined scalar number 2 instead, for example, use 
-!     ivart = isca(2) 
+! --- Rank of the temperature for the current phase iphas in the array 'rtp'
+!     To refer to the user-defined scalar number 2 instead, for example, use
+!     ivart = isca(2)
 
   ivart = isca(itempk(iphas))
 
-! --- Rank 'ipcpp' of the isobaric specific heat for the current phase  
-!     iphas in the array 'propce' (physical properties at the cell 
-!     centers) 
+! --- Rank 'ipcpp' of the isobaric specific heat for the current phase
+!     iphas in the array 'propce' (physical properties at the cell
+!     centers)
 
   if(icp(iphas).gt.0) then
     ipccp  = ipproc(icp   (iphas))
@@ -451,7 +451,7 @@ do iphas = 1, nphas
     ipccp  = 0
   endif
 
-! --- Stop if the iobaric or iochoric specific heat (cp or cv) has not 
+! --- Stop if the iobaric or iochoric specific heat (cp or cv) has not
 !     been defined as variable
 
   if(ipccp.le.0) then
@@ -463,17 +463,17 @@ do iphas = 1, nphas
     call csexit (1)
   endif
 
-! --- User-defined coefficients for the selected law. 
-!     The values provided hereafter are provided as a mere example. They 
+! --- User-defined coefficients for the selected law.
+!     The values provided hereafter are provided as a mere example. They
 !     are physically meaningless.
 
   varac = 0.00001d0
   varbc = 1000.0d0
 
 ! --- Isobaric specific heat cp at the cell centres, J/(kg degree)
-!     In this example, cp is provided as a function of the temperature T: 
+!     In this example, cp is provided as a function of the temperature T:
 !       cp(T)              =      ac * T  + ab
-!     that is: 
+!     that is:
 !       propce(iel,ipccp ) =    varac*xrtp+varbc
 
   do iel = 1, ncel
@@ -481,8 +481,8 @@ do iphas = 1, nphas
     propce(iel,ipccp ) = varac*xrtp + varbc
   enddo
 
-! --- The isochoric specific heat is deduced from the isobaric specific 
-!     heat using the subroutine 'uscfth'. 
+! --- The isochoric specific heat is deduced from the isobaric specific
+!     heat using the subroutine 'uscfth'.
 
   iccfth = 432
   imodif = 0
@@ -506,7 +506,7 @@ do iphas = 1, nphas
    rdevel , rtuser , ra     )
 
 enddo
-! --- End of the loop on iphas 
+! --- End of the loop on iphas
 
 ! --- Discard the following test so that the code do not stop
 if(1.eq.1) then
@@ -518,23 +518,23 @@ endif
 !===============================================================================
 ! Ex. 4: molecular thermal conductivity varying with temperature
 ! =====
-!    The values of the molecular thermal conductivity are provided as a function 
-!    of the temperature. All variables are evaluated at the cell centres. 
-!    The same treatment is applied for all values of iphas. 
+!    The values of the molecular thermal conductivity are provided as a function
+!    of the temperature. All variables are evaluated at the cell centres.
+!    The same treatment is applied for all values of iphas.
 !===============================================================================
 
 ! --- Loop on iphas
 do iphas = 1, nphas
 
-! --- Rank of the temperature for the current phase iphas in the array 'rtp'  
-!     To refer to the user-defined scalar number 2 instead, for example, use 
-!     ivart = isca(2) 
+! --- Rank of the temperature for the current phase iphas in the array 'rtp'
+!     To refer to the user-defined scalar number 2 instead, for example, use
+!     ivart = isca(2)
 
   ivart = isca(itempk(iphas))
 
-! --- Rank 'ipcvsl' of the olecular thermal conductivity for the current   
-!     phase iphas in the array 'propce' (physical properties at the cell 
-!     centers) 
+! --- Rank 'ipcvsl' of the olecular thermal conductivity for the current
+!     phase iphas in the array 'propce' (physical properties at the cell
+!     centers)
 
   if(ivisls(itempk(iphas)).gt.0) then
     ipcvsl = ipproc(ivisls(itempk(iphas)))
@@ -542,7 +542,7 @@ do iphas = 1, nphas
     ipcvsl = 0
   endif
 
-! --- Stop if the molecular thermal conductivity has not 
+! --- Stop if the molecular thermal conductivity has not
 !     been defined as variable
 
   if(ipcvsl.le.0) then
@@ -551,8 +551,8 @@ do iphas = 1, nphas
     call csexit (1)
   endif
 
-! --- User-defined coefficients for the selected law. 
-!     The values provided hereafter are provided as a mere example. They 
+! --- User-defined coefficients for the selected law.
+!     The values provided hereafter are provided as a mere example. They
 !     are physically meaningless.
 
   varal = -3.3283d-7
@@ -561,9 +561,9 @@ do iphas = 1, nphas
   vardl =  0.58923d0
 
 ! --- Molecular thermal conductivity lambda at the cell centres, W/(m degree)
-!     In this example, lambda is provided as a function of the temperature T: 
+!     In this example, lambda is provided as a function of the temperature T:
 !       lambda(T)          =    T  *( T  *( al  * T +  bl  )+ cl  )+ dl
-!     that is: 
+!     that is:
 !       propce(iel,ipcvsl) =   xrtp*(xrtp*(varal*xrtp+varbl)+varcl)+vardl
 
   do iel = 1, ncel
@@ -574,7 +574,7 @@ do iphas = 1, nphas
 
 
 enddo
-! --- End of the loop on iphas 
+! --- End of the loop on iphas
 
 
 ! --- Discard the following test so that the code do not stop
@@ -585,50 +585,50 @@ endif
 
 
 !===============================================================================
-! Ex. 5: molecular diffusivity of user-defined scalars varying with temperature 
-! ===== 
+! Ex. 5: molecular diffusivity of user-defined scalars varying with temperature
+! =====
 !    The molecular diffusivity can be set for all the user-defined scalars
 !    ** except **:
-!      - temperature and enthalpy (already dealt with above: for these 
+!      - temperature and enthalpy (already dealt with above: for these
 !        variables, the 'diffusivity' is the thermal conductivity)
-!      - variances of the fluctuations of another scalar variable (the 
-!        diffusivity is assumed to be equal to that of the associated 
+!      - variances of the fluctuations of another scalar variable (the
+!        diffusivity is assumed to be equal to that of the associated
 !        scalar)
 !    The values of the molecular diffusivity are provided as a function
-!    of the temperature. All variables are evaluated at the cell centres. 
+!    of the temperature. All variables are evaluated at the cell centres.
 !===============================================================================
 
 ! --- Loop on the scalars
 do ii = 1, nscaus
 
-! --- Rank of the ii-th scalar in the list of all scalars 
+! --- Rank of the ii-th scalar in the list of all scalars
   iscal = ii
 
 
-! --- If the scalar is the temperature, it is marked by ith = 1 
-!     so that it will be skipped. 
+! --- If the scalar is the temperature, it is marked by ith = 1
+!     so that it will be skipped.
 
   ith = 0
   do iphas = 1, nphas
     if (iscal.eq.itempk(iphas)) ith = 1
   enddo
 
-! --- If the variable represents the variance of the fluctuations of 
+! --- If the variable represents the variance of the fluctuations of
 !     another scalar variable (iscavr <= 0), it is simply skipped.
 
   if (ith.eq.0.and.iscavr(iscal).le.0) then
 
-! --- Here, iscal points to any scalar variable except the temperature, 
-!     the enthalpy and the variance of the fluctuations of another 
-!     scalar variable. 
+! --- Here, iscal points to any scalar variable except the temperature,
+!     the enthalpy and the variance of the fluctuations of another
+!     scalar variable.
 
-! --- Rank of the temperature for the current phase iphas in the array 'rtp'  
-!     To refer to the user-defined scalar number 2 instead, for example, use 
-!     ivart = isca(2) 
+! --- Rank of the temperature for the current phase iphas in the array 'rtp'
+!     To refer to the user-defined scalar number 2 instead, for example, use
+!     ivart = isca(2)
 
   ivart = isca(itempk(iphas))
 
-! --- Rank 'ipcvsl' of the molecular diffusivity of the current scalar iscal 
+! --- Rank 'ipcvsl' of the molecular diffusivity of the current scalar iscal
 !     in the array 'propce' (physical properties at the cell centers)
 
     if(ivisls(iscal).gt.0) then
@@ -644,8 +644,8 @@ do ii = 1, nscaus
       call csexit (1)
     endif
 
-! --- User-defined coefficients for the selected law. 
-!     The values provided hereafter are provided as a mere example. They 
+! --- User-defined coefficients for the selected law.
+!     The values provided hereafter are provided as a mere example. They
 !     are physically meaningless.
 
     varal = -3.3283d-7
@@ -654,9 +654,9 @@ do ii = 1, nscaus
     vardl =  0.58923d0
 
 ! --- Molecular diffusivity lambda at the cell centres, kg/(m s)
-!     In this example, lambda is provided as a function of the temperature T: 
+!     In this example, lambda is provided as a function of the temperature T:
 !       lambda(T)          =    T  *( T  *( al  * T +  bl  )+ cl  )+ dl
-!     that is: 
+!     that is:
 !       propce(iel,ipcvsl) =   xrtp*(xrtp*(varal*xrtp+varbl)+varcl)+vardl
 
     do iel = 1, ncel
@@ -667,10 +667,10 @@ do ii = 1, nscaus
 
 
   endif
-! --- End of the tests on ith and iscavr 
+! --- End of the tests on ith and iscavr
 
 enddo
-! --- End of the loop on the scalars  
+! --- End of the loop on the scalars
 
 
 ! --- Discard the following test so that the code do not stop
@@ -690,7 +690,7 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in computation of physical properties',/,  &
 '@    =======',/,                                                 &
-'@     The data is inconsistent',/,                               &  
+'@     The data is inconsistent',/,                               &
 '@',/,                                                            &
 '@     For phase ',i10,/,                                         &
 '@       in the GUI or in the user subroutine ''usini1'', the',/, &
@@ -698,9 +698,9 @@ endif
 '@         uniform in space: icp(',i10   ,') = ',i10   ,/,        &
 '@       in the user subroutine ''uscfpv'', however, it is',/,    &
 '@         assumed to be potentially non uniform in space.',/,    &
-'@',/,                                                            & 
+'@',/,                                                            &
 '@  The calculation will not be run.',/,                          &
-'@',/,                                                            & 
+'@',/,                                                            &
 '@  Ensure consistency by modifying the GUI input data or the',/, &
 '@    user subroutines ''usini1'' or ''uscfpv''.',/,              &
 '@',/,                                                            &
@@ -712,7 +712,7 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in computation of physical properties',/,  &
 '@    =======',/,                                                 &
-'@     The data is inconsistent',/,                               &  
+'@     The data is inconsistent',/,                               &
 '@',/,                                                            &
 '@     For phase ',i10,/,                                         &
 '@       in the GUI or in the user subroutine ''usini1'', the',/, &
@@ -720,9 +720,9 @@ endif
 '@         uniform in space: icv(',i10   ,') = ',i10   ,/,        &
 '@       in the user subroutine ''uscfpv'', however, it is',/,    &
 '@         assumed to be potentially non uniform in space.',/,    &
-'@@',/,                                                           & 
+'@@',/,                                                           &
 '@  The calculation will not be run.',/,                          &
-'@',/,                                                            & 
+'@',/,                                                            &
 '@  Ensure consistency by modifying the GUI input data or the',/, &
 '@    user subroutines ''usini1'' or ''uscfpv''.',/,              &
 '@',/,                                                            &
@@ -734,7 +734,7 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in computation of physical properties',/,  &
 '@    =======',/,                                                 &
-'@     The data is inconsistent',/,                               &  
+'@     The data is inconsistent',/,                               &
 '@',/,                                                            &
 '@     For the scalar ',i10,/,                                    &
 '@       in the GUI or in the user subroutine ''usini1'', the',/, &
@@ -742,9 +742,9 @@ endif
 '@         uniform in space: ivisls(',i10   ,') = ',i10   ,/,     &
 '@       in the user subroutine ''uscfpv'', however, it is',/,    &
 '@         assumed to be potentially non uniform in space.',/,    &
-'@@',/,                                                           & 
+'@@',/,                                                           &
 '@  The calculation will not be run.',/,                          &
-'@',/,                                                            & 
+'@',/,                                                            &
 '@  Ensure consistency by modifying the GUI input data or the',/, &
 '@    user subroutines ''usini1'' or ''uscfpv''.',/,              &
 '@',/,                                                            &
@@ -756,7 +756,7 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in computation of physical properties',/,  &
 '@    =======',/,                                                 &
-'@     The data is inconsistent',/,                               &  
+'@     The data is inconsistent',/,                               &
 '@',/,                                                            &
 '@     For phase ',i10,/,                                         &
 '@       in the user subroutine ''uscfx2'', the molecular',/,     &
@@ -764,9 +764,9 @@ endif
 '@         uniform in space: iviscv(',i10   ,') = ',i10   ,/,     &
 '@       in the user subroutine ''uscfpv'', however, it is',/,    &
 '@         assumed to be potentially non uniform in space.',/,    &
-'@@',/,                                                           & 
+'@@',/,                                                           &
 '@  The calculation will not be run.',/,                          &
-'@',/,                                                            & 
+'@',/,                                                            &
 '@  Ensure consistency by modifying the user subroutines',/,      &
 '@    ''uscfx2'' or ''uscfpv''.',/,                               &
 '@',/,                                                            &
@@ -785,11 +785,11 @@ endif
 '@       ensure that all the default examples provided in the',/, &
 '@       reference version of the user subroutine have been',/,   &
 '@       discarded. It shall also be checked that there is no',/, &
-'@       remaining stopping test at the end of the examples ',/,  & 
+'@       remaining stopping test at the end of the examples ',/,  &
 '@       that have been retained.',/,                             &
-'@@',/,                                                           & 
+'@@',/,                                                           &
 '@  The calculation will not be run.',/,                          &
-'@',/,                                                            & 
+'@',/,                                                            &
 '@  Check and modify the user subroutine ''uscfpv''.',/,          &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
diff --git a/users/cfbl/uscfth.f90 b/users/cfbl/uscfth.f90
index 321ed99..5c7ebd4 100644
--- a/users/cfbl/uscfth.f90
+++ b/users/cfbl/uscfth.f90
@@ -52,16 +52,16 @@ subroutine uscfth &
 
 !    User subroutine.
 
-!    Define thermodynamic laws (especially for the compressible flow scheme). 
+!    Define thermodynamic laws (especially for the compressible flow scheme).
 
-!    This user subroutine is mandatory for the compressible flow scheme. 
+!    This user subroutine is mandatory for the compressible flow scheme.
 
 
 ! Introduction
 ! ============
 
-! This user subroutine allows to define all physical properties and 
-! variables, through the implementation of thermodynamic laws. 
+! This user subroutine allows to define all physical properties and
+! variables, through the implementation of thermodynamic laws.
 
 
 ! Avalable thermodynamic laws
@@ -75,84 +75,84 @@ subroutine uscfth &
 ! Implemented calculations
 ! ========================
 
-! This user subroutine implements the computation of several quantities. 
-! Each calculation has to be explicitly implemented in the appropriate 
-! section below (already done for perfect gas). 
+! This user subroutine implements the computation of several quantities.
+! Each calculation has to be explicitly implemented in the appropriate
+! section below (already done for perfect gas).
 
 
 ! Selection of the quantity to return
 ! ===================================
 
-! When calling the user subroutine, the integer 'iccfth' specifies which 
+! When calling the user subroutine, the integer 'iccfth' specifies which
 ! calculation has to be performed (and which quantity has to be returned).
-! The values for 'iccfth' for each case are provided below. 
+! The values for 'iccfth' for each case are provided below.
 ! For some configurations, two systems of references are used for 'iccfth'
-! (this is useful to make tests easier to implement in the calling 
-! subroutines): both systems are explained hereafter for information. 
+! (this is useful to make tests easier to implement in the calling
+! subroutines): both systems are explained hereafter for information.
 
-! First system: 
+! First system:
 
-!   the variables are referred to using an index i: 
-!     Variable  P  rho  T   e   h   s  'internal energy - CvT' 
-!        Index  1   2   3   4   5   6              7      
+!   the variables are referred to using an index i:
+!     Variable  P  rho  T   e   h   s  'internal energy - CvT'
+!        Index  1   2   3   4   5   6              7
 
 !   iccfth is as follows, depending on which quantity needs to be computed:
-!     - compute all variables at cell centers from variable i 
-!                                              and variable j (i<j): 
-!               => iccfth = 10*i+j 
-!     - compute all variables at boundary faces from variable i 
-!                                                and variable j (i<j): 
-!               => iccfth = 10*i+j+900 
- 
-! Second system:  
-
-!   the variables are referred to using a different index i: 
+!     - compute all variables at cell centers from variable i
+!                                              and variable j (i<j):
+!               => iccfth = 10*i+j
+!     - compute all variables at boundary faces from variable i
+!                                                and variable j (i<j):
+!               => iccfth = 10*i+j+900
+
+! Second system:
+
+!   the variables are referred to using a different index i:
 !     Variable  P  rho  T  e  s
 !        Index  2   3   5  7  13
 
 !   iccfth is as follows, depending on which quantity needs to be computed:
-!     - compute all variables at cell centers from variable i 
-!                                              and variable j (i<j): 
-!               => iccfth = i*j*10000 
-!     - compute all variables at boundary faces from variable i 
-!                                                and variable j (i<j): 
-!               => iccfth = i*j*10000+900 
+!     - compute all variables at cell centers from variable i
+!                                              and variable j (i<j):
+!               => iccfth = i*j*10000
+!     - compute all variables at boundary faces from variable i
+!                                                and variable j (i<j):
+!               => iccfth = i*j*10000+900
 
-! Other quantities: 
+! Other quantities:
 
 !   the variables are referred to using the index of the first system.
 !   iccfth is defined as follows:
-!     - compute variable i at cell centers (for s and 'internal energy-CvT') 
+!     - compute variable i at cell centers (for s and 'internal energy-CvT')
 !               => iccfth = i
 !                                   \partial(variable i)|
-!     - compute partial derivative  --------------------|           
-!                                   \partial(variable j)|variable k  
-!               => iccfth = 100*i+10*j+k 
+!     - compute partial derivative  --------------------|
+!                                   \partial(variable j)|variable k
+!               => iccfth = 100*i+10*j+k
 !     - compute boundary conditions, resp. symmetry, wall, inlet, outlet:
 !               => iccfth = 91, 92, 93, 94
 
 
-! Values of iccfth 
+! Values of iccfth
 ! ================
 
-! To summarize, the values for iccfth are as follows: 
+! To summarize, the values for iccfth are as follows:
 
-!   Values at the cell centers: 
+!   Values at the cell centers:
 
 !   -> set calculation options (cst/variable cp)   : iccfth = -1
 !   -> set default initialization                  : iccfth =  0
 !   -> calculate gamma                             : iccfth =  1
 !   -> verification of the density                 : iccfth = -2
 !   -> verification of the energy                  : iccfth = -4
-!   -> calculation of temperature and energy 
+!   -> calculation of temperature and energy
 !                     from pressure and density    : iccfth =  12 or  60000
-!   -> calculation of density and energy 
+!   -> calculation of density and energy
 !                     from pressure and temperature: iccfth =  13 or 100000
-!   -> calculation of density and temperature 
+!   -> calculation of density and temperature
 !                     from pressure and energy     : iccfth =  14 or 140000
-!   -> calculation of pressure and energy 
+!   -> calculation of pressure and energy
 !                     from density and temperature : iccfth =  23 or 150000
-!   -> calculation of pressure and temperature 
+!   -> calculation of pressure and temperature
 !                     from density and energy      : iccfth =  24 or 210000
 !
 !                      2    dP |
@@ -172,23 +172,23 @@ subroutine uscfth &
 !
 !   Values at the boundary faces
 !
-!   -> calculation of the boundary conditions:  
+!   -> calculation of the boundary conditions:
 !     - symmetry                                   : iccfth =  90
 !     - wall                                       : iccfth =  91
 !     - inlet                                      : iccfth =  92
 !     - outlet                                     : iccfth =  93
 !     - different outlet,not implemented yet       : iccfth =  94
 !
-!   -> calculation of the variables at the faces for boundary conditions:  
-!     - temperature and energy 
+!   -> calculation of the variables at the faces for boundary conditions:
+!     - temperature and energy
 !         from pressure and density                : iccfth = 912 ou  60900
-!     - density and energy 
+!     - density and energy
 !         from pressure and temperature            : iccfth = 913 ou 100900
-!     - density and temperature 
+!     - density and temperature
 !         from pressure and energy                 : iccfth = 914 ou 140900
-!     - pressure and energy 
+!     - pressure and energy
 !         from density and temperature             : iccfth = 923 ou 150900
-!     - pressure and temperature 
+!     - pressure and temperature
 !         from density and energy                  : iccfth = 924 ou 210900
 
 
@@ -364,7 +364,7 @@ idebra = idbra0
 ! Error indicator (stop if non zero)
 ierr   = 0
 
-! Rank of the variables in their associated arrays 
+! Rank of the variables in their associated arrays
 if(iccfth.ge.0.or.iccfth.le.-2) then
   ipriph = ipr(iphas)
   irhiph = isca(irho  (iphas))
@@ -382,7 +382,7 @@ if(iccfth.ge.0.or.iccfth.le.-2) then
   iclw = iclrtp(iwiph,icoef)
 endif
 
-! For calculation of values at the cell centers, 
+! For calculation of values at the cell centers,
 !   ifac0 > indicates that the array rtp must be modified
 ! For calculation of values at the cell faces,
 !   ifac0 is the number of the current face
@@ -402,7 +402,7 @@ do iiph = 1, nphas
 enddo
 
 
-! Warning: once the thermodynamic law has been chosen, 
+! Warning: once the thermodynamic law has been chosen,
 ! =======  the remainder of the user subroutine must be modified
 
 
@@ -413,7 +413,7 @@ enddo
 if(ieos(iphas).eq.1) then
 
 !===============================================================================
-! 2.1. Parameters to be completed by the user 
+! 2.1. Parameters to be completed by the user
 !===============================================================================
 
 ! For each phase
@@ -439,10 +439,10 @@ if(ieos(iphas).eq.1) then
 
   if(iccfth.gt.0) then
 
-    ! Gamagp is supposed to be superior or equal to 1. 
-    ! It is computed at each call, even if this may seem costly, 
-    !   to be coherent with the "constant gamma" case for which this 
-    !   constant is not saved. A ''save'' instruction and a test would  
+    ! Gamagp is supposed to be superior or equal to 1.
+    ! It is computed at each call, even if this may seem costly,
+    !   to be coherent with the "constant gamma" case for which this
+    !   constant is not saved. A ''save'' instruction and a test would
     !   be sufficient to avoid computing gamagp at each call if necessary.
 
     gamagp = 1.d0 + rr/(xmasml*cp0(iphas)-rr)
@@ -452,7 +452,7 @@ if(ieos(iphas).eq.1) then
       call csexit (1)
     endif
 
-    ! Gamma is returned if required 
+    ! Gamma is returned if required
 
     if(iccfth.eq.1) then
       gamagr(1) = gamagp
@@ -461,12 +461,12 @@ if(ieos(iphas).eq.1) then
   endif
 
 
-! --- Calculation options: constant Cp and Cv (perfect gas) 
+! --- Calculation options: constant Cp and Cv (perfect gas)
 
   if(iccfth.eq.-1) then
 
     ! The value for the isobaric specific heat Cp0 must be provided in
-    !   the user subroutine ''usini1''. The value for the isochoric 
+    !   the user subroutine ''usini1''. The value for the isochoric
     !   specific heat Cv0 is calculated in a subsequent section (from Cp0)
 
     icp(iphas) = 0
@@ -475,7 +475,7 @@ if(ieos(iphas).eq.1) then
 
 ! --- Default initializations (before uscfxi)
 
-!     T0 is positive (this assumption has been checked in 
+!     T0 is positive (this assumption has been checked in
 !       the user programme 'verini')
 
   elseif(iccfth.eq.0) then
@@ -496,8 +496,8 @@ if(ieos(iphas).eq.1) then
 
     ! If the density is lower or equal to zero: clipping, write and stop.
     !   Indeed, if this is the case, the thermodynamic computations will
-    !   most probably fail. 
-    ! This call is done at the end of the density calculation (after 
+    !   most probably fail.
+    ! This call is done at the end of the density calculation (after
     !   a classical clipping and before parallel communications).
 
     ierr = 0
@@ -516,13 +516,13 @@ if(ieos(iphas).eq.1) then
     endif
 
 
-! --- Verification of the energy 
+! --- Verification of the energy
 
   elseif(iccfth.eq.-4) then
 
     ! If the total energy <= zero: clipping, write and stop
     !   Indeed, if this is the case, the thermodynamic computations will
-    !   most probably fail. 
+    !   most probably fail.
 
     ierr = 0
     do iel = 1, ncel
@@ -558,8 +558,8 @@ if(ieos(iphas).eq.1) then
         write(nfecra,3010)rtp(iel,irhiph),iel
       endif
     enddo
-    ! Stop if a negative value is detected (since the density has been 
-    ! provided by the user, one potential cause is a wrong user 
+    ! Stop if a negative value is detected (since the density has been
+    ! provided by the user, one potential cause is a wrong user
     ! initialization)
     if(ierr.eq.1) then
       call csexit (1)
@@ -574,7 +574,7 @@ if(ieos(iphas).eq.1) then
                                        + rtp(iel,iwiph)**2 )
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,itkiph) = sorti1(iel)
@@ -594,8 +594,8 @@ if(ieos(iphas).eq.1) then
         write(nfecra,2010)rtp(iel,itkiph),iel
       endif
     enddo
-    ! Stop if a negative value is detected (since the temperature has been 
-    ! provided by the user, one potential cause is a wrong user 
+    ! Stop if a negative value is detected (since the temperature has been
+    ! provided by the user, one potential cause is a wrong user
     ! initialization: a value not provided in Kelvin for example)
     if(ierr.eq.1) then
       call csexit (1)
@@ -610,7 +610,7 @@ if(ieos(iphas).eq.1) then
                                        + rtp(iel,iwiph)**2 )
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,irhiph) = sorti1(iel)
@@ -636,7 +636,7 @@ if(ieos(iphas).eq.1) then
       sorti2(iel) = xmasml * (gamagp-1.d0) * enint / rr
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,irhiph) = sorti1(iel)
@@ -658,7 +658,7 @@ if(ieos(iphas).eq.1) then
                                        + rtp(iel,iwiph)**2 )
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,ipriph) = sorti1(iel)
@@ -684,7 +684,7 @@ if(ieos(iphas).eq.1) then
       sorti2(iel) = xmasml * (gamagp-1.d0) * enint / rr
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,ipriph) = sorti1(iel)
@@ -699,8 +699,8 @@ if(ieos(iphas).eq.1) then
 
   elseif(iccfth.eq.126) then
 
-    ! Verification of the values of the density 
-    !   This test can be discarded to reduce the CPU time (if 
+    ! Verification of the values of the density
+    !   This test can be discarded to reduce the CPU time (if
     !     density is <= 0, the calculation will simply fail)
     !   It is discarded here with iutile = 0
     iutile = 0
@@ -727,7 +727,7 @@ if(ieos(iphas).eq.1) then
   elseif(iccfth.eq.162) then
 
     ! Verification of the values of the density
-    !   This test can be discarded to reduce the CPU time (if 
+    !   This test can be discarded to reduce the CPU time (if
     !     density is <= 0, the calculation will simply fail)
     !   It is discarded here with iutile = 0
     iutile = 0
@@ -748,7 +748,7 @@ if(ieos(iphas).eq.1) then
     enddo
 
 
-! --- Calculation of the isochoric specific heat 
+! --- Calculation of the isochoric specific heat
 
     ! It is a constant: nothing to do
 
@@ -761,7 +761,7 @@ if(ieos(iphas).eq.1) then
   elseif(iccfth.eq.6) then
 
     ! Verification of the values of the density
-    !   This test can be discarded to reduce the CPU time (if 
+    !   This test can be discarded to reduce the CPU time (if
     !     density is <= 0, the calculation will simply fail)
     ierr = 0
     do iel = 1, ncel
@@ -778,18 +778,18 @@ if(ieos(iphas).eq.1) then
     enddo
 
 
-! --- Calculation of 'internal energy - Cv.T' 
+! --- Calculation of 'internal energy - Cv.T'
 
   elseif(iccfth.eq.7) then
 
-    ! It is zero for a perfect gas 
+    ! It is zero for a perfect gas
 
-    !   At the cell centers 
+    !   At the cell centers
     do iel = 1, ncel
       sorti1(iel) = 0.d0
     enddo
 
-    !   On the boundary faces  
+    !   On the boundary faces
     do ifac = 1, nfabor
       sorti2(ifac) = 0.d0
     enddo
@@ -804,7 +804,7 @@ if(ieos(iphas).eq.1) then
     ifac = ifac0
     iel  = ifabor(ifac)
 
-    ! Calculation of the Mach number at the boundary face, using the 
+    ! Calculation of the Mach number at the boundary face, using the
     !   cell center velocity projected on the vector normal to the boundary
     xmach =                                                       &
          ( rtp(iel,iuiph)*surfbo(1,ifac)                          &
@@ -812,13 +812,13 @@ if(ieos(iphas).eq.1) then
          + rtp(iel,iwiph)*surfbo(3,ifac) ) / ra(isrfbn+ifac-1)    &
          / sqrt( gamagp * rtp(iel,ipriph) / rtp(iel,irhiph) )
 
-    ! Pressure 
+    ! Pressure
 
-    !   A Neumann boundary condition is used. This does not allow to use 
-    !     the Rusanov scheme, but some stabilization effect is expected. 
-    !     A test based on the value of coefb at the previous time step 
-    !     is implemented to avoid oscillating between a rarefaction 
-    !     situation and a shock configuration from one time step to the 
+    !   A Neumann boundary condition is used. This does not allow to use
+    !     the Rusanov scheme, but some stabilization effect is expected.
+    !     A test based on the value of coefb at the previous time step
+    !     is implemented to avoid oscillating between a rarefaction
+    !     situation and a shock configuration from one time step to the
     !     next.
 
     !   Rarefaction
@@ -828,8 +828,8 @@ if(ieos(iphas).eq.1) then
         coefb(ifac,iclp) = (1.d0 + (gamagp-1.d0)/2.d0 * xmach)    &
              ** (2.d0*gamagp/(gamagp-1.d0))
       else
-        ! In case the rarefaction is too strong, a zero Dirichlet value 
-        !   is used for pressure (the value of coefb is used here as an 
+        ! In case the rarefaction is too strong, a zero Dirichlet value
+        !   is used for pressure (the value of coefb is used here as an
         !   indicator and will be modified later in cfxtcl)
         coefb(ifac,iclp) = rinfin
       endif
@@ -854,36 +854,36 @@ if(ieos(iphas).eq.1) then
     ifac = ifac0
     iel  = ifabor(ifac)
 
-    ! A zero flux condition (homogeneous Neumann condition) is 
+    ! A zero flux condition (homogeneous Neumann condition) is
     !   prescribed by default.
     ! No user input required
 
 
 !  -- Subsonic inlet with prescribed density and velocity
 
-    ! The subsonic nature of the inlet is postulated. 
+    ! The subsonic nature of the inlet is postulated.
 
-    ! Further testing may be required here. Contrary to the initial 
-    !   development, an explicit Dirichlet condition is prescribed for 
-    !   pressure instead of a Neumann condition (however, the same 
-    !   physical value for pressure is used). 
+    ! Further testing may be required here. Contrary to the initial
+    !   development, an explicit Dirichlet condition is prescribed for
+    !   pressure instead of a Neumann condition (however, the same
+    !   physical value for pressure is used).
     ! The advantage of this approach is to allow the use of the Rusanov
-    !   scheme to stabilize the user defined inlet conditions. 
-    ! Moreover, with this approach, coefb does not have to be filled in 
-    !   here (it is not a major point, since coefb has to be filled in 
-    !   for the wall boundary condition anyway)  
-    ! Shall an oscillatory behavior (in time) be observed, it might be 
-    !   worth trying to add a test to avoid switching between  
-    !   rarefaction and shock from one time step to the other (just as 
-    !   for the wall boundary condition).  
-    ! The relevance of this approach remains to be demonstrated. 
+    !   scheme to stabilize the user defined inlet conditions.
+    ! Moreover, with this approach, coefb does not have to be filled in
+    !   here (it is not a major point, since coefb has to be filled in
+    !   for the wall boundary condition anyway)
+    ! Shall an oscillatory behavior (in time) be observed, it might be
+    !   worth trying to add a test to avoid switching between
+    !   rarefaction and shock from one time step to the other (just as
+    !   for the wall boundary condition).
+    ! The relevance of this approach remains to be demonstrated.
 
   elseif(iccfth.eq.92) then
 
     ifac = ifac0
     iel  = ifabor(ifac)
 
-    ! Calculation of the Mach number at the boundary face, using the 
+    ! Calculation of the Mach number at the boundary face, using the
     !   cell center velocity projected on the vector normal to the boundary
     xmachi =                                                      &
          ( rtp(iel,iuiph)*surfbo(1,ifac)                          &
@@ -916,7 +916,7 @@ if(ieos(iphas).eq.1) then
            + sqrt(1.d0 + (gamagp+1.d0)**2/16.d0*dxmach**2) )  )
     endif
 
-    ! This choice overrides the previous Rusanov choice 
+    ! This choice overrides the previous Rusanov choice
     coefa(ifac,iclp) = rtp(iel,ipriph)
 
     ! Total energy
@@ -926,15 +926,15 @@ if(ieos(iphas).eq.1) then
                 + coefa(ifac,iclv)**2 + coefa(ifac,iclw)**2)
 
 
-!  -- Subsonic inlet with prescribed mass and enthalpy flow rates 
+!  -- Subsonic inlet with prescribed mass and enthalpy flow rates
     ! The quantities prescribed are rho*u and rho*u*h
 
-    ! The subsonic nature of the inlet is postulated. 
+    ! The subsonic nature of the inlet is postulated.
 
-    ! This section remains to be implemented: stop for the moment 
+    ! This section remains to be implemented: stop for the moment
 
-    ! One may proceed as follows: 
-    !   Pressure computed with a Newton method 
+    ! One may proceed as follows:
+    !   Pressure computed with a Newton method
     !   Velocity and density computed from pressure
     !   Total energy computed from enthalpy
     !   (written on paper, to be implemented: contact the user support)
@@ -950,16 +950,16 @@ if(ieos(iphas).eq.1) then
     !==========
 
 
-!  -- Subsonic outlet 
+!  -- Subsonic outlet
 
-    ! The subsonic nature of the inlet is postulated. 
+    ! The subsonic nature of the inlet is postulated.
 
   elseif(iccfth.eq.93) then
 
     ifac = ifac0
     iel  = ifabor(ifac)
 
-    ! Rarefaction case 
+    ! Rarefaction case
     if(coefa(ifac,iclp).le.rtp(iel,ipriph)) then
 
       ! Density
@@ -994,7 +994,7 @@ if(ieos(iphas).eq.1) then
            + 0.5d0*(coefa(ifac,iclu)**2                           &
                   + coefa(ifac,iclv)**2 + coefa(ifac,iclw)**2)
 
-    ! Shock 
+    ! Shock
     else
 
       ! Density
@@ -1038,9 +1038,9 @@ if(ieos(iphas).eq.1) then
     endif
 
 
-! --- Calculation of temperature and energy from pressure and density 
+! --- Calculation of temperature and energy from pressure and density
 
-    ! It is postulated that the pressure and density values are 
+    ! It is postulated that the pressure and density values are
     !   strictly positive
 
   elseif(iccfth.eq.912.or.iccfth.eq.60900) then
@@ -1059,7 +1059,7 @@ if(ieos(iphas).eq.1) then
                  + coefa(ifac,iclv)**2 + coefa(ifac,iclw)**2 )
 
 
-! --- Calculation of density and energy from pressure and temperature 
+! --- Calculation of density and energy from pressure and temperature
 
   elseif(iccfth.eq.913.or.iccfth.eq.100900) then
 
@@ -1083,7 +1083,7 @@ if(ieos(iphas).eq.1) then
 
     ifac = ifac0
     iel  = ifabor(ifac)
-    
+
     ! Density
     coefa(ifac,iclr) = coefa(ifac,iclp)/( (gamagp-1.d0)*          &
          (coefa(ifac,icle)                                        &
@@ -1113,7 +1113,7 @@ if(ieos(iphas).eq.1) then
                  + coefa(ifac,iclv)**2 + coefa(ifac,iclw)**2 )
 
 
-! --- Calculation of pressure and temperature from density and energy 
+! --- Calculation of pressure and temperature from density and energy
 
   elseif(iccfth.eq.924.or.iccfth.eq.210900) then
 
@@ -1138,7 +1138,7 @@ if(ieos(iphas).eq.1) then
 
 
 !===============================================================================
-! 3. Perfect gas with variable gamma 
+! 3. Perfect gas with variable gamma
 !===============================================================================
 
 ! This section requires further checking and testing
@@ -1148,7 +1148,7 @@ elseif(ieos(iphas).eq.2) then
 !===============================================================================
 
 !===============================================================================
-! 3.1. Parameters to be completed by the user 
+! 3.1. Parameters to be completed by the user
 !===============================================================================
 
 
@@ -1174,7 +1174,7 @@ elseif(ieos(iphas).eq.2) then
 
     if(iccfth.gt.0) then
 
-      ! Calculation of the molar mass of the mixture at cell centers  
+      ! Calculation of the molar mass of the mixture at cell centers
       do iel = 1, ncel
         xmasmr(iel) = 1.d0 / ( rtp(iel,isca(1))/cstgr(1)          &
                              + rtp(iel,isca(2))/cstgr(2)          &
@@ -1198,7 +1198,7 @@ elseif(ieos(iphas).eq.2) then
 ! End of the examples
 
 
-! Verification of the values of gamagr: gamagr >= 1., otherwise stop 
+! Verification of the values of gamagr: gamagr >= 1., otherwise stop
 
   ierr = 0
 
@@ -1214,7 +1214,7 @@ elseif(ieos(iphas).eq.2) then
   endif
 
 
-! --- Calculation options: variable Cp and Cv  
+! --- Calculation options: variable Cp and Cv
 !     (isobaric and isochoric specific heat)
 
   if(iccfth.eq.-1) then
@@ -1225,7 +1225,7 @@ elseif(ieos(iphas).eq.2) then
     cv0(iphas) = epzero
 
 
-! Default initializations 
+! Default initializations
 
   elseif(iccfth.eq.0) then
 
@@ -1256,7 +1256,7 @@ elseif(ieos(iphas).eq.2) then
 
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,itkiph) = sorti1(iel)
@@ -1283,7 +1283,7 @@ elseif(ieos(iphas).eq.2) then
 
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,irhiph) = sorti1(iel)
@@ -1309,7 +1309,7 @@ elseif(ieos(iphas).eq.2) then
 
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,irhiph) = sorti1(iel)
@@ -1336,7 +1336,7 @@ elseif(ieos(iphas).eq.2) then
 
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,ipriph) = sorti1(iel)
@@ -1362,7 +1362,7 @@ elseif(ieos(iphas).eq.2) then
 
     enddo
 
-    ! Transfer to the array rtp 
+    ! Transfer to the array rtp
     if(imodif.gt.0) then
       do iel = 1, ncel
         rtp(iel,ipriph) = sorti1(iel)
@@ -1378,7 +1378,7 @@ elseif(ieos(iphas).eq.2) then
 
     do iel = 1, ncel
 
-      ! Verification of the positivity of the pressure 
+      ! Verification of the positivity of the pressure
       if(rtp(iel,ipriph).lt.0.d0) then
         write(nfecra,1110) iel , rtp(iel,ipriph)
         ierr = 1
@@ -1427,7 +1427,7 @@ elseif(ieos(iphas).eq.2) then
     if(ierr.eq.1) call csexit (1)
 
 
-! --- Calculation of the isochoric specific heat: Cv = Cp - R/M 
+! --- Calculation of the isochoric specific heat: Cv = Cp - R/M
 
   elseif(iccfth.eq.432) then
 
@@ -1449,7 +1449,7 @@ elseif(ieos(iphas).eq.2) then
 
     do iel = 1, ncel
 
-      ! Verification of the positivity of the pressure 
+      ! Verification of the positivity of the pressure
       if(rtp(iel,ipriph).lt.0.d0) then
         write(nfecra,1310) iel , rtp(iel,ipriph)
         ierr = 1
@@ -1469,22 +1469,22 @@ elseif(ieos(iphas).eq.2) then
 
     enddo
 
-    ! Stop if error detected 
+    ! Stop if error detected
     if(ierr.eq.1) call csexit (1)
 
 
-! --- Calculation of 'internal energy - Cv.T' 
+! --- Calculation of 'internal energy - Cv.T'
 
   elseif(iccfth.eq.7) then
 
-    ! It is zero for a perfect gas 
+    ! It is zero for a perfect gas
 
-    !   At the cell centers 
+    !   At the cell centers
     do iel = 1, ncel
       sorti1(iel) = 0.d0
     enddo
 
-    !   On the boundary faces  
+    !   On the boundary faces
     do ifac = 1, nfabor
       sorti2(ifac) = 0.d0
     enddo
@@ -1495,14 +1495,14 @@ elseif(ieos(iphas).eq.2) then
 
 ! --- Calculation of the boundary conditions on the face ifac = ifac0
 
-!  -- Wall/symmetry 
+!  -- Wall/symmetry
 
   elseif(iccfth.eq.91) then
 
     ifac = ifac0
     iel  = ifabor(ifac)
 
-    ! Calculation of the Mach number at the boundary face, using the 
+    ! Calculation of the Mach number at the boundary face, using the
     !   cell center velocity projected on the vector normal to the boundary
     xmach = ( rtp(iel,iuiph)*surfbo(1,ifac)                       &
            + rtp(iel,iviph)*surfbo(2,ifac)                        &
@@ -1511,7 +1511,7 @@ elseif(ieos(iphas).eq.2) then
 
     coefa(ifac,iclp) = 0.d0
 
-    ! Pression and entropy: rarefaction 
+    ! Pression and entropy: rarefaction
 
     if(xmach.le.0.d0 .and. xmach.gt.2.d0/(1.d0-gamagr(iel))) then
       coefb(ifac,iclp) = (1.d0 + (gamagr(iel)-1.d0)/2.d0 * xmach) &
@@ -1535,7 +1535,7 @@ elseif(ieos(iphas).eq.2) then
               + rtp(iel,ipriph) *(1.d0-coefb(ifac,iclp)) )
     endif
 
-    ! Total energy: 'internal energy - Cv T' 
+    ! Total energy: 'internal energy - Cv T'
 
     coefa(ifac,icle) = 0.d0
 
@@ -1550,7 +1550,7 @@ elseif(ieos(iphas).eq.2) then
     ifac = ifac0
     iel  = ifabor(ifac)
 
-    ! Calculation of the Mach number at the boundary face, using the 
+    ! Calculation of the Mach number at the boundary face, using the
     !   cell center velocity projected on the vector normal to the boundary
     xmachi = ( rtp(iel,iuiph)*surfbo(1,ifac)                      &
          + rtp(iel,iviph)*surfbo(2,ifac)                          &
@@ -1582,10 +1582,10 @@ elseif(ieos(iphas).eq.2) then
                                            *dxmach**2) )  )
     endif
 
-    ! This choice overrides the previous Rusanov choice 
+    ! This choice overrides the previous Rusanov choice
     coefa(ifac,iclp) = rtp(iel,ipriph)
 
-    ! Total energy 
+    ! Total energy
     coefa(ifac,icle) =                                            &
          coefa(ifac,iclp)/((gamagr(iel)-1.d0)*coefa(ifac,iclr))   &
          + 0.5d0*(coefa(ifac,iclu)**2                             &
@@ -1598,14 +1598,14 @@ elseif(ieos(iphas).eq.2) then
     ifac = ifac0
     iel  = ifabor(ifac)
 
-    ! Calculation of the Mach number at the boundary face, using the 
+    ! Calculation of the Mach number at the boundary face, using the
     !   cell center velocity projected on the vector normal to the boundary
     xmach = ( rtp(iel,iuiph)*surfbo(1,ifac)                       &
            + rtp(iel,iviph)*surfbo(2,ifac)                        &
            + rtp(iel,iwiph)*surfbo(3,ifac) ) / ra(isrfbn+ifac-1)  &
          / sqrt(gamagr(iel)*rtp(iel,ipriph)/rtp(iel,irhiph))
 
-    ! Supersonic outlet: Dirichlet for all variables 
+    ! Supersonic outlet: Dirichlet for all variables
     if(xmach.ge.1.d0) then
       do ivar = 1, nvar
         coefa(ifac,iclrtp(ivar,icoef)) = rtp(iel,ivar)
@@ -1711,7 +1711,7 @@ elseif(ieos(iphas).eq.2) then
     if(ierr.eq.1) call csexit (1)
 
 
-! --- Calculation of temperature and energy from pressure and density 
+! --- Calculation of temperature and energy from pressure and density
 
   elseif(iccfth.eq.912.or.iccfth.eq.60900) then
 
@@ -1728,7 +1728,7 @@ elseif(ieos(iphas).eq.2) then
                     + coefa(ifac,iclv)**2 + coefa(ifac,iclw)**2)
 
 
-! --- Calculation of density and energy from pressure and temperature 
+! --- Calculation of density and energy from pressure and temperature
 
   elseif(iccfth.eq.913.or.iccfth.eq.100900) then
 
@@ -1745,7 +1745,7 @@ elseif(ieos(iphas).eq.2) then
                     + coefa(ifac,iclv)**2 + coefa(ifac,iclw)**2)
 
 
-! --- Calculation of density and temperature from pressure and total energy 
+! --- Calculation of density and temperature from pressure and total energy
 
   elseif(iccfth.eq.914.or.iccfth.eq.140900) then
 
@@ -1779,7 +1779,7 @@ elseif(ieos(iphas).eq.2) then
                     + coefa(ifac,iclv)**2 + coefa(ifac,iclw)**2)
 
 
-! --- Calculation of pressure and temperature from density and energy 
+! --- Calculation of pressure and temperature from density and energy
 
   elseif(iccfth.eq.924.or.iccfth.eq.210900) then
 
@@ -1797,10 +1797,10 @@ elseif(ieos(iphas).eq.2) then
                                        /coefa(ifac,iclr)
 
 
-! --- End of perfect gas with variable gamma 
+! --- End of perfect gas with variable gamma
   endif
 
-! --- End of test on the thermodynamic laws 
+! --- End of test on the thermodynamic laws
 endif
 
 
@@ -1814,11 +1814,11 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
-'@     Gamma = ',e12.4   ,/,                                      &  
-'@     Gamma must be a real number greater or equal to 1.',/,     &  
+'@     Gamma = ',e12.4   ,/,                                      &
+'@     Gamma must be a real number greater or equal to 1.',/,     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1828,11 +1828,11 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
-'@     In cell ',i10   ,', Gamma = ',e12.4   ,/,                  &  
-'@     Gamma must be a real number greater or equal to 1.',/,     &  
+'@     In cell ',i10   ,', Gamma = ',e12.4   ,/,                  &
+'@     Gamma must be a real number greater or equal to 1.',/,     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1842,13 +1842,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of density failed.',/,                     &
 '@',/,                                                            &
-'@     Temperature = ',e12.4   ,' in cell ',i10  ,/,              &  
-'@     Temperature must be strictly positive.',/,                 &  
+'@     Temperature = ',e12.4   ,' in cell ',i10  ,/,              &
+'@     Temperature must be strictly positive.',/,                 &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1858,13 +1858,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of temperature failed.',/,                 &
 '@',/,                                                            &
-'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &  
-'@     Density must be strictly positive.',/,                     &  
+'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &
+'@     Density must be strictly positive.',/,                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1874,13 +1874,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the squared speed of sound failed.',/,  &
 '@',/,                                                            &
-'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &  
-'@     Density must be strictly positive.',/,                     &  
+'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &
+'@     Density must be strictly positive.',/,                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1890,13 +1890,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the variable beta failed.',/,           &
 '@',/,                                                            &
-'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &  
-'@     Density must be strictly positive.',/,                     &  
+'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &
+'@     Density must be strictly positive.',/,                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1906,13 +1906,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the entropy failed.',/,                 &
 '@',/,                                                            &
-'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &  
-'@     Density must be strictly positive.',/,                     &  
+'@     Density = ',e12.4   ,' in cell ',i10  ,/,                  &
+'@     Density must be strictly positive.',/,                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1922,14 +1922,14 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     The boundary condition of the type ''prescribed mass',/,   &
 '@     and enthalpy flow rates '' is not available in the ',/,    &
 '@     current release.',/,                                       &
 '@',/,                                                            &
-'@     Modify the user subroutine ''uscfth''.',/,                 &  
+'@     Modify the user subroutine ''uscfth''.',/,                 &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1939,8 +1939,8 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     Negative values of the density were encountered ',/,       &
 '@     in ',i10   ,' cells.',/,                                   &
@@ -1952,7 +1952,7 @@ endif
 '@     by setting a minimum value for the density variable in',/, &
 '@     the GUI or in the user subroutine ''usini1'' (set the ',/, &
 '@     scamin value associated to the variable ',/,               &
-'@     isca(irho(iphas)).',/,                                     & 
+'@     isca(irho(iphas)).',/,                                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -1962,8 +1962,8 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with constant gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with constant gamma.',/,                 &
 '@',/,                                                            &
 '@     Negative values of the internal energy were encountered',/,&
 '@     in ',i10   ,' cells.',/,                                   &
@@ -1974,7 +1974,7 @@ endif
 '@',/)
 
 
-! The following formats may be discarded if or when the 
+! The following formats may be discarded if or when the
 ! gamma variable option will have been fixed
 
 
@@ -1984,13 +1984,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with variable gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with variable gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the squared speed of sound failed.',/,  &
 '@',/,                                                            &
-'@     In cell ',i10   ,' Pressure = ',e12.4   ,/,                &  
-'@     Pressure must be positive.',/,                             &  
+'@     In cell ',i10   ,' Pressure = ',e12.4   ,/,                &
+'@     Pressure must be positive.',/,                             &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -2000,13 +2000,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with variable gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with variable gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the squared speed of sound failed.',/,  &
 '@',/,                                                            &
-'@     In cell ',i10   ,' Density = ',e12.4   ,/,                 &  
-'@     Density must be strictly positive.',/,                     &  
+'@     In cell ',i10   ,' Density = ',e12.4   ,/,                 &
+'@     Density must be strictly positive.',/,                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -2016,13 +2016,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with variable gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with variable gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the variable beta failed.',/,           &
 '@',/,                                                            &
-'@     In cell ',i10   ,' Density = ',e12.4   ,/,                 &  
-'@     Density must be strictly positive.',/,                     &  
+'@     In cell ',i10   ,' Density = ',e12.4   ,/,                 &
+'@     Density must be strictly positive.',/,                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -2032,13 +2032,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with variable gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with variable gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the entropy failed.',/,                 &
 '@',/,                                                            &
-'@     In cell ',i10   ,' Pressure = ',e12.4   ,/,                &  
-'@     Pressure must be positive.',/,                             &  
+'@     In cell ',i10   ,' Pressure = ',e12.4   ,/,                &
+'@     Pressure must be positive.',/,                             &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -2048,13 +2048,13 @@ endif
 '@',/,                                                            &
 '@ @@ WARNING:    stop in thermodynamics computations',/,         &
 '@    =======',/,                                                 &
-'@     Error encountered in the user subroutine ''uscfth'', ',/,  &  
-'@       for perfect gas with variable gamma.',/,                 &  
+'@     Error encountered in the user subroutine ''uscfth'', ',/,  &
+'@       for perfect gas with variable gamma.',/,                 &
 '@',/,                                                            &
 '@     The computation of the entropy failed.',/,                 &
 '@',/,                                                            &
-'@     In cell ',i10   ,' Density = ',e12.4   ,/,                 &  
-'@     Density must be striclty positive.',/,                     &  
+'@     In cell ',i10   ,' Density = ',e12.4   ,/,                 &
+'@     Density must be striclty positive.',/,                     &
 '@',/,                                                            &
 '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@',/,&
 '@',/)
@@ -2065,4 +2065,4 @@ endif
 !----
 
 return
-end subroutine 
+end subroutine
diff --git a/users/cfbl/uscfx1.f90 b/users/cfbl/uscfx1.f90
index 294a853..fc7b2b1 100644
--- a/users/cfbl/uscfx1.f90
+++ b/users/cfbl/uscfx1.f90
@@ -121,7 +121,7 @@ endif
 ! For each phase
 do iphas = 1, nphas
 
-  ! Specify if the hydrostatic equilibrium must be accounted for 
+  ! Specify if the hydrostatic equilibrium must be accounted for
   !     (yes = 1 , no = 0)
 
   icfgrp(iphas) = 1
diff --git a/users/cfbl/uscfx2.f90 b/users/cfbl/uscfx2.f90
index 2d22a23..32175f9 100644
--- a/users/cfbl/uscfx2.f90
+++ b/users/cfbl/uscfx2.f90
@@ -39,10 +39,10 @@ subroutine uscfx2
 
 !    Set options for viscosity and conductivity for compressible flow.
 
-!    In addition to options set in the user subroutine 'usini1' (or in 
-!    the GUI): this subroutine allows to set switches to indicate if the 
+!    In addition to options set in the user subroutine 'usini1' (or in
+!    the GUI): this subroutine allows to set switches to indicate if the
 !    volumetric viscosity and the conductivity are constants. If they are,
-!    the subroutines allows to set their values. 
+!    the subroutines allows to set their values.
 
 
 !-------------------------------------------------------------------------------
@@ -131,35 +131,35 @@ iphas = 1
 
 ivisls(itempk(iphas)) = 0
 
-!       Reference molecular thermal conductivity 
+!       Reference molecular thermal conductivity
 !       visls0 = lambda0  (molecular thermal conductivity, W/(m K))
 
-!       WARNING: visls0 must be strictly positive 
+!       WARNING: visls0 must be strictly positive
 !         (set a realistic value here even if conductivity is variable)
 
 visls0(itempk(iphas)) = 3.d-2
 
-!       If the molecular thermal conductivity is variable, its values 
+!       If the molecular thermal conductivity is variable, its values
 !         must be provided in the user subroutine 'uscfpv'
 
 
-! --> Volumetric molecular viscosity 
+! --> Volumetric molecular viscosity
 
 !       Reference volumetric molecular viscosity
 
 !       viscv0 = kappa0  (volumetric molecular viscosity, kg/(m s))
 !       iviscv = 0 : uniform  in space and constant in time
-!              = 1 : variable in space and time 
+!              = 1 : variable in space and time
 
 iviscv(iphas) = 0
 viscv0(iphas) = 0.d0
 
-!       If the volumetric molecular viscosity is variable, its values 
+!       If the volumetric molecular viscosity is variable, its values
 !         must be provided in the user subroutine 'uscfpv'
 
 
 !----
-! End 
+! End
 !----
 
 return
diff --git a/users/cfbl/uscfxi.f90 b/users/cfbl/uscfxi.f90
index a4670c1..b78f457 100644
--- a/users/cfbl/uscfxi.f90
+++ b/users/cfbl/uscfxi.f90
@@ -56,24 +56,24 @@ subroutine uscfxi &
 ! Description
 ! ===========
 
-! This subroutine is similar to the user subroutine 'usiniv', but 
-! is dedicated to the compressible flow scheme. 
-! It is called at the beginning of the computation (only if it is 
-! not a restart), just before the time marching loop starts. 
-! It allows to initialize all the unknown variables. 
+! This subroutine is similar to the user subroutine 'usiniv', but
+! is dedicated to the compressible flow scheme.
+! It is called at the beginning of the computation (only if it is
+! not a restart), just before the time marching loop starts.
+! It allows to initialize all the unknown variables.
 
-! The standard initialization has been reproduced here as an example. 
+! The standard initialization has been reproduced here as an example.
 
-! More examples can be found in 'usiniv'. 
+! More examples can be found in 'usiniv'.
 
 
 ! Physical properties
 ! ===================
 
-! The physical properties (viscosity, specific heat, thermal 
-! conductivity, Schmidt number) that are stored in the arrays propce, 
-! propfa and propfb must not be modified here: if it is necessary to 
-! do so, it must be done in the dedicated user programme 'uscfpv'. 
+! The physical properties (viscosity, specific heat, thermal
+! conductivity, Schmidt number) that are stored in the arrays propce,
+! propfa and propfb must not be modified here: if it is necessary to
+! do so, it must be done in the dedicated user programme 'uscfpv'.
 
 
 ! Cells identification
@@ -239,7 +239,7 @@ idebra = idbra0
 imodif = 1
 
 !===============================================================================
-! 3. Unknown variable initialization 
+! 3. Unknown variable initialization
 !      for initial calculations (not in case of restart)
 !===============================================================================
 
@@ -256,16 +256,16 @@ if ( isuite.eq.0 ) then
   enddo
 
 
-! --- User defined scalars 
+! --- User defined scalars
 
-  ! If there are user defined scalars 
+  ! If there are user defined scalars
   if(nscaus.gt.0) then
-    ! For each scalar 
+    ! For each scalar
     do iscal = 1, nscaus
       ! If the scalar is associated to the considered phase iphas
       if(iphsca(iscal).eq.iphas) then
 
-        ! Initialize each cell value 
+        ! Initialize each cell value
         do iel = 1, ncel
           rtp(iel,isca(iscal)) = 0.d0
         enddo
@@ -275,26 +275,26 @@ if ( isuite.eq.0 ) then
   endif
 
 
-! --- Pressure, Density, Temperature, Total Energy 
+! --- Pressure, Density, Temperature, Total Energy
 
-  ! Only 2 out of these 4 variables are independent: one may choose to 
-  ! initialize any pair of variables picked out of these 4, except 
-  ! (Temperature-Energy). The remaining 2 variables will be deduced 
-  ! automatically.  
+  ! Only 2 out of these 4 variables are independent: one may choose to
+  ! initialize any pair of variables picked out of these 4, except
+  ! (Temperature-Energy). The remaining 2 variables will be deduced
+  ! automatically.
 
 
-  ! Initialize 2 and only 2 variables 
+  ! Initialize 2 and only 2 variables
 
-  !   To do so, set iutile=1 for each of the 2 selected variables 
+  !   To do so, set iutile=1 for each of the 2 selected variables
   !             and iutile=0 for each of the 2 others
 
-  !   In the example provided below, Pressure and Temperature are 
+  !   In the example provided below, Pressure and Temperature are
   !   initialized.
 
 
-  ! iccfth indicates which variables have been set: 
-  !   it is completed automatically for each variable and 
-!     it must not be modified. 
+  ! iccfth indicates which variables have been set:
+  !   it is completed automatically for each variable and
+!     it must not be modified.
   iccfth = 10000
 
 
@@ -335,9 +335,9 @@ if ( isuite.eq.0 ) then
   endif
 
 
-  ! ** The following subroutine returns automatically the values for the 
-  ! two remaining variables that need to be computed, using the 
-  ! indicator iccfth.  
+  ! ** The following subroutine returns automatically the values for the
+  ! two remaining variables that need to be computed, using the
+  ! indicator iccfth.
 
   call uscfth                                                     &
   !==========
diff --git a/users/pprt/usppmo.f90 b/users/pprt/usppmo.f90
index 0c129ae..c2521c3 100644
--- a/users/pprt/usppmo.f90
+++ b/users/pprt/usppmo.f90
@@ -39,8 +39,9 @@ subroutine usppmo
 !    User subroutine.
 
 !    Define the use of a specific physics amongst the following:
-!      - combustion with gaz / coal / heavy fioul oil
+!      - combustion with gaz / coal / heavy fuel oil
 !      - compressible flows
+!      - electric arcs
 !      - atmospheric modelling
 !      - cooling towers modelling
 
@@ -193,8 +194,8 @@ ippmod(ieljou) = -1
 ! ==========
 
 !        if = -1   module not activated
-!        if = 0    electric potential
-!        if = 1    electric potential and vector potential (hence 3D modelling)
+!        if = 1    electric potential
+!        if = 2    electric potential and vector potential (hence 3D modelling)
 
 ippmod(ielarc) = -1
 
@@ -244,7 +245,6 @@ ippmod(icodeq) = -1
 ! ==========
 
 !        if = -1   module not activated
-!        if = 1    eletric potential
 
 ippmod(ielion) = -1
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/code-saturne.git



More information about the debian-science-commits mailing list