Commit Graph

88 Commits

Author SHA1 Message Date
Ric
c9199cf1da Address #2753 (#3750)
* add test export heder to gitignore

* define export macros in separate file

* install new header

* patch GA with the new macros

* fix struct declarations

* fix conformerparser exports

* fix MolSGroupParsing ParseV3000Array export

* fix java wrappers

* export exceptions

* remove duplicated exports

* Build RDGeneral exceptions into lib

* export queries, only for *nix

* fix RingDecomposerLib header manipulation

* fix CIP labeler test issues
2021-02-15 14:29:04 +01:00
Greg Landrum
52c83c45f0 Add some more comprehensive R-Group Decomposition tests (#3778)
* start to add some human-readable regression-test like examples for RGD

* small examples from JMedChem

* add helper viewer

* make that generate actual JSON

* use JSON of full output for tests
move JSON generation to RGroupUtils.h

* switch to using JSON from files

* add test notebook

* add jupyter testing to the code

* add nbval to linux test env

* add notebook tests to mac and windows too

* add toJSON for columns too
2021-02-05 10:35:32 +01:00
Eisuke Kawashima
e0b665bfe1 Clean up CMake files (#3417)
* Clean up CMake files

* bump CMake minimum required version to 3.7 to utilize
  [`VERSION_GREATER_EQUAL`](https://cmake.org/cmake/help/v3.7/release/3.7.html#index-0-command:if)
* improve catch-dependency
* fix conditionals
* use early return
* properly use CMake commands

* Apply suggestions from code review

Co-authored-by: Greg Landrum <greg.landrum@gmail.com>
2020-11-28 08:00:39 +01:00
Paolo Tosco
2b592950c9 A couple of minor improvements to FindCairo (#3535)
* - allow defining a specific path to Cairo libraries and headers
- link against Xau library if needed

* changes in response to review

* removed the libXau bit as it is not needed
2020-11-19 09:09:48 +01:00
Paolo Tosco
947144ab6d Avoid really slow Windows conda builds (#3287)
* avoid that if CMAKE_BINARY_DIR==CMAKE_SOURCE_DIR (e.g., conda builds)
export.h is overwritten at each incremental build causing the whole
RDKit to be rebult every time

* use existing CMake function so we don't have to maintain our own
2020-07-13 14:47:29 +02:00
Riccardo Vianello
29ad06f099 fix a small inconsistency in the name of the inchi package (#3182)
with cmake 3.17.2 the original code produced the following warning:
"The package name passed to `find_package_handle_standard_args` (INCHI) does
not match the name of the calling package (Inchi).  This can lead to
problems in calling code that expects `find_package` result variables
(e.g., `_FOUND`) to follow a certain pattern."
2020-05-25 09:08:17 +02:00
Ric
39bcee635e Mem checkup (#3083)
* clean up in testDatastructs

* avoid jump on unassigned mem in rxns

* set valgrind error exit code

* update suppressions

* clean up RDValue in testDict

* don't leak mol if parsing Maestro file fails

* don't leak mol if parsing PDB block fails

* cleanup leftover rxns in testReaction

* cleanup mol if CX extensions cannot be parsed

* cleanup leftover mols in smiTest1

* cleanup leftover mols in moldraw2DTest1

* cleanup leftover mols in testSubstructMatch

* make testEnumeration go easier on valgrind

* reduce R counts
2020-04-17 17:48:58 +02:00
Greg Landrum
45bf58754a Cleanup some cmake dependencies (#3077)
* change minimal cmake version to a consistent 3.5

* progress towards a cleanup

* get the basic python deps working

* two more libs

* another round of changes
all tests pass at this point

* next round of changes
all tests pass at this point

* close to done
all tests pass

* very close

* almost done

* shift the RDBoost dependencies around a bit

* remove an extraneous python linkage
this is trying to get the mac builds working again

* Only link to python if it was built shared (#3091)

* change in response to review

Co-Authored-By: Ric <ricrogz@users.noreply.github.com>

* move that suppression of the maybe-uninitialized warning to BoostStartInclude.h

Co-authored-by: Brian Kelley <fustigator@gmail.com>
Co-authored-by: Ric <ricrogz@users.noreply.github.com>
2020-04-17 14:34:23 +02:00
Ric
cc8e21864b Update Maeparser & Coordgen Dependencies (#3011)
* update

* remove references to templates.mae
2020-03-17 13:50:57 +01:00
Eisuke Kawashima
5cd27a242f Fix typo (#2862)
* Fix typo

* Reflect the comments

* Fix more typos
2019-12-31 06:43:27 +01:00
Eisuke Kawashima
dc7cc84a0c Fix typo [ci skip] 2019-10-17 17:45:50 +09:00
Greg Landrum
06237a88c5 cleanup to make static builds work 2019-03-31 08:22:25 +02:00
Ric
be3170d0d5 Mem errors clean up (#2305)
* fix test leaks

* fix "invalid read" when casting Query to EqualityQuery

* fix error cleanup in SMILES/SMARTS parsers

* SMILES/SMARTS parser fix updated *.cmake

* fix error cleanup in SLN parser

* SLN parser updated *.cmake

* updated suppressions

* update loop in sln bison
2019-03-08 05:39:59 +01:00
Greg Landrum
24f1737839 Remove a bunch of Python2-related warts (#2315)
* remove all of the "from __future__" imports

* remove the first batch of rdkit.six imports/uses

* next step of rdkit.six removal

* removing xrange, range, and some maps

* next round of removals

* next round of cleanups

* fix inchi test

* last bits of "from rdkit.six" are gone

* and the last of the six stuff is gone

* strange importlib problem
2019-03-06 20:43:49 -05:00
Ric
3cc9206a48 Update build rules for coorgen & maeparser (#2184) 2019-01-06 06:28:00 +00:00
Greg Landrum
9ac981d60a Merge branch 'memcheck_on_tests' of https://github.com/ricrogz/rdkit into ricrogz-memcheck_on_tests 2018-10-31 05:25:56 +01:00
Ric
a6b26253ff Fix (most of) mem problems (#2123)
* do not use new on loggers

* del pointers in testDistGeom

* Update Dict hasNonPOD status on bulk update

* delete new Dicts in memtest1.cpp

* fixes in MolSuppliers and testFMCS

* PeriodicTable singleton as unique_ptr

* fix EEM_arrays leak

* fix leaks in testPBF

* fix ParamCollection leak in test UFF

* fix leaks in MMFF

* clear prop dict before read in in pickler

* fix leaks in testFreeSASA

* fix leaks in test3D

* modernize Dict.h & SmilesParse.cpp

* fix leaks in testQuery

* fix leaks in testCrystalFF

* fix leaks in cxsmilesTest

* fix leaks in Catalog & mol cat test

* fix leaks in ShapeUtils & tests

* fix leaks in testSubgraphs1

* fix leaks testFingerprintGenerators

* fix leaks in Catalog/FilterCatalog

* fix leaks in graphmolqueryTest

* these changes reduce bison parse leaks

* fixed leaks in testChirality.cpp

* fix leaks + 2 tests in testMolWriter

* fix 4m leaks in substructLibraryTest

* small improvements to molTautomerTest; still leaks

* fix leaks in testRGroupDecomp

* fix leaks in test; parser still leaks

* fix leaks in itertest

* fix 4m leaks in testDepictor

* fixes in smatest; still leaking due to parser

* fixes in testSLNParse; still leaking due to parser

* flex/bison: always add atoms with ownership; smarts error cleanup

* fix leaks in testReaction

* fix leaks in testSubstructMatch

* fix leaks in resMolSupplierTest

* fix leaks in testChemTransforms + bug in ChemTransforms

* fix leaks in testPickler

* fix leaks in testMolTransform

* fix leaks in testFragCatalog

* fix leak in testSLNParse. Still leaks due to Smiles

* fixed most leaks in testMolSupplier

* pre bison fix

* fix some atom & bond parse problems; others still fail

* bison smiles & smarts, atoms & bonds more or less fixed

* fix leaks in molopstest.cpp

* fix leaks in testFingerprints, MACCS.cpp & AtomPairs.cpp

* fix leaks in moldraw2Dtest1

* fix leaks in testDescriptors

* fix leaks in testInchi

* fix leaks in testUFFForceFieldHelpers

* fix leaks in hanoiTest & new_canon.h

* fix leaks in testMMFFForceField

* fix leaks in graphmolTest1

* fix leaks in testMMFFForceFieldHelpers

* fix leaks in testDistGeomHelpers

* fix leaks in testMolAlign

* initialize occupancy & temp facto with default values

* fix leak in TautomerTransform

* updated suppressions

* fix testStructChecker

* fix logging & py tests

* fix TautomerTransform class/struct issue

* remove misplaced delete in testSLNParse

* deinit in testAvalonLib1

* fix Avalon-triggered(?) bug in StructChecker/Pattern.cpp

* fix random testMolWriter/Supplier fails

- diversify output file names to avoid clashing.
- unify Writers close/destruct behavior.
- flushing/closing in tests.

* use reset in FFs Params.cpp

* comments on testMMFFForceField

* unrequired 'if's added to mol suppliers

* correct cast in FilterCatalog.h

* use unique_ptr in MACCS Patterns

* remove unrequred if in new_canon

* update & move suppressions
2018-10-29 14:33:26 +00:00
Ric
0ed583eb4f move valgrind suppressions into Code/cmake/ 2018-10-27 11:40:02 -04:00
Greg Landrum
7976c36b87 add explicit catch dependency for tests that use it (#2126) 2018-10-19 16:38:58 +02:00
Ric
4294921058 Enabled ctest memcheck to run on tests 2018-10-12 09:34:09 -04:00
Paolo Tosco
f7c888844d moved test.h from RDBoost to RDGeneral for consistency with export.h (#2074) 2018-10-11 17:35:23 -04:00
Greg Landrum
223513a76e Start to use Catch2 for new tests (#1732)
* backup

* build works

* works

* builds on linux

* rename the test

* add another test to make sure that works
2018-09-04 10:32:17 -04:00
Greg Landrum
2738c35178 Fixes #1903 (#1971)
* Fixes #1903

* update SWIG bindings too
2018-07-25 09:14:17 +02:00
Paolo Tosco
1009511907 - fixes the absence of the RDKit prefix in .so/.dylib libraries (#1915) 2018-06-15 07:43:56 +01:00
Paolo Tosco
45499c7bca - allows coordgen and maeparser to be built as static libraries (#1909) 2018-06-14 05:43:59 +02:00
Dan N
5c919dbbdc Fix curl fallback for downloading files (#1904)
The curl file download fallback option was not saving files as
the correct filename. Instead, it used the -O option, which
saved the files using the remote's name for the file! This
was problematic for files downloaded using specification of git
sha.
2018-06-09 04:48:18 +02:00
Paolo Tosco
5ca9148ece - do not re-generate export.h and test.h if they have not changed (#1901) 2018-06-08 06:56:37 +02:00
Paolo Tosco
97d147b3f1 - fixes the dynamic/static library CMake logic (#1875) 2018-05-27 07:13:03 +02:00
Paolo Tosco
c08ea49bda - enable building DLLs on Windows (#1861)
* - enable building DLLs on Windows

* - export.h and test.h are now auto-generated by CMake
2018-05-16 08:42:41 +02:00
Greg Landrum
26f1f4cf01 builds on ubuntu 18.04 (#1858) 2018-05-10 05:04:39 +02:00
Greg Landrum
0959261f37 Fixes #1454 (#1838)
* Fixes #1454; still needs a bit more thinking though

* forgot the necessary version bump

* review related cleanup and a fix to allow the SWIG wrappers to be built
2018-05-07 09:48:47 -04:00
Greg Landrum
dc2fc401f1 allow libs to not be installed (#1832) 2018-04-21 07:27:37 +02:00
Greg Landrum
044bb83bd0 Fix python linkage (#1808)
* apply (manually) #1807 from @bp-kelley to modern_cxx branch and fix (hopefully) a windows problem

* another windows problem

* another windows problem

* windows now builds locally

* update link targets
2018-04-05 06:16:17 +02:00
Greg Landrum
38a449a03d fix an irritating cmake problem (#1715) 2018-01-10 16:14:58 -05:00
Greg Landrum
c7da217d13 update static linkage too 2018-01-01 08:50:42 +01:00
Greg Landrum
62d53d2df6 help with the windows builds 2017-12-28 06:09:14 +00:00
Matt Swain
15c31e1f88 Update embedded InChI to v1.05 (#1684)
* Update download-inchi.sh for InChI 1.05

* Fix downloadAndCheckMD5

* Update FindInchi.cmake for InChI 1.05

* Update CMakeLists.txt for InChI 1.05
2017-12-21 05:45:24 +01:00
Greg Landrum
03e351e68b remove the dependency of the static libs on the dynamic libs 2017-11-25 14:07:01 +01:00
Patrick Avery
206e8a8e17 Update CPack to create .deb files correctly (#1580)
* Update CPack to create .deb files correctly

* get this working with debs
2017-11-15 06:51:38 +01:00
Alain Vaucher
7795a425ff Further cmake improvements (#1515)
* New syntax to import Qt5 dependency in MolDraw2D

* In QTDemo, not necessary to import Qt explicitly because it is automatically imported through target MolDraw2D

* improve import of Cairo dependency

* Remove explicit linking of Cairo in C++ examples

* Use imported targets for Boost

* Using imported CMake targets for Eigen

* Use imported targets for Threads

* Simplify sample CMakeLists

* Remove duplication

* a couple small changes for travis

* typo

* update toolchain to trusty

* switch to requiring at least boost 1.56

* typo

* update boost dependency to pull in the build that has more libraries

* meaningless commit to trigger travis

* switch to ust libc++

* install libc++

* check abi

* try the other one; disable py27 for the moment to speed things up

* switch to c++11, that seems necessary with the conda boost builds at the moment

* re-enable python2.7
2017-08-07 15:49:08 +02:00
Alain Vaucher
21e6b81935 Merge branch 'master' into modern-cmake 2017-07-01 17:59:14 +02:00
Alain Vaucher
7c22e95fbd Setting correct dependencies for the static variants of the libraries 2017-07-01 17:18:51 +02:00
Alain Vaucher
9261d8c74b Linking against the interface library also for the static variant 2017-07-01 14:10:18 +02:00
Alain Vaucher
5bdf2a3cf4 Add INTERFACE library, rdkit_base, against which all other rdkit libraries will link 2017-07-01 13:40:34 +02:00
Paolo Tosco
ea6cfe35ee - updated FindCairo.cmake (#1455) 2017-06-29 20:33:12 +02:00
Greg Landrum
1d04eb3351 add "RDKit" to the beginning of all library names (#1349) 2017-03-20 09:33:13 -04:00
gedeck
0845573a45 Script PythonFormat uses yapf to check the formatting of Python files 2016-10-29 17:13:13 -04:00
Greg Landrum
4f2ec84e7b Add some 3D molecular descriptors (#1084)
* update .gitignore

* foundation for 3D descriptors
move PBF into core

* cleanup work

* a bit more cleanup

* move the principal moments calc to MolTransforms

* cleanup

* cleanups

* add caching of the principal moments and values

* do not include the 3D descriptors in MolDescriptors.h

* the properties are computed

* add PMI descriptors and tests

* add tests for NPR descriptors

* return 0 when the largest PMI is zero

* PMI edge case tests

* NPR edge case tests

* PBF edge case tests

* PBF edge case tests

* more edge cases

* add a few more 3d descriptors

* add defns to docs

* tests for the new descriptors

* add versions to new descriptors

* add 3d descriptors to python wrapper

* add eigen support to the travis build

* try to get non-windows builds working

* remove computeCovarianceMatrix() from java wrapper

* make pmi property names "private"
2016-10-10 08:34:08 -04:00
gedeck
e9af48ffd7 Issue1071/yapf (#1078)
* Issue #1071: add yapf configuration file

* yapf formatting of Code directory

* yapf formatting of Contrib directory

* yapf formatting of Data directory

* yapf formatting of Docs directory

* yapf formatting of External directory

* yapf formatting of Projects directory

* yapf formatting of Regress directory

* yapf formatting of Scripts directory

* yapf formatting of Web directory

* yapf formatting of rdkit directory
2016-09-23 04:58:46 +02:00
Paolo Tosco
5d3bb11488 Fix Inchi being hardcoded into PostgreSQL (#1009)
* - this should fix the problem with "Inchi" being hardcoded into PostgreSQL

* - moved the InChI check code out of the main CMakeLists.txt
  into FindInchi.cmake
2016-08-08 11:22:56 +02:00