Skip to content
Snippets Groups Projects
Commit bcefa6b1 authored by Sergey Yakubov's avatar Sergey Yakubov
Browse files

switch to cmake 3.7+, update build_env docker images

parent f60e2ab6
No related branches found
No related tags found
No related merge requests found
## 20.03 (unreleased)
+## 20.03 (unreleased)
FEATURES
* introduced substreams for producer/consumer [[JIRA_102](https://agira.desy.de/browse/HIDRA2-102)]
......@@ -6,6 +6,7 @@ IMPROVEMENTS
* switch to MongoDB 4.2
* receiver use ASAP3 directory structure to save files to
* API documentation is available at [asapo-docs.desy.de](asapo-docs.desy.de)
* switch to using cmake 3.7+
BUG FIXES
* consumer operation timout - take duration of the operation into account
\ No newline at end of file
cmake_minimum_required(VERSION 2.8)
cmake_minimum_required(VERSION 3.7)
project(ASAPO)
set(CMAKE_CXX_STANDARD 11)
IF(WIN32)
......
......@@ -9,7 +9,8 @@ else()
set (EXTRA_LINK_ARGS "[]")
ENDIF()
get_property(ASAPO_CONSUMER_LIB TARGET asapo-consumer PROPERTY LOCATION)
configure_files(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} @ONLY)
file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py INPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py)
set (ASAPO_CONSUMER_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../cpp/include)
......
......@@ -6,7 +6,7 @@ from Cython.Build import cythonize
import numpy
module = Extension("asapo_consumer", ["asapo_consumer.pyx"],
extra_objects=['@ASAPO_CONSUMER_LIB@',
extra_objects=['$<TARGET_FILE:asapo-consumer>',
'@CURL_LIBRARIES@'],
include_dirs=["@ASAPO_CXX_COMMON_INCLUDE_DIR@","@ASAPO_CONSUMER_INCLUDE_DIR@",numpy.get_include()],
extra_compile_args=@EXTRA_COMPILE_ARGS@,
......
......@@ -11,5 +11,9 @@ RUN ./install_curl.sh /curl
RUN apt install -y python-pip python3-pip && pip install --upgrade cython && pip3 install --upgrade cython
RUN pip3 install sphinx
ADD install_cmake.sh install_cmake.sh
RUN ./install_cmake.sh
ADD build.sh /bin/build.sh
#!/usr/bin/env bash
set -e
cd /asapo/build
cmake \
-DCMAKE_BUILD_TYPE="Release" \
......
#!/usr/bin/env bash
wget https://cmake.org/files/v3.10/cmake-3.10.0.tar.gz
tar zxvf cmake-3.*
cd cmake-3.*
./bootstrap --prefix=/usr/local
make -j$(nproc)
make install
cmake --version
/usr/local/bin/cmake --version
......@@ -11,4 +11,6 @@ ADD build.sh /bin/build.sh
RUN chmod og+rwX -R /opt
ADD install_cmake.sh install_cmake.sh
RUN ./install_cmake.sh
#!/usr/bin/env bash
set -e
for python_path in /opt/python/cp{27,35,36,37}*m; do
python=$python_path/bin/python
......
#!/usr/bin/env bash
docker build -t yakser/asapo-env:manylinux2010 .
#docker push yakser/asapo-env:manylinux2010
docker push yakser/asapo-env:manylinux2010
#!/usr/bin/env bash
wget https://cmake.org/files/v3.10/cmake-3.10.0.tar.gz
tar zxvf cmake-3.*
cd cmake-3.*
./bootstrap --prefix=/usr/local
make -j$(nproc)
make install
cmake --version
/usr/local/bin/cmake --version
......@@ -9,11 +9,11 @@ else()
set (EXTRA_LINK_ARGS "[]")
ENDIF()
get_property(ASAPO_PRODUCER_LIB TARGET asapo-producer PROPERTY LOCATION)
set (ASAPO_PRODUCER_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../cpp/include)
configure_files(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} @ONLY)
file(GENERATE OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py INPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py)
ADD_CUSTOM_TARGET(python-lib-producer ALL
COMMAND ${Python_EXECUTABLE} setup.py build_ext --inplace --force)
......
......@@ -6,7 +6,7 @@ from Cython.Build import cythonize
import numpy
module = Extension("asapo_producer", ["asapo_producer.pyx"],
extra_objects=['@ASAPO_PRODUCER_LIB@',
extra_objects=[$<TARGET_FILE:asapo-producer>,
'@CURL_LIBRARIES@'],
include_dirs=["@ASAPO_CXX_COMMON_INCLUDE_DIR@","@ASAPO_PRODUCER_INCLUDE_DIR@",numpy.get_include()],
extra_compile_args=@EXTRA_COMPILE_ARGS@,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment