Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only install necessary components in conda packages. #2209

Merged
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions conda/recipes/libraft/build_libraft.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/usr/bin/env bash
# Copyright (c) 2022-2023, NVIDIA CORPORATION.
# Copyright (c) 2022-2024, NVIDIA CORPORATION.

./build.sh libraft --allgpuarch --compile-lib --build-metrics=compile_lib --incl-cache-stats --no-nvtx
./build.sh libraft --allgpuarch --compile-lib --build-metrics=compile_lib --incl-cache-stats --no-nvtx -n
cmake --install cpp/build --component compiled
Comment on lines +4 to +5
Copy link
Contributor Author

@bdice bdice Mar 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This now looks a lot like https://github.com/rapidsai/raft/blob/branch-24.04/conda/recipes/libraft/build_libraft_static.sh except installing the compiled component rather than compiled-static.

6 changes: 4 additions & 2 deletions conda/recipes/libraft/build_libraft_headers.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
#!/usr/bin/env bash
# Copyright (c) 2022-2023, NVIDIA CORPORATION.
# Copyright (c) 2022-2024, NVIDIA CORPORATION.

./build.sh libraft --allgpuarch --no-nvtx
./build.sh libraft --allgpuarch --no-nvtx -n
cmake --install cpp/build --component hnswlib
cmake --install cpp/build --component raft
2 changes: 1 addition & 1 deletion cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,8 @@ rapids_cpm_init()

if(NOT BUILD_CPU_ONLY)
# CCCL before rmm/cuco so we get the right version of CCCL
robertmaynard marked this conversation as resolved.
Show resolved Hide resolved
include(cmake/thirdparty/get_cccl.cmake)
include(cmake/thirdparty/get_rmm.cmake)
include(cmake/thirdparty/get_cccl.cmake)
include(cmake/thirdparty/get_cutlass.cmake)

include(${rapids-cmake-dir}/cpm/cuco.cmake)
Expand Down
12 changes: 10 additions & 2 deletions cpp/cmake/thirdparty/get_hnswlib.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,16 @@ function(find_and_configure_hnswlib)
"$<INSTALL_INTERFACE:include>")

if(NOT PKG_EXCLUDE_FROM_ALL)
install(TARGETS hnswlib EXPORT hnswlib-exports)
install(DIRECTORY "${hnswlib_SOURCE_DIR}/hnswlib/" DESTINATION include/hnswlib)
install(
TARGETS hnswlib
COMPONENT hnswlib
EXPORT hnswlib-exports
)
install(
DIRECTORY "${hnswlib_SOURCE_DIR}/hnswlib/"
COMPONENT hnswlib
DESTINATION include/hnswlib
)

# write install export rules
rapids_export(
Expand Down
4 changes: 2 additions & 2 deletions cpp/template/build.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# Copyright (c) 2023, NVIDIA CORPORATION.
# Copyright (c) 2023-2024, NVIDIA CORPORATION.

# raft empty project template build script

Expand All @@ -13,7 +13,7 @@ BUILD_TYPE=Release
BUILD_DIR=build/

RAFT_REPO_REL=""
EXTRA_CMAKE_ARGS=""
EXTRA_CMAKE_ARGS="--trace"
set -e


Expand Down
5 changes: 4 additions & 1 deletion cpp/test/sparse/spmm.cu
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,17 @@
*/

#include "../test_utils.cuh"
#include <gtest/gtest.h>

#include <raft/core/resource/cuda_stream.hpp>
#include <raft/core/resource/thrust_policy.hpp>
#include <raft/random/rng.cuh>
#include <raft/sparse/linalg/spmm.hpp>
#include <raft/util/cuda_utils.cuh>

#include <thrust/fill.h>

#include <gtest/gtest.h>

namespace raft {
namespace sparse {
namespace linalg {
Expand Down
Loading