2019-05-28 22:17:22 +08:00
|
|
|
# Copyright (c) Facebook, Inc. and its affiliates.
|
2018-06-02 14:35:30 +08:00
|
|
|
#
|
2019-05-28 22:17:22 +08:00
|
|
|
# This source code is licensed under the MIT license found in the
|
2018-06-02 14:35:30 +08:00
|
|
|
# LICENSE file in the root directory of this source tree.
|
2018-02-20 22:53:56 +08:00
|
|
|
|
2018-06-02 14:35:30 +08:00
|
|
|
-include ../../makefile.inc
|
2018-02-20 22:53:56 +08:00
|
|
|
|
2018-06-02 14:35:30 +08:00
|
|
|
CPU_TARGETS = 1-Flat 2-IVFFlat 3-IVFPQ
|
|
|
|
GPU_TARGETS = 4-GPU 5-Multiple-GPUs
|
2018-02-21 22:36:29 +08:00
|
|
|
|
2018-06-02 14:35:30 +08:00
|
|
|
default: cpu
|
2018-02-21 22:36:29 +08:00
|
|
|
|
2018-02-20 22:53:56 +08:00
|
|
|
all: cpu gpu
|
|
|
|
|
2018-06-02 14:35:30 +08:00
|
|
|
cpu: $(CPU_TARGETS)
|
2018-02-20 22:53:56 +08:00
|
|
|
|
2018-06-02 14:35:30 +08:00
|
|
|
gpu: $(GPU_TARGETS)
|
2018-02-20 22:53:56 +08:00
|
|
|
|
2019-04-11 20:20:38 +08:00
|
|
|
%: %.cpp ../../libfaiss.a
|
2019-05-24 20:46:53 +08:00
|
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) -o $@ $^ $(LDFLAGS) -I../../.. $(LIBS)
|
2018-02-21 22:36:29 +08:00
|
|
|
|
|
|
|
clean:
|
2018-06-02 14:35:30 +08:00
|
|
|
rm -f $(CPU_TARGETS) $(GPU_TARGETS)
|
|
|
|
|
|
|
|
.PHONY: all cpu default gpu clean
|