From f9e9309162d6c3531074fb5b26b8b45197153570 Mon Sep 17 00:00:00 2001 From: qijun Date: Thu, 8 Mar 2018 10:13:21 +0800 Subject: [PATCH] fix mac build error --- paddle/fluid/inference/tests/test_helper.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/paddle/fluid/inference/tests/test_helper.h b/paddle/fluid/inference/tests/test_helper.h index d0688445fe642..0f5fe6d0aa9a5 100644 --- a/paddle/fluid/inference/tests/test_helper.h +++ b/paddle/fluid/inference/tests/test_helper.h @@ -110,6 +110,8 @@ void TestInference(const std::string& dirname, // Users can get the device_id using: // int device_id = place.GetDeviceId(); paddle::platform::SetDeviceId(0); +#else + PADDLE_THROW("'CUDAPlace' is not supported in CPU only device."); #endif }