@ -78,10 +78,6 @@
#
# cc_test(example_test SRCS example_test.cc DEPS example glog gflags)
if(WITH_GPU)
add_definitions(-DPADDLE_WITH_GPU)
endif()
if(NOT APPLE)
find_package(Threads REQUIRED)
link_libraries(${CMAKE_THREAD_LIBS_INIT})
@ -1,7 +1 @@
add_subdirectory(detail)
if(${WITH_GPU})
nv_library(memory SRCS memory.cc)
else(${WITH_GPU})
cc_library(memory SRCS memory.cc)
endif(${WITH_GPU})
@ -14,7 +14,7 @@
#pragma once
#include "paddle/memory/detail/system_allocator.h"
#include "paddle/memory/detail/buddy_allocator.h"
namespace paddle {
namespace memory {
@ -16,6 +16,9 @@
#include <vector>
#include <mutex>
namespace detail {