openbabel2/openbabel-2.3.2-gcc-6.1.0.patch

37 lines
1.8 KiB
Diff

diff -ru openbabel-2.3.2.patched/include/openbabel/alias.h openbabel-2.3.2/include/openbabel/alias.h
--- openbabel-2.3.2.patched/include/openbabel/alias.h 2016-08-04 12:35:49.111515096 +0200
+++ openbabel-2.3.2/include/openbabel/alias.h 2010-09-07 19:07:53.000000000 +0200
@@ -115,7 +115,7 @@
}
bool FromNameLookup(OBMol& mol, const unsigned int atomindex);
#ifdef HAVE_SHARED_POINTER
- typedef std::vector< std::pair<std::string, shared_ptr<OBSmartsPattern> > > SmartsTable;
+ typedef std::vector< std::pair<std::string, std::tr1::shared_ptr<OBSmartsPattern> > > SmartsTable;
static bool LoadFile(SmartsTable& smtable);
#endif
};
diff -ru openbabel-2.3.2.patched/include/openbabel/shared_ptr.h openbabel-2.3.2/include/openbabel/shared_ptr.h
--- openbabel-2.3.2.patched/include/openbabel/shared_ptr.h 2016-08-04 12:34:32.386554217 +0200
+++ openbabel-2.3.2/include/openbabel/shared_ptr.h 2011-10-12 22:24:02.000000000 +0200
@@ -21,7 +21,7 @@
#define shared_ptr boost::shared_ptr
#else
#include <memory>
- #if __GNUC__ == 4 //&& __GNUC_MINOR__ < 3 removed at the suggestion of Konstantin Tokarev
+ #if __GNUC__ >= 4 //&& __GNUC_MINOR__ < 3 removed at the suggestion of Konstantin Tokarev
#include <tr1/memory>
#endif
using std::tr1::shared_ptr;
diff -ru openbabel-2.3.2.patched/src/alias.cpp openbabel-2.3.2/src/alias.cpp
--- openbabel-2.3.2.patched/src/alias.cpp 2016-08-04 12:36:42.821486062 +0200
+++ openbabel-2.3.2/src/alias.cpp 2012-10-05 22:17:36.000000000 +0200
@@ -270,7 +270,7 @@
//OBSmartsPattern objects are not copyable without complications,
//so reference semantics used.
- shared_ptr<OBSmartsPattern> psp(new OBSmartsPattern);
+ std::tr1::shared_ptr<OBSmartsPattern> psp(new OBSmartsPattern);
psp->Init(ssmarts.str());
smtable.push_back(make_pair(vec[0], psp));
}