diff --git a/modules/conop/src/diag.cc b/modules/conop/src/diag.cc
index 470673bf73f3c6bcb7acc0836839c25c7d740336..cf7147ede8fab30eca26dbf22dfe977b6350ed51 100644
--- a/modules/conop/src/diag.cc
+++ b/modules/conop/src/diag.cc
@@ -79,7 +79,7 @@ String Diag::Format(bool colored) const
       char *end=NULL;
       long int id=strtol(start, &end, 10);
       assert(start!=end);
-      assert(id>=0 && id<strings.size());
+      assert(id>=0 && static_cast<unsigned long>(id)<strings.size());
       if (plural_s) {
         if (ints_[args_[id].index]!=1) {
           ss << "s";
diff --git a/modules/geom/tests/test_transform.cc b/modules/geom/tests/test_transform.cc
index ae27fd594b71432bfa271fbcf5fecce52c9e5594..8ac2ce97b579fe2e5c854c31b6a348e9e0a0910c 100644
--- a/modules/geom/tests/test_transform.cc
+++ b/modules/geom/tests/test_transform.cc
@@ -44,17 +44,6 @@ BOOST_AUTO_TEST_CASE(test_transform_essentials)
   tf.SetTrans(tra);
   tf.SetCenter(cen);
 
-  Mat4 tmat = 
-    geom::Mat4(1.0,0.0,0.0,tra[0],
-               0.0,1.0,0.0,tra[1],
-               0.0,0.0,1.0,tra[2],
-               0.0,0.0,0.0,1.0) *
-    geom::Mat4(rot) *
-    geom::Mat4(1.0,0.0,0.0,-cen[0],
-               0.0,1.0,0.0,-cen[1],
-               0.0,0.0,1.0,-cen[2],
-               0.0,0.0,0.0,1.0);
-
   BOOST_CHECK_EQUAL(tf.GetRot(), rot);
   BOOST_CHECK_EQUAL(tf.GetCenter(), cen);
   BOOST_CHECK_EQUAL(tf.GetTrans(), tra);
diff --git a/modules/gfx/src/bitmap_io.cc b/modules/gfx/src/bitmap_io.cc
index ab42f9de5a67242ee9edf51a705c6cec4a078121..4245c32ec0b7b70daf17f56f73349b10cd39dfa8 100644
--- a/modules/gfx/src/bitmap_io.cc
+++ b/modules/gfx/src/bitmap_io.cc
@@ -114,7 +114,7 @@ Bitmap import_png(const String& filename)
   int png_transforms;
   png_bytep *row_pointers;
   png_uint_32 row,column,chn;
-  png_uint_32 width,height,bpp;
+  png_uint_32 width,height;
   
   if((fp=fopen(filename.c_str(),"rb"))==NULL) {
     LOG_ERROR("error opening " << filename);
@@ -158,8 +158,7 @@ Bitmap import_png(const String& filename)
   
   width=(unsigned int)png_get_image_width(png_ptr, info_ptr);
   height=(unsigned int)png_get_image_height(png_ptr, info_ptr);
-  bpp=(unsigned int)png_get_bit_depth(png_ptr,info_ptr);
-
+ 
   boost::shared_array<unsigned char> data(new unsigned char[width*height*channels]);
   
   row_pointers = png_get_rows(png_ptr, info_ptr);
diff --git a/modules/gfx/src/exporter.cc b/modules/gfx/src/exporter.cc
index 28dbd9b692365f4cfd1590d584a92a0ebbac7477..5100490c1d1ed852b9788f05d57ad3a05e38beaa 100644
--- a/modules/gfx/src/exporter.cc
+++ b/modules/gfx/src/exporter.cc
@@ -28,7 +28,6 @@ namespace ost { namespace gfx {
     normal_tf_=geom::Mat3();
     geom::Mat4 Tmat,Rmat,Smat,Cmat;
     if(to_origin_) {
-      geom::Vec3 trans=scene->GetTransform().GetTrans();
       geom::Vec3 cen=scene->GetTransform().GetCenter();
       vertex_tf_=geom::Mat4(scene->GetTransform().GetRot()) *
                  geom::Mat4(scale_, 0.0, 0.0, 0.0,
diff --git a/modules/gfx/src/impl/backbone_trace.cc b/modules/gfx/src/impl/backbone_trace.cc
index efcd761a5304f9f6c03ffe5362d7ee976dda8d2e..7f5cc812110d5d9dce6858c7756658cb6202b2eb 100644
--- a/modules/gfx/src/impl/backbone_trace.cc
+++ b/modules/gfx/src/impl/backbone_trace.cc
@@ -210,8 +210,6 @@ void BackboneTrace::PrepList(NodeEntryList& nelist) const
   // start loop with the second residue
   unsigned int i=1;
   for(;i<nelist.size()-1;++i) {
-    geom::Vec3 p10=p0-p1;
-    geom::Vec3 p12=p2-p1;
     dir=geom::Normalize(p2-p0);
     e1->direction = dir;
     orth=geom::Normalize(geom::Cross(dir,e1->normal));
diff --git a/modules/gfx/src/impl/entity_detail.cc b/modules/gfx/src/impl/entity_detail.cc
index 407654cfcfa514cc379a240ac1a68bc6d131a077..7e7f65989bca37bfdbba9ef8c68e2208492cfec9 100644
--- a/modules/gfx/src/impl/entity_detail.cc
+++ b/modules/gfx/src/impl/entity_detail.cc
@@ -311,8 +311,6 @@ SplineEntryList Spline::Generate(const SplineEntryList& entry_list, int nsub, ui
   sublist.at(0).direction=geom::Normalize(p1-p0);
   unsigned int i=1;
   for(;i<sublist.size()-1;++i) {
-    geom::Vec3 p10 = p0-p1;
-    geom::Vec3 p12 = p2-p1;
     geom::Vec3 dir=geom::Normalize(p2-p0);
     sublist.at(i).direction=dir;
     geom::Vec3 orth=geom::Normalize(geom::Cross(dir,sublist[i].normal));
diff --git a/modules/gfx/src/render_options/render_options.cc b/modules/gfx/src/render_options/render_options.cc
index 0c5597b33648663ad1afc18f853700cbceabe2a6..660ffa89428a5bcbf5835e4db2f5d3f33fab4c13 100644
--- a/modules/gfx/src/render_options/render_options.cc
+++ b/modules/gfx/src/render_options/render_options.cc
@@ -51,7 +51,6 @@ bool RenderOptions::RemoveObserver(EntityP entity)
 
 void RenderOptions::NotifyStateChange()
 {
-  InputEvent event = InputEvent(INPUT_DEVICE_MOUSE,INPUT_COMMAND_REBUILD,0);
   EntityPObservers::const_iterator observers_it = this->observers_.begin() ;
   while( observers_it != this->observers_.end() )
   {
diff --git a/modules/gui/src/python_shell/python_namespace_tree_item.cc b/modules/gui/src/python_shell/python_namespace_tree_item.cc
index b3e2960901f91b003c3fed8184f5d9e39a6313e6..e16bbede4c7b3726bff8bec166f8b8caa8988477 100644
--- a/modules/gui/src/python_shell/python_namespace_tree_item.cc
+++ b/modules/gui/src/python_shell/python_namespace_tree_item.cc
@@ -107,13 +107,9 @@ void PythonNamespaceTreeItem::FetchMore()
       continue;
     }
     bp::object child_namespace;
-    bool found=false;
     try{
       String keystring=bp::extract<String>(keys[i]);
       child_namespace=namespace_.attr(keystring.c_str());
-      if (bp::len(dir(child_namespace))>0) {
-        found=true;
-      }      
     } catch(bp::error_already_set) {
       PyErr_Clear();
     }
diff --git a/modules/gui/src/widget_geom_handler.cc b/modules/gui/src/widget_geom_handler.cc
index 431fd8ff1903a5e04f456528b1ab86640e3f58d2..efb6d752a83c802fd6339e1be26c338d9242f8d0 100644
--- a/modules/gui/src/widget_geom_handler.cc
+++ b/modules/gui/src/widget_geom_handler.cc
@@ -34,7 +34,6 @@ void WidgetGeomHandler::LoadGeom(const QString& prefix)
   settings.beginGroup(prefix+this->objectName());
   if (settings.contains("pos") && settings.contains("size")) {
     QPoint pos = settings.value("pos").toPoint();
-    QSize size = settings.value("size").toSize();
     Qt::WindowStates state = Qt::WindowStates(settings.value("state").toInt());
     widget_->move(pos);
     widget_->setWindowState(state);
diff --git a/modules/img/base/tests/test_value_holder.cc b/modules/img/base/tests/test_value_holder.cc
index f5b09f938f0bd48ba09e0701631d10ab67f4e8c4..bd0cacbd6ba76084ea7933717ff47a308dc15136 100644
--- a/modules/img/base/tests/test_value_holder.cc
+++ b/modules/img/base/tests/test_value_holder.cc
@@ -91,8 +91,6 @@ test_suite* CreateValueHolderTest()
 {
   using namespace value_holder_test;
   
-  typedef boost::mpl::vector<Real, Complex> values;
-
   test_suite* ts=BOOST_TEST_SUITE("ValueHolder Test");
 
   ts->add( BOOST_TEST_CASE(ReadWrite<Real>) );
diff --git a/modules/io/pymod/export_mmcif_io.cc b/modules/io/pymod/export_mmcif_io.cc
index d3213357183cf73841d9d1386e612b6e0828ca40..f798ba8c9c23a804a2bb0e08a9707aca0f58c374 100644
--- a/modules/io/pymod/export_mmcif_io.cc
+++ b/modules/io/pymod/export_mmcif_io.cc
@@ -99,7 +99,6 @@ void export_mmcif_io()
                   &MMCifInfoCitation::SetAuthorList)
   ;
 
-  typedef std::vector<MMCifInfoCitation> MMCifInfoCitationList;
   class_<std::vector<MMCifInfoCitation> >("MMCifInfoCitationList", init<>())
     .def(vector_indexing_suite<std::vector<MMCifInfoCitation> >())
   ;
@@ -124,7 +123,6 @@ void export_mmcif_io()
                   &MMCifInfoTransOp::SetMatrix)
   ;
 
-  typedef std::vector<MMCifInfoTransOp> MMCifInfoTransOpList;
   class_<std::vector<MMCifInfoTransOp> >("MMCifInfoTransOpList", init<>())
     .def(vector_indexing_suite<std::vector<MMCifInfoTransOp> >())
   ;
@@ -134,7 +132,6 @@ void export_mmcif_io()
     .def(vector_indexing_suite<std::vector<MMCifInfoTransOpPtr>, true >())
   ;
 
-  typedef std::vector<MMCifInfoTransOpPtrList > MMCifInfoTransOpPtrListList;
   class_<std::vector<MMCifInfoTransOpPtrList > >("MMCifInfoTransOpPtrListList",
                                                 init<>())
     .def(vector_indexing_suite<std::vector<MMCifInfoTransOpPtrList >, true >())
@@ -227,7 +224,6 @@ void export_mmcif_io()
   class_<MMCifInfoStructRefSeqDifs>("MMCifInfoStructRefSeqDifs", init<>())
   	.def(vector_indexing_suite<MMCifInfoStructRefSeqDifs, true>())
   ;
-  typedef std::vector<MMCifInfoBioUnit> MMCifInfoBioUnitList;
   class_<std::vector<MMCifInfoBioUnit> >("MMCifInfoBioUnitList", init<>())
     .def(vector_indexing_suite<std::vector<MMCifInfoBioUnit> >())
   ;
diff --git a/modules/io/src/img/map_io_png_handler.cc b/modules/io/src/img/map_io_png_handler.cc
index d77db114b4d20c72d026d10e3f6e2435a8737b06..61156a58b2121bb00b698455906a9733125f3907 100644
--- a/modules/io/src/img/map_io_png_handler.cc
+++ b/modules/io/src/img/map_io_png_handler.cc
@@ -111,7 +111,7 @@ void MapIOPngHandler::Import(img::MapHandle& image, std::istream& f,const ImageF
   png_bytep *row_pointers;
   png_uint_32 row,column;
   png_byte *png_data;
-  png_uint_32 width,height,bpp;
+  png_uint_32 width,height;
   std::ostringstream mesg;
 
   PNG form;
@@ -156,7 +156,6 @@ void MapIOPngHandler::Import(img::MapHandle& image, std::istream& f,const ImageF
 
   width=(unsigned int)png_get_image_width(png_ptr, info_ptr);
   height=(unsigned int)png_get_image_height(png_ptr, info_ptr);
-  bpp=(unsigned int)png_get_bit_depth(png_ptr,info_ptr);
 
   // TODO 16 bit greyscale
 
diff --git a/modules/io/src/mol/mmcif_reader.cc b/modules/io/src/mol/mmcif_reader.cc
index 52cd7e1ae82f20b47834bfe69862097fd9d0dfd9..619daac3c4ecfd5b348394da0389890f0ad6f920 100644
--- a/modules/io/src/mol/mmcif_reader.cc
+++ b/modules/io/src/mol/mmcif_reader.cc
@@ -374,9 +374,9 @@ bool MMCifReader::ParseAtomIdent(const std::vector<StringRef>& columns,
     return false;
   } 
 
-  std::pair<bool, int> a_num = this->TryGetInt(columns[indices_[AS_ID]],
-                                               "atom_site.id",
-                                          profile_.fault_tolerant); // unit test
+  this->TryGetInt(columns[indices_[AS_ID]],
+                  "atom_site.id",
+                  profile_.fault_tolerant); // unit test
 
   alt_loc = columns[indices_[LABEL_ALT_ID]][0];
   res_name = columns[indices_[LABEL_COMP_ID]];
diff --git a/modules/mol/alg/src/lddt.cc b/modules/mol/alg/src/lddt.cc
index 2509a0af9371ef15d6ec18d9d744bc916340893d..c4c9ba5aa5512c4749a26e74a2349b21e4a9313a 100644
--- a/modules/mol/alg/src/lddt.cc
+++ b/modules/mol/alg/src/lddt.cc
@@ -506,7 +506,6 @@ int main (int argc, char **argv)
         ResNum rnum = ritv.GetNumber();
         bool assessed = false;
         String assessed_string="No";
-        bool quality_problems = false;
         String quality_problems_string="No";
         Real lddt_local = -1;
         String lddt_local_string="-";
@@ -519,12 +518,10 @@ int main (int argc, char **argv)
         }
         if (ritv.HasProp("stereo_chemical_violation_sidechain") || 
             ritv.HasProp("steric_clash_sidechain")) {
-          quality_problems = true;
           quality_problems_string="Yes";
         }
         if (ritv.HasProp("stereo_chemical_violation_backbone") || 
             ritv.HasProp("steric_clash_backbone")) {
-          quality_problems = true;
           quality_problems_string="Yes+";
         }