From 72bd54a7b6d3ea532cb73c066a31e9c43f3be631 Mon Sep 17 00:00:00 2001 From: rnou Date: Thu, 7 Jul 2022 09:48:06 +0200 Subject: [PATCH 1/3] Added Redis++ --- CMakeLists.txt | 5 ++ cmake/FindHiRedis.cmake | 117 ++++++++++++++++++++++++++++++++++ cmake/FindRedisPlusPlus.cmake | 117 ++++++++++++++++++++++++++++++++++ docker/0.1.0/Dockerfile | 10 ++- src/scord-ctl/CMakeLists.txt | 2 +- src/scord/CMakeLists.txt | 1 + 6 files changed, 250 insertions(+), 2 deletions(-) create mode 100644 cmake/FindHiRedis.cmake create mode 100644 cmake/FindRedisPlusPlus.cmake diff --git a/CMakeLists.txt b/CMakeLists.txt index c3db076a..67f87693 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -253,6 +253,11 @@ endif () ### variables. mark_variables_as_advanced(REGEX "^(FETCHCONTENT|fmt|FMT|spdlog|SPDLOG)_.*$") +### redisplusplus check +message(STATUS "[${PROJECT_NAME}] Checking for Redis Plus Plus") +find_package(RedisPlusPlus 1.3.3 REQUIRED) + + # ############################################################################## # Process subdirectories # ############################################################################## diff --git a/cmake/FindHiRedis.cmake b/cmake/FindHiRedis.cmake new file mode 100644 index 00000000..ba36ee37 --- /dev/null +++ b/cmake/FindHiRedis.cmake @@ -0,0 +1,117 @@ +################################################################################ +# Copyright 2021, Barcelona Supercomputing Center (BSC), Spain # +# # +# This software was partially supported by the EuroHPC-funded project ADMIRE # +# (Project ID: 956748, https://www.admire-eurohpc.eu). # +# # +# This file is part of scord. # +# # +# scord is free software: you can redistribute it and/or modify # +# it under the terms of the GNU General Public License as published by # +# the Free Software Foundation, either version 3 of the License, or # +# (at your option) any later version. # +# # +# scord is distributed in the hope that it will be useful, # +# but WITHOUT ANY WARRANTY; without even the implied warranty of # +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +# GNU General Public License for more details. # +# # +# You should have received a copy of the GNU General Public License # +# along with scord. If not, see . # +# # +# SPDX-License-Identifier: GPL-3.0-or-later # +################################################################################ + +#[=======================================================================[.rst: +FindHiRedis +--------- + +Find hiredis include dirs and libraries. + +Use this module by invoking find_package with the form:: + + find_package(HiRedis + [version] [EXACT] # Minimum or EXACT version e.g. 0.6.2 + [REQUIRED] # Fail with error if yaml-cpp is not found + ) + +Imported Targets +^^^^^^^^^^^^^^^^ + +This module provides the following imported targets, if found: + +``HIRedis::HiRedis`` + The HiRedis library + +Result Variables +^^^^^^^^^^^^^^^^ + +This will define the following variables: + +``HiRedis_FOUND`` + True if the system has the HiRedis library. +``HiRedis_VERSION`` + The version of the HiRedis library which was found. +``HiRedis_INCLUDE_DIRS`` + Include directories needed to use HiRedis. +``HiRedis_LIBRARIES`` + Libraries needed to link to HiRedis. + +Cache Variables +^^^^^^^^^^^^^^^ + +The following cache variables may also be set: + +``HiRedis_INCLUDE_DIR`` + The directory containing ``hiredis.h``. +``HiRedis_LIBRARY`` + The path to the HiRedis library. + +#]=======================================================================] + + +find_package(PkgConfig) +pkg_check_modules(PC_HiRedis QUIET hiredis) + +find_path(HiRedis_INCLUDE_DIR + NAMES hiredis/hiredis.h + PATHS ${PC_HiRedis_INCLUDE_DIRS} + PATH_SUFFIXES HiRedis +) + +find_library(HiRedis_LIBRARY + NAMES hiredis + PATHS ${PC_HiRedis_LIBRARY_DIRS} +) + +mark_as_advanced( + HiRedis_INCLUDE_DIR + HiRedis_LIBRARY +) + +set(HiRedis_VERSION ${PC_HiRedis_VERSION}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(HiRedis + FOUND_VAR HiRedis_FOUND + REQUIRED_VARS + HiRedis_LIBRARY + HiRedis_INCLUDE_DIR + VERSION_VAR HiRedis_VERSION +) + +if(HiRedis_FOUND) + set(HiRedis_LIBRARIES ${HiRedis_LIBRARY}) + set(HiRedis_INCLUDE_DIRS ${HiRedis_INCLUDE_DIR}) + set(HiRedis_DEFINITIONS ${PC_HiRedis_CFLAGS_OTHER}) +endif() + +if(HiRedis_FOUND AND NOT TARGET HiRedis::HiRedis) + add_library(HiRedis::HiRedis UNKNOWN IMPORTED) + set_target_properties(HiRedis::HiRedis PROPERTIES + IMPORTED_LINK_INTERFACE_LANGUAGES "CXX" + IMPORTED_LOCATION "${HiRedis_LIBRARY}" + INTERFACE_COMPILE_DEFINITIONS "${PC_HiRedis_CFLAGS_OTHER}" + INTERFACE_INCLUDE_DIRECTORIES "${HiRedis_INCLUDE_DIR}" +) +endif() diff --git a/cmake/FindRedisPlusPlus.cmake b/cmake/FindRedisPlusPlus.cmake new file mode 100644 index 00000000..43089297 --- /dev/null +++ b/cmake/FindRedisPlusPlus.cmake @@ -0,0 +1,117 @@ +################################################################################ +# Copyright 2021, Barcelona Supercomputing Center (BSC), Spain # +# # +# This software was partially supported by the EuroHPC-funded project ADMIRE # +# (Project ID: 956748, https://www.admire-eurohpc.eu). # +# # +# This file is part of scord. # +# # +# scord is free software: you can redistribute it and/or modify # +# it under the terms of the GNU General Public License as published by # +# the Free Software Foundation, either version 3 of the License, or # +# (at your option) any later version. # +# # +# scord is distributed in the hope that it will be useful, # +# but WITHOUT ANY WARRANTY; without even the implied warranty of # +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +# GNU General Public License for more details. # +# # +# You should have received a copy of the GNU General Public License # +# along with scord. If not, see . # +# # +# SPDX-License-Identifier: GPL-3.0-or-later # +################################################################################ + +#[=======================================================================[.rst: +FindRedisPlusPlus +--------- + +Find hiredis include dirs and libraries. + +Use this module by invoking find_package with the form:: + + find_package(RedisPlusPlus + [version] [EXACT] # Minimum or EXACT version e.g. 0.6.2 + [REQUIRED] # Fail with error if yaml-cpp is not found + ) + +Imported Targets +^^^^^^^^^^^^^^^^ + +This module provides the following imported targets, if found: + +``RedisPlusPlus::RedisPlusPlus`` + The RedisPlusPlus library + +Result Variables +^^^^^^^^^^^^^^^^ + +This will define the following variables: + +``RedisPlusPlus_FOUND`` + True if the system has the RedisPlusPlus library. +``RedisPlusPlus_VERSION`` + The version of the RedisPlusPlus library which was found. +``RedisPlusPlus_INCLUDE_DIRS`` + Include directories needed to use RedisPlusPlus. +``RedisPlusPlus_LIBRARIES`` + Libraries needed to link to RedisPlusPlus. + +Cache Variables +^^^^^^^^^^^^^^^ + +The following cache variables may also be set: + +``RedisPlusPlus_INCLUDE_DIR`` + The directory containing ``redis++.h``. +``RedisPlusPlus_LIBRARY`` + The path to the RedisPlusPlus library. + +#]=======================================================================] + + +find_package(PkgConfig) +pkg_check_modules(PC_RedisPlusPlus QUIET redisplusplus) + +find_path(RedisPlusPlus_INCLUDE_DIR + NAMES sw/redis++/redis++.h + PATHS ${PC_RedisPlusPlus_INCLUDE_DIRS} + PATH_SUFFIXES RedisPlusPlus +) + +find_library(RedisPlusPlus_LIBRARY + NAMES redis++ + PATHS ${PC_RedisPlusPlus_LIBRARY_DIRS} +) + +mark_as_advanced( + RedisPlusPlus_INCLUDE_DIR + RedisPlusPlus_LIBRARY +) + +set(RedisPlusPlus_VERSION ${PC_RedisPlusPlus_VERSION}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(RedisPlusPlus + FOUND_VAR RedisPlusPlus_FOUND + REQUIRED_VARS + RedisPlusPlus_LIBRARY + RedisPlusPlus_INCLUDE_DIR + VERSION_VAR RedisPlusPlus_VERSION +) + +if(RedisPlusPlus_FOUND) + set(RedisPlusPlus_LIBRARIES ${RedisPlusPlus_LIBRARY}) + set(RedisPlusPlus_INCLUDE_DIRS ${RedisPlusPlus_INCLUDE_DIR}) + set(RedisPlusPlus_DEFINITIONS ${PC_RedisPlusPlus_CFLAGS_OTHER}) +endif() + +if(RedisPlusPlus_FOUND AND NOT TARGET RedisPlusPlus::RedisPlusPlus) + add_library(RedisPlusPlus::RedisPlusPlus UNKNOWN IMPORTED) + set_target_properties(RedisPlusPlus::RedisPlusPlus PROPERTIES + IMPORTED_LINK_INTERFACE_LANGUAGES "CXX" + IMPORTED_LOCATION "${RedisPlusPlus_LIBRARY}" + INTERFACE_COMPILE_DEFINITIONS "${PC_RedisPlusPlus_CFLAGS_OTHER}" + INTERFACE_INCLUDE_DIRECTORIES "${RedisPlusPlus_INCLUDE_DIR}" +) +endif() diff --git a/docker/0.1.0/Dockerfile b/docker/0.1.0/Dockerfile index 65a59ad9..9a4f269b 100644 --- a/docker/0.1.0/Dockerfile +++ b/docker/0.1.0/Dockerfile @@ -30,7 +30,7 @@ RUN apt-get update && \ python3 \ libyaml-dev libcurl4-openssl-dev procps \ # genopts dependencies - python3-venv && \ + python3-venv libhiredis-dev && \ # install cmake 3.14 since it's needed for some dependencies curl -OL https://github.com/Kitware/CMake/releases/download/v3.23.1/cmake-3.23.1-Linux-x86_64.sh && \ chmod u+x ./cmake-3.23.1-Linux-x86_64.sh && \ @@ -58,6 +58,7 @@ RUN apt-get update && \ git clone https://github.com/pmodels/argobots --recurse-submodules && \ git clone https://github.com/mercury-hpc/mercury --recurse-submodules && \ git clone https://github.com/mochi-hpc/mochi-margo --recurse-submodules && \ + git clone https://github.com/sewenew/redis-plus-plus --recurse-submodules && \ export LD_LIBRARY_PATH=${INSTALL_PATH}/lib:${INSTALL_PATH}/lib64 && \ export PKG_CONFIG_PATH=${INSTALL_PATH}/lib/pkgconfig:${INSTALL_PATH}/lib64/pkgconfig && \ cd && \ @@ -94,6 +95,13 @@ RUN apt-get update && \ PKG_CONFIG_PATH=${INSTALL_PATH}/lib/pkgconfig:${INSTALL_PATH}/lib64/pkgconfig ./configure --prefix=${INSTALL_PATH} && \ make -j install && \ cd && \ + cd deps/redis-plus-plus && \ + mkdir build && \ + cd build && \ + cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} .. && \ + make install -j && \ + cd ../../ && \ + cd && \ rm -rf deps && \ # Clean apt cache to reduce image layer size rm -rf /var/lib/apt/lists/* && \ diff --git a/src/scord-ctl/CMakeLists.txt b/src/scord-ctl/CMakeLists.txt index 26dfc86b..26ea4e21 100644 --- a/src/scord-ctl/CMakeLists.txt +++ b/src/scord-ctl/CMakeLists.txt @@ -36,7 +36,7 @@ target_include_directories( target_link_libraries( scord-ctl PRIVATE common::config common::logger common::network::rpc_server - scord_ctl_private_rpcs fmt::fmt Boost::program_options + scord_ctl_private_rpcs fmt::fmt Boost::program_options RedisPlusPlus::RedisPlusPlus ) install(TARGETS scord DESTINATION ${CMAKE_INSTALL_BINDIR}) diff --git a/src/scord/CMakeLists.txt b/src/scord/CMakeLists.txt index b7d7d6d1..aad2746c 100644 --- a/src/scord/CMakeLists.txt +++ b/src/scord/CMakeLists.txt @@ -67,6 +67,7 @@ target_link_libraries( scord_private_rpcs fmt::fmt Boost::program_options + RedisPlusPlus::RedisPlusPlus ) install(TARGETS scord DESTINATION ${CMAKE_INSTALL_BINDIR}) -- GitLab From a48604030d666f19e036f1bb76a28b7806819d85 Mon Sep 17 00:00:00 2001 From: rnou Date: Thu, 7 Jul 2022 11:55:33 +0200 Subject: [PATCH 2/3] Modified docker image Makefile --- cmake/FindHiRedis.cmake | 117 ---------------------------------------- docker/0.1.0/Makefile | 2 +- 2 files changed, 1 insertion(+), 118 deletions(-) delete mode 100644 cmake/FindHiRedis.cmake diff --git a/cmake/FindHiRedis.cmake b/cmake/FindHiRedis.cmake deleted file mode 100644 index ba36ee37..00000000 --- a/cmake/FindHiRedis.cmake +++ /dev/null @@ -1,117 +0,0 @@ -################################################################################ -# Copyright 2021, Barcelona Supercomputing Center (BSC), Spain # -# # -# This software was partially supported by the EuroHPC-funded project ADMIRE # -# (Project ID: 956748, https://www.admire-eurohpc.eu). # -# # -# This file is part of scord. # -# # -# scord is free software: you can redistribute it and/or modify # -# it under the terms of the GNU General Public License as published by # -# the Free Software Foundation, either version 3 of the License, or # -# (at your option) any later version. # -# # -# scord is distributed in the hope that it will be useful, # -# but WITHOUT ANY WARRANTY; without even the implied warranty of # -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # -# GNU General Public License for more details. # -# # -# You should have received a copy of the GNU General Public License # -# along with scord. If not, see . # -# # -# SPDX-License-Identifier: GPL-3.0-or-later # -################################################################################ - -#[=======================================================================[.rst: -FindHiRedis ---------- - -Find hiredis include dirs and libraries. - -Use this module by invoking find_package with the form:: - - find_package(HiRedis - [version] [EXACT] # Minimum or EXACT version e.g. 0.6.2 - [REQUIRED] # Fail with error if yaml-cpp is not found - ) - -Imported Targets -^^^^^^^^^^^^^^^^ - -This module provides the following imported targets, if found: - -``HIRedis::HiRedis`` - The HiRedis library - -Result Variables -^^^^^^^^^^^^^^^^ - -This will define the following variables: - -``HiRedis_FOUND`` - True if the system has the HiRedis library. -``HiRedis_VERSION`` - The version of the HiRedis library which was found. -``HiRedis_INCLUDE_DIRS`` - Include directories needed to use HiRedis. -``HiRedis_LIBRARIES`` - Libraries needed to link to HiRedis. - -Cache Variables -^^^^^^^^^^^^^^^ - -The following cache variables may also be set: - -``HiRedis_INCLUDE_DIR`` - The directory containing ``hiredis.h``. -``HiRedis_LIBRARY`` - The path to the HiRedis library. - -#]=======================================================================] - - -find_package(PkgConfig) -pkg_check_modules(PC_HiRedis QUIET hiredis) - -find_path(HiRedis_INCLUDE_DIR - NAMES hiredis/hiredis.h - PATHS ${PC_HiRedis_INCLUDE_DIRS} - PATH_SUFFIXES HiRedis -) - -find_library(HiRedis_LIBRARY - NAMES hiredis - PATHS ${PC_HiRedis_LIBRARY_DIRS} -) - -mark_as_advanced( - HiRedis_INCLUDE_DIR - HiRedis_LIBRARY -) - -set(HiRedis_VERSION ${PC_HiRedis_VERSION}) - -include(FindPackageHandleStandardArgs) -find_package_handle_standard_args(HiRedis - FOUND_VAR HiRedis_FOUND - REQUIRED_VARS - HiRedis_LIBRARY - HiRedis_INCLUDE_DIR - VERSION_VAR HiRedis_VERSION -) - -if(HiRedis_FOUND) - set(HiRedis_LIBRARIES ${HiRedis_LIBRARY}) - set(HiRedis_INCLUDE_DIRS ${HiRedis_INCLUDE_DIR}) - set(HiRedis_DEFINITIONS ${PC_HiRedis_CFLAGS_OTHER}) -endif() - -if(HiRedis_FOUND AND NOT TARGET HiRedis::HiRedis) - add_library(HiRedis::HiRedis UNKNOWN IMPORTED) - set_target_properties(HiRedis::HiRedis PROPERTIES - IMPORTED_LINK_INTERFACE_LANGUAGES "CXX" - IMPORTED_LOCATION "${HiRedis_LIBRARY}" - INTERFACE_COMPILE_DEFINITIONS "${PC_HiRedis_CFLAGS_OTHER}" - INTERFACE_INCLUDE_DIRECTORIES "${HiRedis_INCLUDE_DIR}" -) -endif() diff --git a/docker/0.1.0/Makefile b/docker/0.1.0/Makefile index eca88329..d353b79c 100644 --- a/docker/0.1.0/Makefile +++ b/docker/0.1.0/Makefile @@ -1,4 +1,4 @@ .PHONY: all all: - docker build -t gekkofs/scord:0.1.0 . + docker build -t bscstorage/scord:0.1.0 . -- GitLab From a05835c0ff41aac241516bd0c00829359471a920 Mon Sep 17 00:00:00 2001 From: rnou Date: Thu, 7 Jul 2022 12:50:00 +0200 Subject: [PATCH 3/3] Added 0.2.0-wip docker --- .gitlab-ci.yml | 2 +- cmake/FindRedisPlusPlus.cmake | 4 +- docker/0.1.0/Dockerfile | 10 +--- docker/0.2.0-wip/Dockerfile | 109 ++++++++++++++++++++++++++++++++++ docker/0.2.0-wip/Makefile | 4 ++ 5 files changed, 117 insertions(+), 12 deletions(-) create mode 100644 docker/0.2.0-wip/Dockerfile create mode 100644 docker/0.2.0-wip/Makefile diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 87629b4b..91710897 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,6 +1,6 @@ # Compilation of scord and execution of tests -image: bscstorage/scord:0.1.0 +image: bscstorage/scord:0.2.0-wip stages: - build diff --git a/cmake/FindRedisPlusPlus.cmake b/cmake/FindRedisPlusPlus.cmake index 43089297..38e337d8 100644 --- a/cmake/FindRedisPlusPlus.cmake +++ b/cmake/FindRedisPlusPlus.cmake @@ -1,5 +1,5 @@ ################################################################################ -# Copyright 2021, Barcelona Supercomputing Center (BSC), Spain # +# Copyright 2021-2022, Barcelona Supercomputing Center (BSC), Spain # # # # This software was partially supported by the EuroHPC-funded project ADMIRE # # (Project ID: 956748, https://www.admire-eurohpc.eu). # @@ -26,7 +26,7 @@ FindRedisPlusPlus --------- -Find hiredis include dirs and libraries. +Find RedisPlusPlus include dirs and libraries. Use this module by invoking find_package with the form:: diff --git a/docker/0.1.0/Dockerfile b/docker/0.1.0/Dockerfile index 9a4f269b..65a59ad9 100644 --- a/docker/0.1.0/Dockerfile +++ b/docker/0.1.0/Dockerfile @@ -30,7 +30,7 @@ RUN apt-get update && \ python3 \ libyaml-dev libcurl4-openssl-dev procps \ # genopts dependencies - python3-venv libhiredis-dev && \ + python3-venv && \ # install cmake 3.14 since it's needed for some dependencies curl -OL https://github.com/Kitware/CMake/releases/download/v3.23.1/cmake-3.23.1-Linux-x86_64.sh && \ chmod u+x ./cmake-3.23.1-Linux-x86_64.sh && \ @@ -58,7 +58,6 @@ RUN apt-get update && \ git clone https://github.com/pmodels/argobots --recurse-submodules && \ git clone https://github.com/mercury-hpc/mercury --recurse-submodules && \ git clone https://github.com/mochi-hpc/mochi-margo --recurse-submodules && \ - git clone https://github.com/sewenew/redis-plus-plus --recurse-submodules && \ export LD_LIBRARY_PATH=${INSTALL_PATH}/lib:${INSTALL_PATH}/lib64 && \ export PKG_CONFIG_PATH=${INSTALL_PATH}/lib/pkgconfig:${INSTALL_PATH}/lib64/pkgconfig && \ cd && \ @@ -95,13 +94,6 @@ RUN apt-get update && \ PKG_CONFIG_PATH=${INSTALL_PATH}/lib/pkgconfig:${INSTALL_PATH}/lib64/pkgconfig ./configure --prefix=${INSTALL_PATH} && \ make -j install && \ cd && \ - cd deps/redis-plus-plus && \ - mkdir build && \ - cd build && \ - cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} .. && \ - make install -j && \ - cd ../../ && \ - cd && \ rm -rf deps && \ # Clean apt cache to reduce image layer size rm -rf /var/lib/apt/lists/* && \ diff --git a/docker/0.2.0-wip/Dockerfile b/docker/0.2.0-wip/Dockerfile new file mode 100644 index 00000000..9a4f269b --- /dev/null +++ b/docker/0.2.0-wip/Dockerfile @@ -0,0 +1,109 @@ +FROM debian:bullseye-slim + +LABEL Description="Debian-based environment suitable to build scord" + +ENV INSTALL_PATH /usr/local + + +RUN apt-get update && \ + apt-get install -y --no-install-recommends \ + git \ + curl \ + ca-certificates \ + libtool \ + pkg-config \ + make \ + automake \ + gcc \ + g++ \ + procps \ + # AGIOS dependencies + libconfig-dev \ + # Mercury dependencies + libltdl-dev \ + lbzip2 \ + # Margo dependencies \ + libjson-c-dev \ + # GekkoFS dependencies + libboost-program-options-dev \ + uuid-dev \ + python3 \ + libyaml-dev libcurl4-openssl-dev procps \ + # genopts dependencies + python3-venv libhiredis-dev && \ + # install cmake 3.14 since it's needed for some dependencies + curl -OL https://github.com/Kitware/CMake/releases/download/v3.23.1/cmake-3.23.1-Linux-x86_64.sh && \ + chmod u+x ./cmake-3.23.1-Linux-x86_64.sh && \ + ./cmake-3.23.1-Linux-x86_64.sh --skip-license --prefix=${INSTALL_PATH} && \ + # Clean apt cache to reduce image layer size + rm -rf /var/lib/apt/lists/* && \ + # Clean apt caches of packages + apt-get clean && apt-get autoclean && \ + rm ./cmake-3.23.1-Linux-x86_64.sh && \ + cmake --version && \ + curl -OL https://github.com/jbeder/yaml-cpp/archive/refs/tags/yaml-cpp-0.6.2.tar.gz && \ + tar -xzf yaml-cpp-0.6.2.tar.gz && \ + cd yaml-cpp-yaml-cpp-0.6.2 && \ + mkdir build && \ + cd build && \ + cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} .. && \ + make -j install && \ + cd && \ + rm -rf yaml-cpp-yaml-cpp-0.6.2 && \ + mkdir deps && \ + cd deps && \ + git clone https://github.com/jbeder/yaml-cpp --recurse-submodules && \ + git clone https://github.com/json-c/json-c --recurse-submodules && \ + git clone https://github.com/ofiwg/libfabric --recurse-submodules && \ + git clone https://github.com/pmodels/argobots --recurse-submodules && \ + git clone https://github.com/mercury-hpc/mercury --recurse-submodules && \ + git clone https://github.com/mochi-hpc/mochi-margo --recurse-submodules && \ + git clone https://github.com/sewenew/redis-plus-plus --recurse-submodules && \ + export LD_LIBRARY_PATH=${INSTALL_PATH}/lib:${INSTALL_PATH}/lib64 && \ + export PKG_CONFIG_PATH=${INSTALL_PATH}/lib/pkgconfig:${INSTALL_PATH}/lib64/pkgconfig && \ + cd && \ + cd deps/yaml-cpp && \ + mkdir build && \ + cd build && \ + cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} -DYAML_CPP_BUILD_TESTS=OFF .. && \ + make -j install && \ + cd ../../ && \ + cd argobots && \ + ./autogen.sh && \ + ./configure --prefix=${INSTALL_PATH} && \ + make install -j && \ + cd .. && \ + cd libfabric && \ + ./autogen.sh && \ + ./configure --prefix=${INSTALL_PATH} && \ + make install -j && \ + cd .. && \ + cd mercury && \ + mkdir build && \ + cd build && \ + cmake -DMERCURY_USE_SELF_FORWARD:BOOL=ON -DBUILD_TESTING:BOOL=ON -DMERCURY_USE_BOOST_PP:BOOL=ON -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} -DBUILD_SHARED_LIBS:BOOL=ON -DNA_USE_OFI:BOOL=ON -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE:STRING=Release .. && \ + make install -j && \ + cd ../.. && \ + cd json-c && \ + mkdir build && \ + cd build && \ + cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} .. && \ + make install -j && \ + cd ../../ && \ + cd mochi-margo && \ + ./prepare.sh && \ + PKG_CONFIG_PATH=${INSTALL_PATH}/lib/pkgconfig:${INSTALL_PATH}/lib64/pkgconfig ./configure --prefix=${INSTALL_PATH} && \ + make -j install && \ + cd && \ + cd deps/redis-plus-plus && \ + mkdir build && \ + cd build && \ + cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} .. && \ + make install -j && \ + cd ../../ && \ + cd && \ + rm -rf deps && \ + # Clean apt cache to reduce image layer size + rm -rf /var/lib/apt/lists/* && \ + # Clean apt caches of packages + apt-get clean && apt-get autoclean diff --git a/docker/0.2.0-wip/Makefile b/docker/0.2.0-wip/Makefile new file mode 100644 index 00000000..67260f17 --- /dev/null +++ b/docker/0.2.0-wip/Makefile @@ -0,0 +1,4 @@ +.PHONY: all + +all: + docker build -t bscstorage/scord:0.2.0-wip . -- GitLab