diff --git a/Common/CMakeLists.txt b/Common/CMakeLists.txt index 8144777f5..a4585b759 100644 --- a/Common/CMakeLists.txt +++ b/Common/CMakeLists.txt @@ -193,7 +193,7 @@ source_group( "ImageSamplers" FILES ${ImageSamplersFiles} ) #--------------------------------------------------------------------- # Create the elxCommon library. -add_library( elxCommon STATIC +add_library( elxCommon ${CommonFiles} ${CostFunctionFiles} ${TransformFiles} diff --git a/Common/MevisDicomTiff/CMakeLists.txt b/Common/MevisDicomTiff/CMakeLists.txt index d4332b8db..bac91b2be 100644 --- a/Common/MevisDicomTiff/CMakeLists.txt +++ b/Common/MevisDicomTiff/CMakeLists.txt @@ -3,7 +3,7 @@ project( MevisDicomTiff ) if( ELASTIX_USE_MEVISDICOMTIFF ) add_definitions( -D_ELASTIX_USE_MEVISDICOMTIFF ) - add_library( mevisdcmtiff STATIC + add_library( mevisdcmtiff itkMevisDicomTiffImageIO.cxx itkMevisDicomTiffImageIOFactory.cxx itkUseMevisDicomTiff.cxx @@ -11,7 +11,7 @@ if( ELASTIX_USE_MEVISDICOMTIFF ) else() # avoid dependencies, but compile the lib, so that customers of this # lib can just call RegisterMevisDicomTiff without checking. - add_library( mevisdcmtiff STATIC + add_library( mevisdcmtiff itkUseMevisDicomTiff.cxx ) endif() diff --git a/Common/OpenCL/CMakeLists.txt b/Common/OpenCL/CMakeLists.txt index 2cedb2e38..8a29ed8b3 100644 --- a/Common/OpenCL/CMakeLists.txt +++ b/Common/OpenCL/CMakeLists.txt @@ -53,7 +53,7 @@ set( OpenCL_Files ) # Create the openCL library -add_library( elxOpenCL STATIC ${OpenCL_Files} ) +add_library( elxOpenCL ${OpenCL_Files} ) # Link it against the necessary libraries. target_link_libraries( elxOpenCL diff --git a/Common/ParameterFileParser/CMakeLists.txt b/Common/ParameterFileParser/CMakeLists.txt index 65b617510..9db6262e2 100644 --- a/Common/ParameterFileParser/CMakeLists.txt +++ b/Common/ParameterFileParser/CMakeLists.txt @@ -8,7 +8,7 @@ set( param_SRCS source_group( "Parser" FILES ${param_SRCS} ) -add_library( param STATIC ${param_SRCS} ) +add_library( param ${param_SRCS} ) install( TARGETS param ARCHIVE DESTINATION ${ELASTIX_ARCHIVE_DIR} LIBRARY DESTINATION ${ELASTIX_LIBRARY_DIR} diff --git a/Common/xout/CMakeLists.txt b/Common/xout/CMakeLists.txt index 791f04503..868c07a6a 100644 --- a/Common/xout/CMakeLists.txt +++ b/Common/xout/CMakeLists.txt @@ -18,7 +18,7 @@ set( xouthfiles xoutcell.h ) # a lib defining the global variable xout. -add_library( xoutlib STATIC xoutmain.cxx ${xouthxxfiles} ${xouthfiles} ) +add_library( xoutlib xoutmain.cxx ${xouthxxfiles} ${xouthfiles} ) install( TARGETS xoutlib ARCHIVE DESTINATION ${ELASTIX_ARCHIVE_DIR} LIBRARY DESTINATION ${ELASTIX_LIBRARY_DIR} diff --git a/Components/CMakeLists.txt b/Components/CMakeLists.txt index dc9ebb076..87fae6752 100644 --- a/Components/CMakeLists.txt +++ b/Components/CMakeLists.txt @@ -127,7 +127,7 @@ macro( ADD_ELXCOMPONENT name ) # Create project and static library project( ${name} ) - add_library( ${name} STATIC ${filelist} ) + add_library( ${name} ${filelist} ) target_link_libraries( ${name} ${elxLinkLibs} ) install( TARGETS ${name} ARCHIVE DESTINATION ${ELASTIX_ARCHIVE_DIR} diff --git a/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/CMakeLists.txt b/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/CMakeLists.txt index 581841c66..ea1e8309d 100644 --- a/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/CMakeLists.txt +++ b/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/CMakeLists.txt @@ -33,7 +33,7 @@ set( KNN_Files add_subdirectory( ann_1.1 ) # Create the KNN library -add_library( KNNlib STATIC ${KNN_Files} ) +add_library( KNNlib ${KNN_Files} ) # Link it against the necessary libraries. target_link_libraries( KNNlib ANNlib ${ITK_LIBRARIES} ) diff --git a/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/ann_1.1/CMakeLists.txt b/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/ann_1.1/CMakeLists.txt index f02605b8d..ff1665bfb 100644 --- a/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/ann_1.1/CMakeLists.txt +++ b/Components/Metrics/KNNGraphAlphaMutualInformation/KNN/ann_1.1/CMakeLists.txt @@ -40,7 +40,7 @@ set( ANN_SRCS ) # Create the ANNlib library -add_library( ANNlib SHARED ${ANN_SRCS} ) +add_library( ANNlib ${ANN_SRCS} ) # Necessary when building a library, because in windows dll_export # is needed for creating the dll, but dll_import for using it in a program. diff --git a/Core/CMakeLists.txt b/Core/CMakeLists.txt index d4aef7c38..e912aa125 100644 --- a/Core/CMakeLists.txt +++ b/Core/CMakeLists.txt @@ -89,7 +89,7 @@ source_group( "ProgressCommand" FILES ${ProgressCommandFiles} ) #--------------------------------------------------------------------- # Create the elxCore library. -add_library( elxCore STATIC +add_library( elxCore ${KernelFilesForComponents} ${InstallFilesForComponents} ${ConfigurationFiles}