diff --git a/libcorpus2/CMakeLists.txt b/libcorpus2/CMakeLists.txt
index 7f507e772867a80b13cd5de44ff0b0a8fd3fb756..fc5dc989bf0610e532e92d596411ff5aab44bd52 100644
--- a/libcorpus2/CMakeLists.txt
+++ b/libcorpus2/CMakeLists.txt
@@ -90,11 +90,11 @@ if(WIN32)
 # by default.
 # For UNIX on the other hand everything is exported by default.
 # Until external API is specified explicitly, build STATIC for WIN32
-	add_library(corpus2 STATIC ${libcorpus2_STAT_SRC} ${INCS})
+	add_library(corpus2 SHARED ${libcorpus2_STAT_SRC} ${INCS})
 else(WIN32)
 	add_library(corpus2 SHARED ${libcorpus2_STAT_SRC} ${INCS})
 endif(WIN32)
-target_link_libraries(corpus2 ${LIBS})
+target_link_libraries(corpus2 pwrutils ${LIBS})
 set_target_properties(corpus2 PROPERTIES
 	VERSION "${corpus2_ver_major}.${corpus2_ver_minor}"
 	SOVERSION ${corpus2_ver_major})
diff --git a/libcorpus2_whole/CMakeLists.txt b/libcorpus2_whole/CMakeLists.txt
index 1f410bdafb052825f7d35336dcb46b9a86176fb5..9c00a6f19d70c5432e14d19e7c512152e77656b2 100755
--- a/libcorpus2_whole/CMakeLists.txt
+++ b/libcorpus2_whole/CMakeLists.txt
@@ -3,6 +3,9 @@ PROJECT(corpus2_whole)
 find_package(LibXML++ REQUIRED QUIET)
 include_directories(${LibXML++_INCLUDE_DIRS})
 include_directories(${Boost_INCLUDE_DIRS})
+link_directories(${ICU_LIBRARY_DIRS})
+link_directories(${Boost_LIBRARY_DIRS})
+include_directories(${ICU_INCLUDE_DIR})
 link_directories(${LibXML++_LIBRARY_DIRS})
 set(LIBS ${LIBS} ${LibXML++_LIBRARIES})
 
@@ -30,7 +33,7 @@ endif(CORPUS2_BUILD_POLIQARP)
 file(GLOB_RECURSE INCS "*.h")
 
 if(WIN32)
-	add_library(corpus2_whole STATIC ${libcorpus2_whole_SRC} ${INCS})
+	add_library(corpus2_whole SHARED ${libcorpus2_whole_SRC} ${INCS})
 else(WIN32)
 	add_library(corpus2_whole SHARED ${libcorpus2_whole_SRC} ${INCS})
 endif(WIN32)
diff --git a/libpwrutils/CMakeLists.txt b/libpwrutils/CMakeLists.txt
index 05192d00cd8089491c4c243d5ed1939485583f6e..30c8042c4f8921a8daf563a7cb52ccea87f25841 100644
--- a/libpwrutils/CMakeLists.txt
+++ b/libpwrutils/CMakeLists.txt
@@ -43,7 +43,7 @@ if(WIN32)
 # by default.
 # For UNIX on the other hand everything is exported by default.
 # Until external API is specified explicitly, build STATIC for WIN32
-	add_library(pwrutils STATIC ${libpwrutils_STAT_SRC} ${INCS})
+	add_library(pwrutils SHARED ${libpwrutils_STAT_SRC} ${INCS})
 else(WIN32)
 	add_library(pwrutils SHARED ${libpwrutils_STAT_SRC} ${INCS})
 endif(WIN32)