"vscode:/vscode.git/clone" did not exist on "643ea90ea19d517fe22b83a7a31d1c802b60b19a"
Commit 4e6e8ba3 authored by peastman's avatar peastman Committed by GitHub
Browse files

Merge pull request #1518 from peastman/appveyor

Fix OpenCL on AppVeyor
parents d4d25d46 b518ad19
......@@ -29,6 +29,7 @@ install:
# Download OpenCL Headers and build the ICD loader
- ps: $opencl_registry = "https://www.khronos.org/registry/cl"
- ps: $opencl_github = "KhronosGroup/OpenCL-Headers"
- ps: mkdir C:/opencl > $null
- ps: cd C:/opencl
- ps: wget $opencl_registry/specs/opencl-icd-1.2.11.0.tgz -OutFile opencl-icd-1.2.11.0.tgz
......@@ -36,7 +37,7 @@ install:
- ps: 7z x opencl-icd-1.2.11.0.tar > $null
- ps: mv .\icd\* .
- ps: mkdir inc/CL > $null
- ps: wget $opencl_registry/api/1.2/ | select -ExpandProperty links | where {$_.href -like "*.h*"} | select -ExpandProperty outerText | foreach{ wget $opencl_registry/api/1.2/$_ -OutFile inc/CL/$_ }
- ps: wget https://github.com/$opencl_github | select -ExpandProperty links | where {$_.href -like "*.h*"} | select -ExpandProperty outerText | foreach{ wget https://raw.githubusercontent.com/$opencl_github/master/$_ -OutFile inc/CL/$_ }
- ps: mkdir lib > $null
- ps: cd lib
- cmake -G "NMake Makefiles" ..
......
......@@ -36,6 +36,7 @@
#include <cmath>
#include <sstream>
#include <vector>
#include <algorithm>
using namespace OpenMM;
using namespace std;
......@@ -108,7 +109,7 @@ void LocalEnergyMinimizer::minimize(Context& context, double tolerance, int maxI
if (x == NULL)
throw OpenMMException("LocalEnergyMinimizer: Failed to allocate memory");
double constraintTol = context.getIntegrator().getConstraintTolerance();
double workingConstraintTol = max(1e-4, constraintTol);
double workingConstraintTol = std::max(1e-4, constraintTol);
double k = tolerance/workingConstraintTol;
// Initialize the minimizer.
......
......@@ -33,6 +33,9 @@
* This tests the Cuda implementation of CudaAmoebaAngleForce.
*/
#ifdef WIN32
#define _USE_MATH_DEFINES // Needed to get M_PI
#endif
#include "openmm/internal/AssertionUtilities.h"
#include "openmm/Context.h"
#include "openmm/CustomAngleForce.h"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment