BUG: Using static const variable causes ld error when using dynamic libraries

Static const variables yeld STB_GNU_UNIQUE symbols in shared libraries, and prevent these libraries to be properly unloaded. As a result, a program using dynamic libraries loading including calls to itk::MattesMutualInformationImageToImageMetric will return the following error whenever it ends :

Inconsistency detected by ld.so: dl-close.c: 731: _dl_close: Assertion `map->l_init_called' failed!

This patch only replaces the static const variables by const variables.

The pre-commit hook made me do the style changes. I applied the requested changes in this new version.

Change-Id: I5862ff5a965599dbf2a4cc1b48b5a4931588653b
BUG: Remove initially available ITK_WRAP_JAVA cmake option

Currently Java WrapITK needs work, an does not build correctly. This
patch removes the option initially available. The option will still
become available after ITK_WRAPPING is enabled.

Change-Id: I8d552555d72d95b5fbf05b87b94527aac1025960
Merge topic 'WrapITKNoEasyJavaOption'

04c9485 BUG: Remove initially available ITK_WRAP_JAVA cmake option
Merge topic 'static_const_removal'

d74f4d8 BUG: Using static const variable causes ld error when using dynamic libraries
BUG: Update VXL update README location.

Change-Id: I65b09d24e335889aab78f61f3c4908a62b13ddf2
ENH: Wrap additional dimensions for TileImageFilter.

Tiling from 2 to 3 dimensions, for example, is common.

Change-Id: I285abb92aa5c9aa9d8b147ca4bb97467809b09c3
Suggested-by: Michka Popoff <michkapopoff@gmail.com>
Merge topic 'vxl-readme'

ab4f446 BUG: Update VXL update README location.
COMP: Fix improper included header in vcl_memory_tr1.h

TR1 is a special case in vcl and does not exactly fit the original vcl
header generation framework.  Make a small change to add a special case
for TR1 in which the "_tr1" suffix is stripped when generating the
include path.

Change-Id: I02a39658f5c0d28ad701052ba8444dfc1a9d997b
Merge topic 'vcl_memory'

790d46b COMP: Fix improper included header in vcl_memory_tr1.h
COMP: Ensure FindDCMTK.cmake provided by ITK is used (build tree case)

When building project against ITK, if the CMAKE_MODULE_PATH is not
updated to include the location of the FindDCMTK.cmake module provided
by ITK, the default one provided by CMake will be used and the
configuration will fail with an error like the one reported below.

Note that this commit only fix the "exported build tree" case, similar
patch should be done for the "exported install tree" case (including
the addition of an install rule for the FindDCMTK.cmake module provided
by ITK)

Finally, it is also agreed that the module provided within CMake should
be fixed. For more detailed, see commit d9034833.

Configuration error:

CMake Error at /home/jchris/Support/cmake-2.8.11.2/Modules/FindPackageHandleStandardArgs.cmake:108 (message):
  Could NOT find DCMTK (missing: DCMTK_ofstd_INCLUDE_DIR
  DCMTK_dcmdata_INCLUDE_DIR DCMTK_dcmimgle_INCLUDE_DIR)
Call Stack (most recent call first):
  /home/jchris/Support/cmake-2.8.11.2/Modules/FindPackageHandleStandardArgs.cmake:315 (_FPHSA_FAILURE_MESSAGE)
  /home/jchris/Support/cmake-2.8.11.2/Modules/FindDCMTK.cmake:138 (find_package_handle_standard_args)
  /home/jchris/Projects/Slicer-SuperBuild-Debug-Qt485-new-buildsystem/ITKv4-build/lib/cmake/ITK-4.5/Modules/ITKDCMTK.cmake:9 (find_package)
  /home/jchris/Projects/Slicer-SuperBuild-Debug-Qt485-new-buildsystem/ITKv4/CMake/ITKModuleAPI.cmake:48 (include)
  /home/jchris/Projects/Slicer-SuperBuild-Debug-Qt485-new-buildsystem/ITKv4/CMake/ITKModuleAPI.cmake:25 (itk_module_load)
  /home/jchris/Projects/Slicer-SuperBuild-Debug-Qt485-new-buildsystem/ITKv4/CMake/ITKModuleAPI.cmake:67 (_itk_module_config_recurse)
  /home/jchris/Projects/Slicer-SuperBuild-Debug-Qt485-new-buildsystem/ITKv4-build/ITKConfig.cmake:81 (itk_module_config)
  /home/jchris/Support/cmake-2.8.11.2/Modules/FindITK.cmake:48 (find_package)

Change-Id: I18240028092bd3b7879db18e6d05aa0c1669f5b6
ENH: Restore/convert/repair ImageRegistrationHistogramPlotter

ImageRegistrationHistogramPlotter was never converted to the new
statistics framework. This patch restores, converts and repairs the
example.

Also, added a regression test.

Change-Id: I7f86e454b34bffbb36bc4a7023973a8c0c346db8
DOC: Fixing BinShrink image caption

Doxygen requires caption to be one line with only quotes.

Change-Id: Ibab01a8a14d92f8bdd9f034bc9b609722c1088ff
Merge topic 'fix-building-against-system-dcmtk'

d6ca29c COMP: Ensure FindDCMTK.cmake provided by ITK is used (build tree case)
BUG: Fix up-casting causing inf loop

An infinite loop occurred with uint8 and labels of 255 due to
incorrectly casting. It was waiting for uint8 >= 256. The correct
type is now used for the loop control variable.

Change-Id: Ica67d476fec337e92c4f1b41527eeb2e2c679c70
BUG: LeafTreeIterator does not produce correct output.

The LeafTreeIterator uses a PreOrderIterator internally in its implementation,
but it initializes with its current position, which the PreOrderIterator
considers as the start of its subtree and will cause the PreOrderIterator to
terminate prematurely. This causes the LeafTreeIterator to incorrectly
end after its first value.

To correct the behavior the Root of the helper PreOrderIterator is adjusted.
This is done by naming the LeafTreeIterator a friend class to maintain
efficiency, correctness, and backwards compatible behavior.

This patch also improves expected value testing in the unit test.

Change-Id: Id6aea31dec1131b45b046924bdc72dfbcf907602
Suggested-by: Hoang Van Thai <hvthaibk@gmail.com>
Merge topic 'FixLabelVotingInfLoop'

8b09a0f BUG: Fix up-casting causing inf loop
Merge topic 'DocBinShrinkCaption'

34d6d55 DOC: Fixing BinShrink image caption
BUG: remove HDF5 configuration option propagated to the top

This cmake option from HDF5 is being propagated to the top. It is
removed to reduce clutter and confusion.

Change-Id: I466c2d41d30b63e107f773547261b1ad2bd84950
Merge topic 'NoBUILD_STATIC_EXECS'

b6520ff BUG: remove HDF5 configuration option propagated to the top
Merge topic 'LeafTreeIterator'

76a2854 BUG: LeafTreeIterator does not produce correct output.