Index: src/CMakeLists.txt
===================================================================
--- src/CMakeLists.txt	(revision 1878)
+++ src/CMakeLists.txt	(working copy)
@@ -26,6 +26,11 @@
 #  DEALINGS IN THE SOFTWARE.
 #
 
+if(NOT WIN32)
+  set(ENV{CC} gcc-4.6)
+  set(ENV{CXX} g++-4.6)
+endif(NOT WIN32)
+
 ###########################################
 # PROJECT: Seg3D
 ###########################################
Index: src/Core/Utils/FilesystemUtil.cc
===================================================================
--- src/Core/Utils/FilesystemUtil.cc	(revision 1878)
+++ src/Core/Utils/FilesystemUtil.cc	(working copy)
@@ -58,7 +58,7 @@
 
 bool RecursiveCopyDirectory( const boost::filesystem::path& from, const boost::filesystem::path& to )
 {
-	using namespace boost::filesystem3;
+	using namespace boost::filesystem;
 	
 	// If the source path doesn't exist or it's not a directory
 	if ( !exists( from ) || !is_directory( from ) ) return false;
Index: src/Application/Layer/LayerCheckPoint.cc
===================================================================
--- src/Application/Layer/LayerCheckPoint.cc	(revision 1878)
+++ src/Application/Layer/LayerCheckPoint.cc	(working copy)
@@ -94,7 +94,7 @@
 	
 	if ( !( this->private_->data_slices_.empty() ) )
 	{
-		DataLayerHandle data_layer = boost::shared_dynamic_cast<DataLayer>( layer );
+		DataLayerHandle data_layer = boost::dynamic_pointer_cast<DataLayer>( layer );
 		if ( ! data_layer ) return false;
 
 		LayerManager::DispatchInsertDataSlicesIntoLayer( data_layer, 
@@ -104,7 +104,7 @@
 
 	if ( !( this->private_->mask_slices_.empty() ) )
 	{
-		MaskLayerHandle mask_layer = boost::shared_dynamic_cast<MaskLayer>( layer );
+		MaskLayerHandle mask_layer = boost::dynamic_pointer_cast<MaskLayer>( layer );
 		if ( ! mask_layer ) return false;
 
 		LayerManager::DispatchInsertMaskSlicesIntoLayer( mask_layer, 
@@ -130,7 +130,7 @@
 
 	if ( layer->get_type() == Core::VolumeType::MASK_E )
 	{
-		MaskLayerHandle mask = boost::shared_dynamic_cast<MaskLayer>( layer );
+		MaskLayerHandle mask = boost::dynamic_pointer_cast<MaskLayer>( layer );
 		if ( ! mask->has_valid_data() ) return false;
 		
 		Core::MaskDataSliceHandle slice;
@@ -141,7 +141,7 @@
 	}
 	else if ( layer->get_type() == Core::VolumeType::DATA_E )
 	{
-		DataLayerHandle data = boost::shared_dynamic_cast<DataLayer>( layer );
+		DataLayerHandle data = boost::dynamic_pointer_cast<DataLayer>( layer );
 		if ( ! data->has_valid_data() ) return false;
 		
 		Core::DataSliceHandle slice;
@@ -164,7 +164,7 @@
 		for ( Core::DataBlock::index_type j = start; j <= end; j++ )
 		{
 
-			MaskLayerHandle mask = boost::shared_dynamic_cast<MaskLayer>( layer );
+			MaskLayerHandle mask = boost::dynamic_pointer_cast<MaskLayer>( layer );
 			if ( ! mask->has_valid_data() ) return false;
 			
 			Core::MaskDataSliceHandle slice;
@@ -178,7 +178,7 @@
 	{
 		for ( Core::DataBlock::index_type j = start; j <= end; j++ )
 		{
-			DataLayerHandle data = boost::shared_dynamic_cast<DataLayer>( layer );
+			DataLayerHandle data = boost::dynamic_pointer_cast<DataLayer>( layer );
 			if ( ! data->has_valid_data() ) return false;
 			
 			Core::DataSliceHandle slice;
Index: src/Application/Layer/LayerManager.cc
===================================================================
--- src/Application/Layer/LayerManager.cc	(revision 1878)
+++ src/Application/Layer/LayerManager.cc	(working copy)
@@ -1465,13 +1465,13 @@
 
 MaskLayerHandle LayerManager::FindMaskLayer( const std::string& layer_id, SandboxID sandbox )
 {
-	return boost::shared_dynamic_cast<MaskLayer>(  
+	return boost::dynamic_pointer_cast<MaskLayer>(  
 		LayerManager::Instance()->find_layer_by_id( layer_id, sandbox ) );
 }
 
 DataLayerHandle LayerManager::FindDataLayer( const std::string& layer_id, SandboxID sandbox )
 {
-	return boost::shared_dynamic_cast<DataLayer>(  
+	return boost::dynamic_pointer_cast<DataLayer>(  
 		LayerManager::Instance()->find_layer_by_id( layer_id, sandbox ) );
 }
 
@@ -1751,8 +1751,8 @@
 {
 	if ( layer->get_type() == Core::VolumeType::MASK_E )
 	{
-		MaskLayerHandle mask = boost::shared_dynamic_cast<MaskLayer>( layer );
-		Core::MaskVolumeHandle mask_volume = boost::shared_dynamic_cast<Core::MaskVolume>( volume );
+		MaskLayerHandle mask = boost::dynamic_pointer_cast<MaskLayer>( layer );
+		Core::MaskVolumeHandle mask_volume = boost::dynamic_pointer_cast<Core::MaskVolume>( volume );
 		if ( mask && mask_volume )
 		{
 			DispatchInsertMaskVolumeIntoLayer( mask, mask_volume, prov_id, key, sandbox );
@@ -1760,8 +1760,8 @@
 	}
 	else if ( layer->get_type() == Core::VolumeType::DATA_E )
 	{
-		DataLayerHandle data = boost::shared_dynamic_cast<DataLayer>( layer );
-		Core::DataVolumeHandle data_volume = boost::shared_dynamic_cast<Core::DataVolume>( volume );
+		DataLayerHandle data = boost::dynamic_pointer_cast<DataLayer>( layer );
+		Core::DataVolumeHandle data_volume = boost::dynamic_pointer_cast<Core::DataVolume>( volume );
 		if ( data && data_volume )
 		{
 			DispatchInsertDataVolumeIntoLayer( data, data_volume, prov_id, key, sandbox );
